musl/arch
Rich Felker c2feda4e2e prefer new socket syscalls, fallback to SYS_socketcall only if needed
a number of users performing seccomp filtering have requested use of
the new individual syscall numbers for socket syscalls, rather than
the legacy multiplexed socketcall, since the latter has the arguments
all in memory where they can't participate in filter decisions.

previously, some archs used the multiplexed socketcall if it was
historically all that was available, while other archs used the
separate syscalls. the intent was that the latter set only include
archs that have "always" had separate socket syscalls, at least going
back to linux 2.6.0. however, at least powerpc, powerpc64, and sh were
wrongly included in this set, and thus socket operations completely
failed on old kernels for these archs.

with the changes made here, the separate syscalls are always
preferred, but fallback code is compiled for archs that also define
SYS_socketcall. two such archs, mips (plain o32) and microblaze,
define SYS_socketcall despite never having needed it, so it's now
undefined by their versions of syscall_arch.h to prevent inclusion of
useless fallback code.

some archs, where the separate syscalls were only added after the
addition of SYS_accept4, lack SYS_accept. because socket calls are
always made with zeros in the unused argument positions, it suffices
to just use SYS_accept4 to provide a definition of SYS_accept, and
this is done to make happy the macro machinery that concatenates the
socket call name onto __SC_ and SYS_.
2020-08-08 20:59:26 -04:00
..
aarch64 add clone3 syscall number from linux v5.3 2019-12-30 18:13:56 -05:00
arm remove arm (32-bit) support for vdso clock_gettime 2020-04-26 17:05:27 -04:00
generic move struct dirent to bits header, allow NAME_MAX to vary 2020-01-25 23:08:55 -05:00
i386 prefer new socket syscalls, fallback to SYS_socketcall only if needed 2020-08-08 20:59:26 -04:00
m68k prefer new socket syscalls, fallback to SYS_socketcall only if needed 2020-08-08 20:59:26 -04:00
microblaze prefer new socket syscalls, fallback to SYS_socketcall only if needed 2020-08-08 20:59:26 -04:00
mips prefer new socket syscalls, fallback to SYS_socketcall only if needed 2020-08-08 20:59:26 -04:00
mips64 fix incorrect SIGSTKFLT on all mips archs 2020-05-21 16:25:12 -04:00
mipsn32 fix incorrect SIGSTKFLT on all mips archs 2020-05-21 16:25:12 -04:00
or1k remove legacy time32 timer[fd] syscalls from public syscall.h 2020-02-05 09:57:41 -05:00
powerpc define MAP_SYNC on powerpc/powerpc64 2020-03-14 21:39:39 -04:00
powerpc64 define MAP_SYNC on powerpc/powerpc64 2020-03-14 21:39:39 -04:00
riscv64 move riscv64 register index constants to signal.h 2020-02-04 09:29:13 -05:00
s390x prefer new socket syscalls, fallback to SYS_socketcall only if needed 2020-08-08 20:59:26 -04:00
sh remove legacy time32 timer[fd] syscalls from public syscall.h 2020-02-05 09:57:41 -05:00
x32 add clone3 syscall number from linux v5.3 2019-12-30 18:13:56 -05:00
x86_64 add clone3 syscall number from linux v5.3 2019-12-30 18:13:56 -05:00