summaryrefslogtreecommitdiff
path: root/arch/um/kernel
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2021-05-17 16:38:13 +0900
committerThomas Gleixner <tglx@linutronix.de>2021-05-20 15:03:59 +0200
commit49f731f1972e6e44d8a5c3982a72902b3944bc34 (patch)
tree4e484aebd2b85a4f2d03bd82518f52beec0c5258 /arch/um/kernel
parentf63815eb1d909a4121806e60928108ff040bf291 (diff)
x86/syscalls: Use __NR_syscalls instead of __NR_syscall_max
__NR_syscall_max is only used by x86 and UML. In contrast, __NR_syscalls is widely used by all the architectures. Convert __NR_syscall_max to __NR_syscalls and adjust the usage sites. This prepares x86 to switch to the generic syscallhdr.sh script. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://lore.kernel.org/r/20210517073815.97426-6-masahiroy@kernel.org
Diffstat (limited to 'arch/um/kernel')
-rw-r--r--arch/um/kernel/skas/syscall.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/um/kernel/skas/syscall.c b/arch/um/kernel/skas/syscall.c
index 3d91f89fd852..9ee19e566da3 100644
--- a/arch/um/kernel/skas/syscall.c
+++ b/arch/um/kernel/skas/syscall.c
@@ -41,7 +41,7 @@ void handle_syscall(struct uml_pt_regs *r)
goto out;
syscall = UPT_SYSCALL_NR(r);
- if (syscall >= 0 && syscall <= __NR_syscall_max)
+ if (syscall >= 0 && syscall < __NR_syscalls)
PT_REGS_SET_SYSCALL_RETURN(regs,
EXECUTE_SYSCALL(syscall, regs));