Skip to content

Conversation

Bben01
Copy link
Contributor

@Bben01 Bben01 commented Apr 30, 2025

Description

Add constants from linux/cn_proc.h and linux/connector.h

Sources

https://github.com/torvalds/linux/blob/b6ea1680d0ac0e45157a819c41b46565f4616186/include/uapi/linux/cn_proc.h
https://github.com/torvalds/linux/blob/b6ea1680d0ac0e45157a819c41b46565f4616186/include/uapi/linux/connector.h

Checklist

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

@rustbot label +stable-nominated

@rustbot rustbot added O-linux O-unix S-waiting-on-review stable-nominated This PR should be considered for cherry-pick to libc's stable release branch labels Apr 30, 2025
@Bben01
Copy link
Contributor Author

Bben01 commented Apr 30, 2025

I think that the CI is failing on i686-unknown-linux-gnu because it didn't find the header files. What should I do to fix that?

@tgross35
Copy link
Contributor

tgross35 commented May 9, 2025

If these are more recent than our kernel versions in CI, you will need to update libc-test/build.rs to skip them with a FIXME. If you do this, just make sure libc-test passes locally without the skips (assuming you have a newer version locally).

@rustbot author

@rustbot
Copy link
Collaborator

rustbot commented May 9, 2025

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@Bben01 Bben01 force-pushed the feature/add-connector-constants branch 5 times, most recently from c1044df to 60e12f7 Compare May 9, 2025 14:40
@Bben01
Copy link
Contributor Author

Bben01 commented May 9, 2025

I don't know why the style check fails. It says to replace the = with : in the c_enum, but the macro cannot accept :

help: replace equals symbol with a colon
     |
4760 -         PROC_EVENT_EXIT = 0x80000000,
4760 +         PROC_EVENT_EXIT: 0x80000000,

@rustbot ready

@Bben01
Copy link
Contributor Author

Bben01 commented May 31, 2025

I've added c_enum to the ignore list in .ci/style.sh because rustfmt cannot handle the case when values are specified. If you have a better solution, I will implement it instead

The CI failures appear to be unrelated to the changes I made

@Bben01 Bben01 force-pushed the feature/add-connector-constants branch from 8ed834d to abd00f8 Compare May 31, 2025 19:28
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.

Sorry for the delay, thank you for the fix! I don't have any better suggestion for now.

@tgross35 tgross35 enabled auto-merge June 1, 2025 22:31
@tgross35 tgross35 added this pull request to the merge queue Jun 1, 2025
Merged via the queue into rust-lang:main with commit 3451a9d Jun 1, 2025
73 of 96 checks passed
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Jun 1, 2025
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Jun 1, 2025
@tgross35 tgross35 mentioned this pull request Jun 1, 2025
@tgross35 tgross35 added stable-applied This PR has been cherry-picked to libc's stable release branch and removed stable-nominated This PR should be considered for cherry-pick to libc's stable release branch labels Jun 2, 2025
@Bben01 Bben01 deleted the feature/add-connector-constants branch June 2, 2025 18:00
@Bben01
Copy link
Contributor Author

Bben01 commented Jun 2, 2025

@tgross35 do you know when the next release is coming out?

@tgross35
Copy link
Contributor

tgross35 commented Jun 2, 2025

Probably within a couple of weeks. Usually it's about once every 6 weeks, this cycle got kind of slowed down with backport conflicts and CI issues.

DorianNiemiecSVRJS pushed a commit to DorianNiemiecSVRJS/rust-libc that referenced this pull request Jun 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-linux O-unix S-waiting-on-review stable-applied This PR has been cherry-picked to libc's stable release branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants