summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/memfd/fuse_test.c
diff options
context:
space:
mode:
authorJeff Xu <jeffxu@google.com>2022-12-15 00:12:05 +0000
committerAndrew Morton <akpm@linux-foundation.org>2023-01-18 17:12:37 -0800
commit11f75a01448f1b7a739e75dbd8f17b844fcfc510 (patch)
treea38832bfda0ec5cdd5af8d3158df5f283a454b16 /tools/testing/selftests/memfd/fuse_test.c
parentc4f75bc8bd6b3d62665e1f5400c419540edb5601 (diff)
selftests/memfd: add tests for MFD_NOEXEC_SEAL MFD_EXEC
Tests to verify MFD_NOEXEC, MFD_EXEC and vm.memfd_noexec sysctl. Link: https://lkml.kernel.org/r/20221215001205.51969-6-jeffxu@google.com Signed-off-by: Jeff Xu <jeffxu@google.com> Co-developed-by: Daniel Verkamp <dverkamp@chromium.org> Signed-off-by: Daniel Verkamp <dverkamp@chromium.org> Reviewed-by: Kees Cook <keescook@chromium.org> Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com> Cc: Hugh Dickins <hughd@google.com> Cc: Jann Horn <jannh@google.com> Cc: Jorge Lucangeli Obes <jorgelo@chromium.org> Cc: kernel test robot <lkp@intel.com> Cc: Shuah Khan <skhan@linuxfoundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'tools/testing/selftests/memfd/fuse_test.c')
-rw-r--r--tools/testing/selftests/memfd/fuse_test.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/memfd/fuse_test.c b/tools/testing/selftests/memfd/fuse_test.c
index be675002f918..93798c8c5d54 100644
--- a/tools/testing/selftests/memfd/fuse_test.c
+++ b/tools/testing/selftests/memfd/fuse_test.c
@@ -22,6 +22,7 @@
#include <linux/falloc.h>
#include <fcntl.h>
#include <linux/memfd.h>
+#include <linux/types.h>
#include <sched.h>
#include <stdio.h>
#include <stdlib.h>