]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
selftests/seccomp: remove ARRAY_SIZE define from seccomp_benchmark
authorShuah Khan <skhan@linuxfoundation.org>
Thu, 9 Dec 2021 23:20:53 +0000 (16:20 -0700)
committerShuah Khan <skhan@linuxfoundation.org>
Sat, 11 Dec 2021 00:51:09 +0000 (17:51 -0700)
ARRAY_SIZE is defined in several selftests. Remove definitions from
individual test files and include header file for the define instead.
ARRAY_SIZE define is added in a separate patch to prepare for this
change.

Remove ARRAY_SIZE from seccomp_benchmark and pickup the one defined in
kselftest.h.

Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/seccomp/seccomp_benchmark.c

index 6e5102a7d7c9ecf8d726872f1308cf35eab24574..5b5c9d558dee07bc1f7afd7df280e1189858451e 100644 (file)
@@ -18,7 +18,7 @@
 #include <sys/syscall.h>
 #include <sys/types.h>
 
-#define ARRAY_SIZE(a)    (sizeof(a) / sizeof(a[0]))
+#include "../kselftest.h"
 
 unsigned long long timing(clockid_t clk_id, unsigned long long samples)
 {