Skip to content

Commit

Permalink
fanotify-dont-set-fan_ondir-implicitly-on-a-marks-ignored-mask-checkp…
Browse files Browse the repository at this point in the history
…atch-fixes

WARNING: Missing a blank line after declarations
torvalds#48: FILE: fs/notify/fanotify/fanotify_user.c:495:
+		__u32 tmask = fsn_mark->mask & ~mask;
+		if (flags & FAN_MARK_ONDIR)

WARNING: Missing a blank line after declarations
torvalds#67: FILE: fs/notify/fanotify/fanotify_user.c:579:
+		__u32 tmask = fsn_mark->mask | mask;
+		if (flags & FAN_MARK_ONDIR)

total: 0 errors, 2 warnings, 54 lines checked

./patches/fanotify-dont-set-fan_ondir-implicitly-on-a-marks-ignored-mask.patch has style problems, please review.

If any of these errors are false positives, please report
them to the maintainer, see CHECKPATCH in MAINTAINERS.

Please run checkpatch prior to sending patches

Cc: Lino Sanfilippo <LinoSanfilippo@gmx.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
  • Loading branch information
akpm00 authored and sfrothwell committed Jan 8, 2015
1 parent 45ee284 commit 00ed0d3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fs/notify/fanotify/fanotify_user.c
Expand Up @@ -492,6 +492,7 @@ static __u32 fanotify_mark_remove_from_mask(struct fsnotify_mark *fsn_mark,
spin_lock(&fsn_mark->lock);
if (!(flags & FAN_MARK_IGNORED_MASK)) {
__u32 tmask = fsn_mark->mask & ~mask;

if (flags & FAN_MARK_ONDIR)
tmask &= ~FAN_ONDIR;

Expand Down Expand Up @@ -576,6 +577,7 @@ static __u32 fanotify_mark_add_to_mask(struct fsnotify_mark *fsn_mark,
spin_lock(&fsn_mark->lock);
if (!(flags & FAN_MARK_IGNORED_MASK)) {
__u32 tmask = fsn_mark->mask | mask;

if (flags & FAN_MARK_ONDIR)
tmask |= FAN_ONDIR;

Expand Down

0 comments on commit 00ed0d3

Please sign in to comment.