summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorYu Liao <liaoyu15@huawei.com>2024-10-08 10:33:32 +0800
committerShuah Khan <skhan@linuxfoundation.org>2024-10-08 15:48:09 -0600
commit34d5b600172b846161e507bdce132c98d9cc9701 (patch)
tree404954cbf1347d31255349c96fd91ca534488fa0 /tools
parent3953a1d1375247eafeeee24e69abb622f6acbd79 (diff)
selftests: vDSO: Explicitly include sched.h
The previous commit introduced the use of CLONE_NEWTIME without including <sched.h> which contains its definition. Add an explicit include of <sched.h> to ensure that CLONE_NEWTIME is correctly defined before it is used. Fixes: 2aec90036dcd ("selftests: vDSO: ensure vgetrandom works in a time namespace") Signed-off-by: Yu Liao <liaoyu15@huawei.com> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/testing/selftests/vDSO/vdso_test_getrandom.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/vDSO/vdso_test_getrandom.c b/tools/testing/selftests/vDSO/vdso_test_getrandom.c
index da1210c4df02..95057f7567db 100644
--- a/tools/testing/selftests/vDSO/vdso_test_getrandom.c
+++ b/tools/testing/selftests/vDSO/vdso_test_getrandom.c
@@ -11,6 +11,7 @@
#include <string.h>
#include <time.h>
#include <unistd.h>
+#include <sched.h>
#include <signal.h>
#include <sys/auxv.h>
#include <sys/mman.h>