summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorJan Kara <jack@suse.cz>2017-01-04 10:33:18 +0100
committerJan Kara <jack@suse.cz>2017-04-10 17:37:36 +0200
commit18f2e0d3a43641889ac2ba9d7508d47359eec063 (patch)
treeb387228853b068db6aeac707763270a1342f8bdf /fs
parent416bcdbcbbb4800f11f03e8baf570f9996219f67 (diff)
downloadlinux-18f2e0d3a43641889ac2ba9d7508d47359eec063.tar.gz
linux-18f2e0d3a43641889ac2ba9d7508d47359eec063.tar.bz2
linux-18f2e0d3a43641889ac2ba9d7508d47359eec063.zip
fsnotify: Rename fsnotify_clear_marks_by_group_flags()
The _flags() suffix in the function name was more confusing than explaining so just remove it. Also rename the argument from 'flags' to 'type' to better explain what the function expects. Reviewed-by: Miklos Szeredi <mszeredi@redhat.com> Suggested-by: Amir Goldstein <amir73il@gmail.com> Reviewed-by: Amir Goldstein <amir73il@gmail.com> Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs')
-rw-r--r--fs/notify/mark.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/fs/notify/mark.c b/fs/notify/mark.c
index ae33e9f91849..89656abbf4f8 100644
--- a/fs/notify/mark.c
+++ b/fs/notify/mark.c
@@ -67,7 +67,7 @@
* - The fs the inode is on is unmounted. (fsnotify_inode_delete/fsnotify_unmount_inodes)
* - Something explicitly requests that it be removed. (fsnotify_destroy_mark)
* - The fsnotify_group associated with the mark is going away and all such marks
- * need to be cleaned up. (fsnotify_clear_marks_by_group)
+ * need to be cleaned up. (fsnotify_detach_group_marks)
*
* This has the very interesting property of being able to run concurrently with
* any (or all) other directions.
@@ -645,11 +645,9 @@ struct fsnotify_mark *fsnotify_find_mark(
return NULL;
}
-/*
- * clear any marks in a group in which mark->flags & flags is true
- */
-void fsnotify_clear_marks_by_group_flags(struct fsnotify_group *group,
- unsigned int flags)
+/* Clear any marks in a group with given type */
+void fsnotify_clear_marks_by_group(struct fsnotify_group *group,
+ unsigned int type)
{
struct fsnotify_mark *lmark, *mark;
LIST_HEAD(to_free);
@@ -665,7 +663,7 @@ void fsnotify_clear_marks_by_group_flags(struct fsnotify_group *group,
*/
mutex_lock_nested(&group->mark_mutex, SINGLE_DEPTH_NESTING);
list_for_each_entry_safe(mark, lmark, &group->marks_list, g_list) {
- if (mark->connector->flags & flags)
+ if (mark->connector->flags & type)
list_move(&mark->g_list, &to_free);
}
mutex_unlock(&group->mark_mutex);