Skip to content

freebsd15: Add ki_uerrmsg to struct kinfo_proc #4553

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 11, 2025

Conversation

neuschaefer
Copy link
Contributor

Description

During the development of FreeBSD 15, a field was added to kinfo_proc. With this PR and #4552, the libc-test suite passes on FreeBSD 15 on ppc64.

Sources

Upstream commit: freebsd/freebsd-src@7212b37

Checklist

  • Relevant tests in libc-test/semver have been updated
  • No placeholder or unstable values like *LAST or *MAX are
    included (see #3131)
  • Tested locally (cd libc-test && cargo test --target mytarget);
    especially relevant for platforms that may not be checked in CI

@tgross35
Copy link
Contributor

@asomers given this does technically break the struct definition, do you want this on stable? I think if this is done, the struct should be marked #[non_exhaustive] at the same time so future similar changes aren't breaking (in 1.0 everything will be #[non_exhaustive]).

The change itself LGTM

@asomers
Copy link
Contributor

asomers commented Jul 28, 2025

This change only affects FreeBSD 15. That release is still under development, and therefore no backwards-compatibility concerns apply. So yes I think we should merge it to libc-0.2.

@tgross35
Copy link
Contributor

Thanks for confirming, that's perfect. I think we should still add #[non_exhaustive] to allow changing padding fields into named fields in the future.

Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you just make the struct #[non_exhaustive]? We're starting to do this for everything new, may as well do it with the change here as well

struct kinfo_proc may be extended again in the future.
Add #[non_exhaustive] to let the compiler and other tooling know.
@neuschaefer
Copy link
Contributor Author

could you just make the struct #[non_exhaustive]? We're starting to do this for everything new, may as well do it with the change here as well

commit added.

Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@tgross35 tgross35 added this pull request to the merge queue Aug 11, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Aug 11, 2025
@tgross35 tgross35 added this pull request to the merge queue Aug 11, 2025
Merged via the queue into rust-lang:main with commit 9ee2d2a Aug 11, 2025
48 of 52 checks passed
@neuschaefer neuschaefer deleted the freebsd-kinfo branch August 11, 2025 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants