libc icon indicating copy to clipboard operation
libc copied to clipboard

Add additional Linux AF_PACKET options (libc 0.2)

Open nathaniel-bennett opened this issue 2 years ago • 8 comments

Added socket options, structs and other miscellaneous constants that make memory-mapped packet sockets possible in Linux--PACKET_TX_RING, PACKET_RX_RING, etc.

(adding this to libc 0.2 as 0.3 is in early development)

nathaniel-bennett avatar Jan 12 '24 21:01 nathaniel-bennett

r? @JohnTitor

(rustbot has picked a reviewer for you, use r? to override)

rustbot avatar Jan 12 '24 21:01 rustbot

Sorry but could you add cfgs here? 0.2's MSRV is 1.13 and we need to add them, see https://github.com/rust-lang/libc/tree/libc-0.2#rust-version-support.

JohnTitor avatar Jan 14 '24 07:01 JohnTitor

Added cfgs for union types in latest force-push

nathaniel-bennett avatar Jan 17 '24 00:01 nathaniel-bennett

CI fails, seems you also need libc_align cfg. @rustbot author

JohnTitor avatar Jan 19 '24 19:01 JohnTitor

Added libc_align cfg to any structs that use repr(align)

nathaniel-bennett avatar Mar 05 '24 01:03 nathaniel-bennett

Resolved other issues with libc_const_size_of--ready to merge

nathaniel-bennett avatar May 03 '24 13:05 nathaniel-bennett

Removed the unintentional semicolon and rebased

nathaniel-bennett avatar May 14 '24 15:05 nathaniel-bennett

Rebased to working CI and ready for review

nathaniel-bennett avatar Jun 19 '24 12:06 nathaniel-bennett

r? @tgross35

nathaniel-bennett avatar Aug 13 '24 02:08 nathaniel-bennett

This is a big-ish API surface so it's still taking me a while to going through it. Feel free to hold off rebasing until I get back to you.

Some brief notes below.

tgross35 avatar Aug 16 '24 09:08 tgross35

Linked to (https://github.com/rust-lang/rust/issues/43894), removed the spurious whitespace, and dropped the Debug implementations. This is a backport of a PR that was already added to the 1.0 branch, so I'll open up a PR taking out the bad Debug implementations there too

nathaniel-bennett avatar Aug 16 '24 10:08 nathaniel-bennett

@rustbot label S-waiting-on-review

nathaniel-bennett avatar Aug 16 '24 20:08 nathaniel-bennett

@rustbot label -S-waiting-on-author

nathaniel-bennett avatar Aug 16 '24 20:08 nathaniel-bennett