aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/audit_fsnotify.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2018-06-16 16:06:18 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2018-06-16 16:06:18 -0400
commitdbb2816fc78abb0282a803bea1119e2f31354b20 (patch)
tree5122c31321a6afcf8f9b99d823a22eba577f80d3 /kernel/audit_fsnotify.c
parent644f2639aef0c7a9a4f59b679375719d720d5461 (diff)
parentb249f5be6165811749b04a927806056c198222b1 (diff)
Merge tag 'fsnotify_for_v4.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs
Pull fsnotify updates from Jan Kara: "fsnotify cleanups unifying handling of different watch types. This is the shortened fsnotify series from Amir with the last five patches pulled out. Amir has modified those patches to not change struct inode but obviously it's too late for those to go into this merge window" * tag 'fsnotify_for_v4.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs: fsnotify: add fsnotify_add_inode_mark() wrappers fanotify: generalize fanotify_should_send_event() fsnotify: generalize send_to_group() fsnotify: generalize iteration of marks by object type fsnotify: introduce marks iteration helpers fsnotify: remove redundant arguments to handle_event() fsnotify: use type id to identify connector object type
Diffstat (limited to 'kernel/audit_fsnotify.c')
-rw-r--r--kernel/audit_fsnotify.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/audit_fsnotify.c b/kernel/audit_fsnotify.c
index 52f368b6561e..fba78047fb37 100644
--- a/kernel/audit_fsnotify.c
+++ b/kernel/audit_fsnotify.c
@@ -109,7 +109,7 @@ struct audit_fsnotify_mark *audit_alloc_mark(struct audit_krule *krule, char *pa
109 audit_update_mark(audit_mark, dentry->d_inode); 109 audit_update_mark(audit_mark, dentry->d_inode);
110 audit_mark->rule = krule; 110 audit_mark->rule = krule;
111 111
112 ret = fsnotify_add_mark(&audit_mark->mark, inode, NULL, true); 112 ret = fsnotify_add_inode_mark(&audit_mark->mark, inode, true);
113 if (ret < 0) { 113 if (ret < 0) {
114 fsnotify_put_mark(&audit_mark->mark); 114 fsnotify_put_mark(&audit_mark->mark);
115 audit_mark = ERR_PTR(ret); 115 audit_mark = ERR_PTR(ret);
@@ -165,12 +165,11 @@ static void audit_autoremove_mark_rule(struct audit_fsnotify_mark *audit_mark)
165/* Update mark data in audit rules based on fsnotify events. */ 165/* Update mark data in audit rules based on fsnotify events. */
166static int audit_mark_handle_event(struct fsnotify_group *group, 166static int audit_mark_handle_event(struct fsnotify_group *group,
167 struct inode *to_tell, 167 struct inode *to_tell,
168 struct fsnotify_mark *inode_mark,
169 struct fsnotify_mark *vfsmount_mark,
170 u32 mask, const void *data, int data_type, 168 u32 mask, const void *data, int data_type,
171 const unsigned char *dname, u32 cookie, 169 const unsigned char *dname, u32 cookie,
172 struct fsnotify_iter_info *iter_info) 170 struct fsnotify_iter_info *iter_info)
173{ 171{
172 struct fsnotify_mark *inode_mark = fsnotify_iter_inode_mark(iter_info);
174 struct audit_fsnotify_mark *audit_mark; 173 struct audit_fsnotify_mark *audit_mark;
175 const struct inode *inode = NULL; 174 const struct inode *inode = NULL;
176 175