summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/memfd/memfd_test.c
diff options
context:
space:
mode:
authorMichael Ellerman <mpe@ellerman.id.au>2020-11-04 13:03:05 +0300
committerShuah Khan <skhan@linuxfoundation.org>2020-11-11 00:42:04 +0300
commit1c49e3783f8899555190a49024ac86d3d76633cd (patch)
treed65b2f5d54d5f662a2425f3090c09ceb320f15ef /tools/testing/selftests/memfd/memfd_test.c
parentfc4a3a1bf9ad799181e4d4ec9c2598c0405bc27d (diff)
downloadlinux-1c49e3783f8899555190a49024ac86d3d76633cd.tar.xz
selftests/memfd: Fix implicit declaration warnings
The memfd tests emit several warnings: fuse_test.c:261:7: warning: implicit declaration of function 'open' fuse_test.c:67:6: warning: implicit declaration of function 'fcntl' memfd_test.c:397:6: warning: implicit declaration of function 'fallocate' memfd_test.c:64:7: warning: implicit declaration of function 'open' memfd_test.c:90:6: warning: implicit declaration of function 'fcntl' These are all caused by the test not including fcntl.h. Instead of including linux/fcntl.h, include fcntl.h, which should eventually cause the former to be included as well. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'tools/testing/selftests/memfd/memfd_test.c')
-rw-r--r--tools/testing/selftests/memfd/memfd_test.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/memfd/memfd_test.c b/tools/testing/selftests/memfd/memfd_test.c
index 334a7eea2004..74baab83fec3 100644
--- a/tools/testing/selftests/memfd/memfd_test.c
+++ b/tools/testing/selftests/memfd/memfd_test.c
@@ -6,7 +6,7 @@
#include <inttypes.h>
#include <limits.h>
#include <linux/falloc.h>
-#include <linux/fcntl.h>
+#include <fcntl.h>
#include <linux/memfd.h>
#include <sched.h>
#include <stdio.h>