vfs: move fsnotify junk to struct mount
[deliverable/linux.git] / fs / notify / fsnotify.c
index 79b47cbb5cd82e8e89bf96de095bf76bcd2c0c47..ccb14d3fc0de99790d282ae17ce984338ca309ab 100644 (file)
@@ -26,6 +26,7 @@
 
 #include <linux/fsnotify_backend.h>
 #include "fsnotify.h"
+#include "../mount.h"
 
 /*
  * Clear all of the marks on an inode when it is being evicted from core
@@ -205,13 +206,13 @@ int fsnotify(struct inode *to_tell, __u32 mask, void *data, int data_is,
        struct fsnotify_mark *inode_mark = NULL, *vfsmount_mark = NULL;
        struct fsnotify_group *inode_group, *vfsmount_group;
        struct fsnotify_event *event = NULL;
-       struct vfsmount *mnt;
+       struct mount *mnt;
        int idx, ret = 0;
        /* global tests shouldn't care about events on child only the specific event */
        __u32 test_mask = (mask & ~FS_EVENT_ON_CHILD);
 
        if (data_is == FSNOTIFY_EVENT_PATH)
-               mnt = ((struct path *)data)->mnt;
+               mnt = real_mount(((struct path *)data)->mnt);
        else
                mnt = NULL;
 
@@ -262,11 +263,11 @@ int fsnotify(struct inode *to_tell, __u32 mask, void *data, int data_is,
                        /* we didn't use the vfsmount_mark */
                        vfsmount_group = NULL;
                } else if (vfsmount_group > inode_group) {
-                       ret = send_to_group(to_tell, mnt, NULL, vfsmount_mark, mask, data,
+                       ret = send_to_group(to_tell, &mnt->mnt, NULL, vfsmount_mark, mask, data,
                                            data_is, cookie, file_name, &event);
                        inode_group = NULL;
                } else {
-                       ret = send_to_group(to_tell, mnt, inode_mark, vfsmount_mark,
+                       ret = send_to_group(to_tell, &mnt->mnt, inode_mark, vfsmount_mark,
                                            mask, data, data_is, cookie, file_name,
                                            &event);
                }
This page took 0.026175 seconds and 5 git commands to generate.