linux/fs/notify
Amir Goldstein 83b535d289 fanotify: support events with data type FSNOTIFY_EVENT_INODE
When event data type is FSNOTIFY_EVENT_INODE, we don't have a refernece
to the mount, so we will not be able to open a file descriptor when user
reads the event. However, if the listener has enabled reporting file
identifier with the FAN_REPORT_FID init flag, we allow reporting those
events and we use an identifier inode to encode fid.

The inode to use as identifier when reporting fid depends on the event.
For dirent modification events, we report the modified directory inode
and we report the "victim" inode otherwise.
For example:
FS_ATTRIB reports the child inode even if reported on a watched parent.
FS_CREATE reports the modified dir inode and not the created inode.

[JK: Fixup condition in fanotify_group_event_mask()]

Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Signed-off-by: Jan Kara <jack@suse.cz>
2019-02-07 16:38:36 +01:00
..
dnotify Merge branch 'siginfo-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2018-08-21 13:47:29 -07:00
fanotify fanotify: support events with data type FSNOTIFY_EVENT_INODE 2019-02-07 16:38:36 +01:00
inotify fsnotify: report FS_ISDIR flag with MOVE_SELF and DELETE_SELF events 2019-02-07 16:38:35 +01:00
fdinfo.c fsnotify/fdinfo: include fdinfo.h for inotify_show_fdinfo() 2018-11-15 17:34:27 +01:00
fdinfo.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
fsnotify.c fsnotify: send all event types to super block marks 2019-02-06 15:20:30 +01:00
fsnotify.h fsnotify: add super block object type 2018-09-03 15:14:01 +02:00
group.c fs: fsnotify: account fsnotify metadata to kmemcg 2018-08-17 16:20:30 -07:00
Kconfig rcu: Make SRCU optional by using CONFIG_SRCU 2015-01-06 11:04:29 -08:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mark.c fanotify: cache fsid in fsnotify_mark_connector 2019-02-07 16:38:35 +01:00
notification.c fsnotify: move mask out of struct fsnotify_event 2019-02-06 15:25:11 +01:00