musl/include/sys/socket.h, branch master musl - an implementation of the standard library for Linux-based systems sys/socket.h: add new SO_ socket options from linux v5.11 2022年03月08日T22:19:40+00:00 Szabolcs Nagy nsz@port70.net 2021年03月07日T21:19:36+00:00 c5ecaca743e4d6c1be7e3fd91dee62e560acb7e2 see linux commit 7fd3253a7de6a317a0683f83739479fb880bffc8 net: Introduce preferred busy-polling linux commit 7c951cafc0cb2e575f1d58677b95ac387ac0a5bd net: Add SO_BUSY_POLL_BUDGET socket option
see
 linux commit 7fd3253a7de6a317a0683f83739479fb880bffc8
 net: Introduce preferred busy-polling
 linux commit 7c951cafc0cb2e575f1d58677b95ac387ac0a5bd
 net: Add SO_BUSY_POLL_BUDGET socket option
sys/socket.h: add SO_DETACH_REUSEPORT_BPF from linux v5.3 2019年12月30日T23:12:46+00:00 Szabolcs Nagy nsz@port70.net 2019年11月03日T22:27:13+00:00 06636c55428fe220ec4bdeecca723a95a75839ce see linux commit 99f3a064bc2e4bd5fe50218646c5be342f2ad18c bpf: net: Add SO_DETACH_REUSEPORT_BPF
see
 linux commit 99f3a064bc2e4bd5fe50218646c5be342f2ad18c
 bpf: net: Add SO_DETACH_REUSEPORT_BPF
move time64 socket options from arch bits to top-level sys/socket.h 2019年11月02日T22:30:56+00:00 Rich Felker dalias@aerifal.cx 2019年11月02日T00:11:08+00:00 c71dbb24c947dc14f43960bfec4da670fccba580 now that all 32-bit archs have 64-bit time types, the values for the time-related socket option macros can be treated as universal for 32-bit archs. the sys/socket.h mechanism for this predates arch/generic and is instead in the top-level header. x32, which does not use the new time64 values of the macros, already has its own overrides, so this commit does not affect it.
now that all 32-bit archs have 64-bit time types, the values for the
time-related socket option macros can be treated as universal for
32-bit archs. the sys/socket.h mechanism for this predates
arch/generic and is instead in the top-level header.
x32, which does not use the new time64 values of the macros, already
has its own overrides, so this commit does not affect it.
move msghdr and cmsghdr out of bits/socket.h 2019年11月02日T22:30:56+00:00 Rich Felker dalias@aerifal.cx 2019年11月01日T03:09:48+00:00 a0252bc75b8546008c6b87e58344c4340683d5eb these structures can now be defined generically in terms of endianness and long size. previously, the 32-bit archs all shared a common definition from the generic bits header, and each 64-bit arch had to repeat the 64-bit version, with endian conditionals if the arch had variants of each endianness. I would prefer getting rid of the preprocessor conditionals for padding and instead using unnamed bitfield members, like commit 9b2921bea1d5017832e1b45d1fd64220047a9802 did for struct timespec. however, at present sendmsg, recvmsg, and recvmmsg need access to the padding members by name to zero them. this could perhaps be cleaned up in the future.
these structures can now be defined generically in terms of endianness
and long size. previously, the 32-bit archs all shared a common
definition from the generic bits header, and each 64-bit arch had to
repeat the 64-bit version, with endian conditionals if the arch had
variants of each endianness.
I would prefer getting rid of the preprocessor conditionals for
padding and instead using unnamed bitfield members, like commit
9b2921bea1d5017832e1b45d1fd64220047a9802 did for struct timespec.
however, at present sendmsg, recvmsg, and recvmmsg need access to the
padding members by name to zero them. this could perhaps be cleaned up
in the future.
make time-related socket options overridable by arch bits files 2019年11月02日T22:30:56+00:00 Rich Felker dalias@aerifal.cx 2019年10月31日T20:48:30+00:00 0bbc04c98115440d15a51d6b2ba087ea79c56ad9 SO_RCVTIMEO and SO_SNDTIMEO already were, but only in aggregate with SO_DEBUG and all of the other low/traditional options that varied per arch. SO_TIMESTAMP* are newly overridable. the two groups have to be done separately since mips64 and powerpc64 will override the former but not the latter. at some point this should be cleaned up to use bits headers more idiomatically.
SO_RCVTIMEO and SO_SNDTIMEO already were, but only in aggregate with
SO_DEBUG and all of the other low/traditional options that varied per
arch. SO_TIMESTAMP* are newly overridable. the two groups have to be
done separately since mips64 and powerpc64 will override the former
but not the latter.
at some point this should be cleaned up to use bits headers more
idiomatically.
add time64 symbol name redirects to public headers, under arch control 2019年10月28日T23:26:52+00:00 Rich Felker dalias@aerifal.cx 2019年07月31日T19:24:58+00:00 1febd21d3fb7b78f6fc13e48b3ff2a396a607a15 a _REDIR_TIME64 macro is introduced, which the arch's alltypes.h is expected to define, to control redirection of symbol names for interfaces that involve time_t and derived types. this ensures that object files will only be linked to libc interfaces matching the ABI whose headers they were compiled against. along with time32 compat shims, which will be introduced separately, the redirection also makes it possible for a single libc (static or shared) to be used with object files produced with either the old (32-bit time_t) headers or the new ones after 64-bit time_t switchover takes place. mixing of such object files (or shared libraries) in the same program will also be possible, but must be done with care; ABI between libc and a consumer of the libc interfaces is guaranteed to match by the the symbol name redirection, but pairwise ABI between consumers of libc that define interfaces between each other in terms of time_t is not guaranteed to match. this change adds a dependency on an additional "GNU C" feature to the public headers for existing 32-bit archs, which is generally undesirable; however, the feature is one which glibc has depended on for a long time, and thus which any viable alternative compiler is going to need to provide. 64-bit archs are not affected, nor will future 32-bit archs be, regardless of whether they are "new" on the kernel side (e.g. riscv32) or just newly-added (e.g. a new sparc or xtensa port). the same applies to newly-added ABIs for existing machine-level archs.
a _REDIR_TIME64 macro is introduced, which the arch's alltypes.h is
expected to define, to control redirection of symbol names for
interfaces that involve time_t and derived types. this ensures that
object files will only be linked to libc interfaces matching the ABI
whose headers they were compiled against.
along with time32 compat shims, which will be introduced separately,
the redirection also makes it possible for a single libc (static or
shared) to be used with object files produced with either the old
(32-bit time_t) headers or the new ones after 64-bit time_t switchover
takes place. mixing of such object files (or shared libraries) in the
same program will also be possible, but must be done with care; ABI
between libc and a consumer of the libc interfaces is guaranteed to
match by the the symbol name redirection, but pairwise ABI between
consumers of libc that define interfaces between each other in terms
of time_t is not guaranteed to match.
this change adds a dependency on an additional "GNU C" feature to the
public headers for existing 32-bit archs, which is generally
undesirable; however, the feature is one which glibc has depended on
for a long time, and thus which any viable alternative compiler is
going to need to provide. 64-bit archs are not affected, nor will
future 32-bit archs be, regardless of whether they are "new" on the
kernel side (e.g. riscv32) or just newly-added (e.g. a new sparc or
xtensa port). the same applies to newly-added ABIs for existing
machine-level archs.
sys/socket.h: add SO_BINDTOIFINDEX from linux v5.1 2019年07月01日T18:12:36+00:00 Szabolcs Nagy nsz@port70.net 2019年06月29日T21:13:18+00:00 5b2b682ddc67552dcd16ed6a095b7f67f47c16c3 SO_BINDTOIFINDEX behaves similar to SO_BINDTODEVICE, but takes a network interface index as argument, rather than the network interface name. see linux commit f5dd3d0c9638a9d9a02b5964c4ad636f06cf7e2c net: introduce SO_BINDTOIFINDEX sockopt
SO_BINDTOIFINDEX behaves similar to SO_BINDTODEVICE, but takes a
network interface index as argument, rather than the network
interface name. see
 linux commit f5dd3d0c9638a9d9a02b5964c4ad636f06cf7e2c
 net: introduce SO_BINDTOIFINDEX sockopt
sys/socket.h: add SO_TXTIME from linux v4.19 2019年03月13日T16:29:23+00:00 Szabolcs Nagy nsz@port70.net 2018年11月10日T18:29:58+00:00 31b3efbf3eccec3296980527f4afcb49a0753b1d added in linux commit 80b14dee2bea128928537d61c333f24cb8cbb62f
added in linux commit 80b14dee2bea128928537d61c333f24cb8cbb62f
add AF_XDP to sys/socket.h from linux v4.18 2018年12月10日T03:24:12+00:00 Szabolcs Nagy nsz@port70.net 2018年08月22日T16:28:31+00:00 0a9a5c20c7ebaba9f60f75a6c40a9506d721dff5 new address family and related macros were added in linux commit 68e8b849b221b37a78a110a0307717d45e3593a0
new address family and related macros were added in linux commit
68e8b849b221b37a78a110a0307717d45e3593a0
fix value of SO_PEERSEC on mips archs 2018年06月26日T19:55:29+00:00 Rich Felker dalias@aerifal.cx 2018年06月26日T19:55:29+00:00 587f5a53bc3a68d80b239ba515d583df690a96df adapted from patch by Matthias Schiffer.
adapted from patch by Matthias Schiffer.

AltStyle によって変換されたページ (->オリジナル) /