Skip to content

x32 and compat syscall improvements

Andy Lutomirski lkml 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4x86/syscalls: Use the compat versions of rt_sigsuspend() and rt_sigprocmask()arch/x86/entry/syscalls/syscall_32.tbl+2 -20 replies
2/4x86/syscalls: Disallow compat entries for all types of 64-bit syscallsarch/x86/entry/syscalls/syscalltbl.sh+2 -20 replies
3/4x86/syscalls: Split the x32 syscalls into their own tablearch/x86/entry/common.c arch/x86/entry/syscall_64.c arch/x86/entry/syscalls/syscalltbl.sh +5 more+163 -270 replies
4/4x86/syscalls: Make __X32_SYSCALL_BIT be unsigned longarch/x86/include/uapi/asm/unistd.h+1 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/4] x32 and compat syscall improvements

This series contains a couple of minor cleanups and a major change to the way that x32 syscalls work. We currently have a range of syscall numbers starting at 512 that are rather annoying -- they've been known to cause security problems for seccomp filter authors who don't know about them, and they cause people to think that x86_64 will run out of syscall numbers after 511 due to a conflict with x32.

With this series applied, 512-547 can be just a silly legacy oddity just like all the other silly legacy oddities we have, and we can go on with our lives without kludges starting at 548 :)

Andy Lutomirski (4):
x86/syscalls: Use the compat versions of rt_sigsuspend() and
rt_sigprocmask()
x86/syscalls: Disallow compat entries for all types of 64-bit syscalls x86/syscalls: Split the x32 syscalls into their own table x86/syscalls: Make __X32_SYSCALL_BIT be unsigned long

 arch/x86/entry/common.c                       | 13 +--
 arch/x86/entry/syscall_64.c                   | 25 ++++++
 arch/x86/entry/syscalls/syscall_32.tbl        |  4 +-
 arch/x86/entry/syscalls/syscalltbl.sh         | 35 ++++----
 arch/x86/include/asm/syscall.h                |  4 +
 arch/x86/include/asm/unistd.h                 |  6 --
 arch/x86/include/uapi/asm/unistd.h            |  2 +-
 arch/x86/kernel/asm-offsets_64.c              | 20 +++++
 tools/testing/selftests/x86/Makefile          |  2 +-
 .../testing/selftests/x86/syscall_numbering.c | 89 +++++++++++++++++++
 10 files changed, 168 insertions(+), 32 deletions(-)
 create mode 100644 tools/testing/selftests/x86/syscall_numbering.c
Signature · 1 line
2.21.0