Re: [PATCH RFC 1/4] syscalls: Create unified partial table for all archs
"Arnd Bergmann" <[email protected]> Sat, 25 Jul 2026 10:25:49 +0200
| Newsgroups | gmane.linux.kbuild.devel,gmane.linux.kernel |
|---|---|
| Message-ID | <[email protected]> |
On Fri, Jul 24, 2026, at 23:22, H. Peter Anvin wrote: > On July 24, 2026 1:25:05 PM PDT, Arnd Bergmann <[email protected]> wrote: >>> It will wrongly add >>> >>> __SYSCALL_WITH_COMPAT(441, sys_epoll_pwait2, compat_sys_epoll_pwait2) >>> >>> to arch/x86/include/generated/asm/syscalls_64.h. >>> >>> Maybe I could add a --ignore-compat to scripts/syscalltbl.sh, and add >>> this flag for 64 builds. What do you think? >> >>IIRC, we can just use compat_sys_epoll_pwait2 for both i386 >>and x32, because compat_sigset_t is compatible with sigset_t -- >>they are only really different on big-endian targets, which >>count the bits in a u64 different from two u32. >> >>This problem also goes away once x32 is gone. > > No reason to introduce another entry point if there's no difference. > > x86, after all, is littleendian and alignment-tolerant. What I meant was the reverse: if the common table has the compat_sys_epoll_pwait2 entry for compat targets and x32 is the only outlier, we don't need a special case for that to force it to use the sys_epoll_pwait2 variant since they are identical on x86. Looking again at the x86 table, I see that x32 is not even described as a compat target and just takes the second (native 64-bit) argument of __SYSCALL_WITH_COMPAT() instead of third anyway, so there wouldn't even be a problem if native and compat were different. Arnd