From: Kees Cook Date: Mon, 10 Feb 2025 17:22:50 +0000 (-0800) Subject: selftests/seccomp: Add hard-coded __NR_uretprobe for x86_64 X-Git-Tag: v6.15-rc1~232^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18f7686a1ce6b72e0ac61aa16f167eb931185cf1;p=thirdparty%2Fkernel%2Flinux.git selftests/seccomp: Add hard-coded __NR_uretprobe for x86_64 Since headers don't always follow the selftests around correct, explicitly include the __NR_uretprobe syscall for better test coverage. Signed-off-by: Kees Cook --- diff --git a/tools/testing/selftests/seccomp/seccomp_bpf.c b/tools/testing/selftests/seccomp/seccomp_bpf.c index 14ba51b52095a..b2f76a52215ad 100644 --- a/tools/testing/selftests/seccomp/seccomp_bpf.c +++ b/tools/testing/selftests/seccomp/seccomp_bpf.c @@ -155,6 +155,12 @@ struct seccomp_data { # endif #endif +#ifndef __NR_uretprobe +# if defined(__x86_64__) +# define __NR_uretprobe 335 +# endif +#endif + #ifndef SECCOMP_SET_MODE_STRICT #define SECCOMP_SET_MODE_STRICT 0 #endif