Merge branch 'linux-5.7' of git://github.com/skeggsb/linux into drm-fixes
[linux-2.6-microblaze.git] / include / linux / fsnotify_backend.h
index 337c87c..f0c5064 100644 (file)
@@ -47,6 +47,7 @@
 #define FS_OPEN_PERM           0x00010000      /* open event in an permission hook */
 #define FS_ACCESS_PERM         0x00020000      /* access event in a permissions hook */
 #define FS_OPEN_EXEC_PERM      0x00040000      /* open/exec event in a permission hook */
+#define FS_DIR_MODIFY          0x00080000      /* Directory entry was modified */
 
 #define FS_EXCL_UNLINK         0x04000000      /* do not send events if object is unlinked */
 /* This inode cares about things that happen to its children.  Always set for
@@ -66,7 +67,8 @@
  * The watching parent may get an FS_ATTRIB|FS_EVENT_ON_CHILD event
  * when a directory entry inside a child subdir changes.
  */
-#define ALL_FSNOTIFY_DIRENT_EVENTS     (FS_CREATE | FS_DELETE | FS_MOVE)
+#define ALL_FSNOTIFY_DIRENT_EVENTS     (FS_CREATE | FS_DELETE | FS_MOVE | \
+                                        FS_DIR_MODIFY)
 
 #define ALL_FSNOTIFY_PERM_EVENTS (FS_OPEN_PERM | FS_ACCESS_PERM | \
                                  FS_OPEN_EXEC_PERM)
@@ -132,8 +134,7 @@ struct fsnotify_ops {
  */
 struct fsnotify_event {
        struct list_head list;
-       /* inode may ONLY be dereferenced during handle_event(). */
-       struct inode *inode;    /* either the inode the event happened to or its parent */
+       unsigned long objectid; /* identifier for queue merges */
 };
 
 /*
@@ -526,10 +527,10 @@ extern void fsnotify_finish_user_wait(struct fsnotify_iter_info *iter_info);
 extern bool fsnotify_prepare_user_wait(struct fsnotify_iter_info *iter_info);
 
 static inline void fsnotify_init_event(struct fsnotify_event *event,
-                                      struct inode *inode)
+                                      unsigned long objectid)
 {
        INIT_LIST_HEAD(&event->list);
-       event->inode = inode;
+       event->objectid = objectid;
 }
 
 #else