I run the test locally on a vm running linux-oracle-5.15-1029.
It seems `syscall(__NR__sysctl, NULL)` returns ENOSYS(38) -- Function not implemented.
Checking `/proc/kallsyms` it seems sysctl is not implemented indeed.
If I take a closer look at jammy-ubuntu tag in systemd source (test that is not failing currently)
I can see that it asserts for either EFAULT or ENOSYS:
I run the test locally on a vm running linux-oracle- 5.15-1029. __NR__sysctl, NULL)` returns ENOSYS(38) -- Function not implemented.
It seems `syscall(
Checking `/proc/kallsyms` it seems sysctl is not implemented indeed.
If I take a closer look at jammy-ubuntu tag in systemd source (test that is not failing currently)
I can see that it asserts for either EFAULT or ENOSYS:
assert_ se(IN_SET( errno, EFAULT, ENOSYS));
This patch will solve the issue:
diff --git a/src/test/ test-seccomp. c b/src/test/ test-seccomp. c .7ebcca4d3 100644 test-seccomp. c test-seccomp. c sysctl( void) {
assert_ se(syscall( __NR__sysctl, NULL) < 0); se(IN_SET( errno, EFAULT, ENOSYS));
index 67900d85e.
--- a/src/test/
+++ b/src/test/
@@ -307,7 +307,7 @@ static void test_protect_
if (pid == 0) {
#if defined __NR__sysctl && __NR__sysctl >= 0
- assert_se(errno == EFAULT);
+ assert_
#endif