From: Chen Jiahao chenjiahao16@huawei.com
hulk inclusion category: bugfix bugzilla: 176178 https://gitee.com/openeuler/kernel/issues/I4DDEL
--------
In secure computing mode, due to the incorrect name of syscall __NR_compat_exit, while setting as strict mode, calling exit(0) will return SIGKILL, which does not match our expectation. This patch fixes it.
Fixes: 2227c11c5f07 ("[Huawei] arm64: secomp: fix the secure computing mode 1 syscall check for ilp32") Signed-off-by: Chen Jiahao chenjiahao16@huawei.com Reviewed-by: Liao Chang liaochang1@huawei.com Signed-off-by: Chen Jun chenjun102@huawei.com --- arch/arm64/include/asm/seccomp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm64/include/asm/seccomp.h b/arch/arm64/include/asm/seccomp.h index 0be58ac682c4..bc3ab2468f03 100644 --- a/arch/arm64/include/asm/seccomp.h +++ b/arch/arm64/include/asm/seccomp.h @@ -25,7 +25,7 @@ static inline const int *get_compat_mode1_syscalls(void) #ifdef CONFIG_AARCH32_EL0 static const int mode1_syscalls_a32[] = { __NR_compat_read, __NR_compat_write, - __NR_compat_read, __NR_compat_sigreturn, + __NR_compat_exit, __NR_compat_sigreturn, 0, /* null terminated */ }; #endif