NetBSD: add kinfo_file, kinfo_pcb structures and related constants#4985
Merged
tgross35 merged 1 commit intorust-lang:mainfrom Mar 3, 2026
Merged
NetBSD: add kinfo_file, kinfo_pcb structures and related constants#4985tgross35 merged 1 commit intorust-lang:mainfrom
kinfo_file, kinfo_pcb structures and related constants#4985tgross35 merged 1 commit intorust-lang:mainfrom
Conversation
Collaborator
|
Some changes occurred in a NetBSD-like module cc @semarie |
Contributor
just to note that the PR is properly rebased to NetBSD only 👍 |
tgross35
requested changes
Mar 2, 2026
Collaborator
|
Reminder, once the PR becomes ready for a review, use |
This comment has been minimized.
This comment has been minimized.
kinfo_file, kinfo_pcb structures and related constants
tgross35
reviewed
Mar 3, 2026
Collaborator
|
Some changes occurred in an OpenBSD module cc @semarie |
This comment has been minimized.
This comment has been minimized.
Collaborator
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
tgross35
approved these changes
Mar 3, 2026
Contributor
Author
Thank you for the review! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR extends NetBSD support with updates to kernel information structures and file descriptor types.
1. Added
kinfo_pcbPCB_SLOPPCB_ALL2.
kinfo_filestructureKERN_FILE_BYFILEKERN_FILE_BYPIDKERN_FILESLOP3. File descriptor types
DTYPE_VNODEDTYPE_SOCKETDTYPE_PIPEDTYPE_MISCDTYPE_CRYPTODTYPE_MQUEUEDTYPE_SEMDTYPE_EVENTFDDTYPE_TIMERFDSources
Checklist
libc-test/semverhave been updated*LASTor*MAXareincluded (see #3131)
cd libc-test && cargo test --target mytarget);especially relevant for platforms that may not be checked in CI
@rustbot label +stable-nominated
Of all the file descriptor types, I’ve been having trouble with
DTYPE_MEMFD. Even though it exists in the NetBSD source code, the corresponding header on an actual installation seems to be missing this definition. I’m not sure how to handle this properly—whether to ignore it during tests or not include it at all.