diff options
-rw-r--r-- | fs/notify/fanotify/fanotify.c | 3 | ||||
-rw-r--r-- | fs/notify/fanotify/fanotify.h | 12 | ||||
-rw-r--r-- | fs/notify/fanotify/fanotify_user.c | 5 |
3 files changed, 4 insertions, 16 deletions
diff --git a/fs/notify/fanotify/fanotify.c b/fs/notify/fanotify/fanotify.c index 202be8adb2ec..f6900022f69e 100644 --- a/fs/notify/fanotify/fanotify.c +++ b/fs/notify/fanotify/fanotify.c | |||
@@ -1,3 +1,4 @@ | |||
1 | #include <linux/fanotify.h> | ||
1 | #include <linux/fdtable.h> | 2 | #include <linux/fdtable.h> |
2 | #include <linux/fsnotify_backend.h> | 3 | #include <linux/fsnotify_backend.h> |
3 | #include <linux/init.h> | 4 | #include <linux/init.h> |
@@ -5,8 +6,6 @@ | |||
5 | #include <linux/mount.h> | 6 | #include <linux/mount.h> |
6 | #include <linux/types.h> | 7 | #include <linux/types.h> |
7 | 8 | ||
8 | #include "fanotify.h" | ||
9 | |||
10 | static bool should_merge(struct fsnotify_event *old, struct fsnotify_event *new) | 9 | static bool should_merge(struct fsnotify_event *old, struct fsnotify_event *new) |
11 | { | 10 | { |
12 | pr_debug("%s: old=%p new=%p\n", __func__, old, new); | 11 | pr_debug("%s: old=%p new=%p\n", __func__, old, new); |
diff --git a/fs/notify/fanotify/fanotify.h b/fs/notify/fanotify/fanotify.h deleted file mode 100644 index 4d5723a74a8e..000000000000 --- a/fs/notify/fanotify/fanotify.h +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | #include <linux/fanotify.h> | ||
2 | #include <linux/fsnotify_backend.h> | ||
3 | #include <linux/net.h> | ||
4 | #include <linux/kernel.h> | ||
5 | #include <linux/types.h> | ||
6 | |||
7 | extern const struct fsnotify_ops fanotify_fsnotify_ops; | ||
8 | |||
9 | static inline __u32 fanotify_outgoing_mask(__u32 mask) | ||
10 | { | ||
11 | return mask & FAN_ALL_OUTGOING_EVENTS; | ||
12 | } | ||
diff --git a/fs/notify/fanotify/fanotify_user.c b/fs/notify/fanotify/fanotify_user.c index 618867e4d30f..84155841a025 100644 --- a/fs/notify/fanotify/fanotify_user.c +++ b/fs/notify/fanotify/fanotify_user.c | |||
@@ -1,3 +1,4 @@ | |||
1 | #include <linux/fanotify.h> | ||
1 | #include <linux/fcntl.h> | 2 | #include <linux/fcntl.h> |
2 | #include <linux/file.h> | 3 | #include <linux/file.h> |
3 | #include <linux/fs.h> | 4 | #include <linux/fs.h> |
@@ -14,7 +15,7 @@ | |||
14 | 15 | ||
15 | #include <asm/ioctls.h> | 16 | #include <asm/ioctls.h> |
16 | 17 | ||
17 | #include "fanotify.h" | 18 | extern const struct fsnotify_ops fanotify_fsnotify_ops; |
18 | 19 | ||
19 | static struct kmem_cache *fanotify_mark_cache __read_mostly; | 20 | static struct kmem_cache *fanotify_mark_cache __read_mostly; |
20 | 21 | ||
@@ -102,7 +103,7 @@ static ssize_t fill_event_metadata(struct fsnotify_group *group, | |||
102 | 103 | ||
103 | metadata->event_len = FAN_EVENT_METADATA_LEN; | 104 | metadata->event_len = FAN_EVENT_METADATA_LEN; |
104 | metadata->vers = FANOTIFY_METADATA_VERSION; | 105 | metadata->vers = FANOTIFY_METADATA_VERSION; |
105 | metadata->mask = fanotify_outgoing_mask(event->mask); | 106 | metadata->mask = event->mask & FAN_ALL_OUTGOING_EVENTS; |
106 | metadata->pid = pid_vnr(event->tgid); | 107 | metadata->pid = pid_vnr(event->tgid); |
107 | metadata->fd = create_fd(group, event); | 108 | metadata->fd = create_fd(group, event); |
108 | 109 | ||