Page MenuHomeFreeBSD

atf: libatf-c: widen our process status capabilities
Needs RevisionPublic

Authored by kevans on Jun 25 2025, 3:53 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Oct 12, 11:48 PM
Unknown Object (File)
Sun, Oct 12, 11:48 PM
Unknown Object (File)
Sun, Oct 12, 12:18 PM
Unknown Object (File)
Wed, Oct 1, 10:03 AM
Unknown Object (File)
Tue, Sep 30, 9:08 AM
Unknown Object (File)
Sep 18 2025, 12:31 AM
Unknown Object (File)
Sep 12 2025, 12:15 AM
Unknown Object (File)
Sep 10 2025, 9:27 PM
Subscribers

Details

Reviewers
igoro
kib
ngie
Group Reviewers
tests
Summary

waitid(2) is commonly available enough, switch to using that for general
wait status collection in libatf-c. This gives us access to the full
32-bit range of exit statuses, which I want to be able to test error
propagation in lockf(1).

atf-check(1) is updated to allow the full 32-bit range.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 65072
Build 61955: arc lint + arc unit

Event Timeline

I do not know atf code, the usage of waitid/siginfo_t is fine.

contrib/atf/atf-c/detail/process.c
191

Or just s->m_info = *info;.
No opinion.

This revision is now accepted and ready to land.Jun 25 2025, 5:24 PM
ngie requested changes to this revision.Jun 27 2025, 6:52 PM

Please submit this upstream. We need to work through the porting issues with Linux/MacOS in order to land this to avoid having multiple different forks/mutations of this (ATF) code.

contrib/atf/atf-sh/atf-check_test.sh
65

These are [nowFreeBSD-implementation

This revision now requires changes to proceed.Jun 27 2025, 6:52 PM
contrib/atf/atf-sh/atf-check_test.sh
65

Please ignore this comment.

Please submit this upstream. We need to work through the porting issues with Linux/MacOS in order to land this to avoid having multiple different forks/mutations of this (ATF) code.

Sure; both have waitid(), so this should more or less be fine. I'll submit a PR, though.

Please submit this upstream. We need to work through the porting issues with Linux/MacOS in order to land this to avoid having multiple different forks/mutations of this (ATF) code.

Thanks for your review.

Probably, we could go with a similar approach as we do for kyua, i.e., if the review is complete we could land the change to freebsd-src and start active testing of main build & CI, and meanwhile a respective Pull Request to the github/freebsd/kyua would wait for additional public review by non-FreeBSD consumers (if required by the nature of the change)? And, if there is any change on the upstream side (GitHub repo) then it will eventually hit freebsd-src by vendor merge process.

What do you think?

P.S. By the way, it seems macOS and Linux testing of the PR was successful.

@ngie seems to be completely unresponsive both in the PR I created and here, so I'm going to move forward with committing this and I'll take responsibility for reconciling any diff once the upstream review gets through.