Skip to contentSkip to conversation

syscalls/fanotify12: add new test for FAN_OPEN_EXEC event mask

PATCH New Matthew Bobrowski 1 participant 1 message Jan 22, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 4/5 syscalls/fanotify12: add new test for FAN_OPEN_EXEC event mask

* Defined FAN_OPEN_EXEC flag in local fanotify header file in case the user space system header files do not have this event type defined

* Added a new test file fanotify12 that contains the necessary test cases to support and test the FAN_OPEN_EXEC event mask

---
 testcases/kernel/syscalls/fanotify/.gitignore   |   1 +
 testcases/kernel/syscalls/fanotify/fanotify.h   |   3 +
 testcases/kernel/syscalls/fanotify/fanotify12.c | 282 ++++++++++++++++++++++++
 3 files changed, 286 insertions(+)
 create mode 100644 testcases/kernel/syscalls/fanotify/fanotify12.c
testcases/kernel/syscalls/fanotify/.gitignore +1 -0
index e08310ed4..4256b8cd3 100644
@@ -9,4 +9,5 @@
 /fanotify09
 /fanotify10
 /fanotify11
+/fanotify12
 /fanotify_child
testcases/kernel/syscalls/fanotify/fanotify.h +3 -0
index c77e7a4ac..e5cc59232 100644
@@ -64,6 +64,9 @@ static long fanotify_mark(int fd, unsigned int flags, uint64_t mask,
 #ifndef FAN_MARK_FILESYSTEM
 #define FAN_MARK_FILESYSTEM	0x00000100
 #endif
+#ifndef FAN_OPEN_EXEC
+#define FAN_OPEN_EXEC		0x00001000
+#endif
 #ifndef FAN_OPEN_EXEC_PERM
 #define FAN_OPEN_EXEC_PERM	0x00040000
 #endif
testcases/kernel/syscalls/fanotify/fanotify12.c new file +282 -0

282 lines not on this page · raw message

Signature · 5 lines
2.16.4


-- 
Matthew Bobrowski