Skip to content

Update linux-raw-sys to 0.6 #1061

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 2 commits into from
Dec 8, 2024

Conversation

oherrala
Copy link
Contributor

This required changing fields of some structs under io_uring thus probably braking semantic versioning.

@sunfishcode sunfishcode added the semver bump Issues that will require a semver-incompatible fix label May 21, 2024
@sunfishcode
Copy link
Member

Yes, this is unfortunately semver breaking. If there's a specific feature you need in linux-raw-sys 0.6, we can backport or add compatible definitions it to 0.4.

@raftario
Copy link

raftario commented Sep 7, 2024

I'm personally interested in this for the futex support in io_uring

@sunfishcode
Copy link
Member

0.38.x releases are now being done in a dedicated 0.38 branch, so main can now accept semver-breaking changes.

The CI failure looks like rustix's io_uring_sync_cancel_reg needs to be updated to match the changes in Linux.

@raftario
Copy link

@oherrala Do you plan on updating this to fix CI ? If not I'd be happy to take over

@oherrala oherrala force-pushed the update-linux-raw branch 3 times, most recently from c2963af to d6b6435 Compare September 15, 2024 09:14
@sunfishcode
Copy link
Member

The CI failure here looks due to changes in the layout of xdp_umem_reg, so it looks like rustix's XdpUmemReg needs to be updated to match.

@oherrala oherrala force-pushed the update-linux-raw branch 2 times, most recently from 12292b7 to 725c0e5 Compare September 21, 2024 09:01
@sunfishcode
Copy link
Member

The compile errors are fixed on main in #1173. However the linux-i686 failure here looks relevant:

thread 'net::types::test_sizes' panicked at src/net/types.rs:1817:5:
assertion `left == right` failed
  left: 32
 right: 28

@arctic-alpaca
Copy link
Contributor

However the linux-i686 failure here looks relevant:

This is caused by the libc crate still using the previous/removed version of the struct:

@arctic-alpaca
Copy link
Contributor

Starting with libc version 0.2.165, the struct is updated and this PR shouldn't be blocked on this anymore.

@oherrala
Copy link
Contributor Author

oherrala commented Dec 1, 2024

Rebased my changes on top of ef39477. Let's see if the tests pass now.

@cgwalters
Copy link
Contributor

We hit on the listxattr call exposing c_char and hence I think this PR would roll in sunfishcode/linux-raw-sys@769c988#diff-b1a35a68f14e696205874893c07fd24fdb88882b47c23cc0e0c80a30c7d53759R20 which would fix that

cgwalters added a commit to cgwalters/composefs-rs that referenced this pull request Dec 4, 2024
See bytecodealliance/rustix#1061 (comment)
Basically current rustix 0.38 sometimes may expose the element type as a signed
or unsigned variant, depending on the version of linux-raw-sys and rustix feature
flags.

Add a cast to work around this; if we cared to drop the unsafe we could
use the zerocopy crate.

Signed-off-by: Colin Walters <[email protected]>
allisonkarlitskaya pushed a commit to containers/composefs-rs that referenced this pull request Dec 5, 2024
See bytecodealliance/rustix#1061 (comment)
Basically current rustix 0.38 sometimes may expose the element type as a signed
or unsigned variant, depending on the version of linux-raw-sys and rustix feature
flags.

Add a cast to work around this; if we cared to drop the unsafe we could
use the zerocopy crate.

Signed-off-by: Colin Walters <[email protected]>
@sunfishcode sunfishcode merged commit b030081 into bytecodealliance:main Dec 8, 2024
45 checks passed
@sunfishcode
Copy link
Member

Thanks!

@oherrala oherrala deleted the update-linux-raw branch December 9, 2024 19:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
semver bump Issues that will require a semver-incompatible fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants