fsnotify: fold fsnotify() call into fsnotify_parent()
authorAmir Goldstein <amir73il@gmail.com>
Wed, 8 Jul 2020 11:11:37 +0000 (14:11 +0300)
committerJan Kara <jack@suse.cz>
Wed, 15 Jul 2020 15:36:41 +0000 (17:36 +0200)
commitc738fbabb0ff62d0f9a9572e56e65d05a1b34c6a
tree3bd2d3996e88cfe74a51e4403ef67108365de1b6
parent71d734103edfa2b4c6657578a3082ee0e51d767e
fsnotify: fold fsnotify() call into fsnotify_parent()

All (two) callers of fsnotify_parent() also call fsnotify() to notify
the child inode. Move the second fsnotify() call into fsnotify_parent().

This will allow more flexibility in making decisions about which of the
two event falvors should be sent.

Using 'goto notify_child' in the inline helper seems a bit strange, but
it mimics the code in __fsnotify_parent() for clarity and the goto
pattern will become less strage after following patches are applied.

Link: https://lore.kernel.org/r/20200708111156.24659-2-amir73il@gmail.com
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/notify/fsnotify.c
include/linux/fsnotify.h