summaryrefslogtreecommitdiff
path: root/fs/notify/dnotify
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2016-12-21 16:03:59 +0100
committerJan Kara <jack@suse.cz>2017-04-10 17:37:36 +0200
commit66d2b81bcb92c14b22a56a9ff936f2b40accc83c (patch)
tree03632d0a65bc71141a6788381a0eea5eb2f4660d /fs/notify/dnotify
parent05f0e38724e8449184acd8fbf0473ee5a07adc6c (diff)
fsnotify: Remove fsnotify_set_mark_{,ignored_}mask_locked()
These helpers are now only a simple assignment and just obfuscate what is going on. Remove them. Reviewed-by: Miklos Szeredi <mszeredi@redhat.com> Reviewed-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/notify/dnotify')
-rw-r--r--fs/notify/dnotify/dnotify.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/notify/dnotify/dnotify.c b/fs/notify/dnotify/dnotify.c
index aba165ae3397..5940c75541a7 100644
--- a/fs/notify/dnotify/dnotify.c
+++ b/fs/notify/dnotify/dnotify.c
@@ -52,7 +52,7 @@ struct dnotify_mark {
*/
static void dnotify_recalc_inode_mask(struct fsnotify_mark *fsn_mark)
{
- __u32 new_mask, old_mask;
+ __u32 new_mask = 0;
struct dnotify_struct *dn;
struct dnotify_mark *dn_mark = container_of(fsn_mark,
struct dnotify_mark,
@@ -60,14 +60,11 @@ static void dnotify_recalc_inode_mask(struct fsnotify_mark *fsn_mark)
assert_spin_locked(&fsn_mark->lock);
- old_mask = fsn_mark->mask;
- new_mask = 0;
for (dn = dn_mark->dn; dn != NULL; dn = dn->dn_next)
new_mask |= (dn->dn_mask & ~FS_DN_MULTISHOT);
- fsnotify_set_mark_mask_locked(fsn_mark, new_mask);
-
- if (old_mask == new_mask)
+ if (fsn_mark->mask == new_mask)
return;
+ fsn_mark->mask = new_mask;
fsnotify_recalc_mask(fsn_mark->connector);
}