linux_like: add missing STATX_* constants - #5412
Open
valentynkit wants to merge 1 commit into
Open
Conversation
libc already has `struct statx` fields through 6.16 but there are missing masks, so several fields are exposed with no way to request them. Add the five constants the header defines and libc does not. The NDK doesn't have `STATX_DIO_READ_ALIGN` yet, so left out for Android. Three others landed in r28 and CI still runs r27, so they're skipped in `test_android`. Link: https://github.com/torvalds/linux/blob/8cd9520d35a6c38db6567e97dd93b1f11f185dc6/include/uapi/linux/stat.h#L218-L221 Link: https://github.com/torvalds/linux/blob/8cd9520d35a6c38db6567e97dd93b1f11f185dc6/include/uapi/linux/stat.h#L257 Link: https://android.googlesource.com/platform/bionic/+/a63b21091ada240d92f8ceadb1cabbdedaaab81b/libc/kernel/uapi/linux/stat.h#95 Link: https://man7.org/linux/man-pages/man2/statx.2.html
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.
libc already has
struct statxfields through, which were added in #4621 but there are missing masks, so several fields are exposed with no way to request them.Adding the five constants the header defines and libc does not.
The Android NDK doesn't have
STATX_DIO_READ_ALIGNyet, so left out for Android. Three others landed in r28 and CI still runs r27, so they're skipped intest_android, without it, the fails will probably fail.Earlier attempt adding these constants: #4401, closed unfinished.
Link: https://github.com/torvalds/linux/blob/8cd9520d35a6c38db6567e97dd93b1f11f185dc6/include/uapi/linux/stat.h#L218-L221
Link: https://github.com/torvalds/linux/blob/8cd9520d35a6c38db6567e97dd93b1f11f185dc6/include/uapi/linux/stat.h#L257
Link: https://android.googlesource.com/platform/bionic/+/a63b21091ada240d92f8ceadb1cabbdedaaab81b/libc/kernel/uapi/linux/stat.h#95
Link: https://man7.org/linux/man-pages/man2/statx.2.html
Description
Checklist
libc-test/semverhave been updated*LASTor*MAXhave the standarddoc comment
cargo test -p libc-test --target mytarget);especially relevant for platforms that may not be checked in CI
@rustbot label +stable-nominated