Whamcloud - gitweb
LU-354 test: Change dev_set_rdonly() check to warning
[fs/lustre-release.git] / lustre / kernel_patches / patches / vfs_races-2.6.32-rhel6.patch
1 Index: linux-2.6.32-71.18.1.el6/fs/dcache.c
2 ===================================================================
3 --- linux-2.6.32-71.18.1.el6.orig/fs/dcache.c
4 +++ linux-2.6.32-71.18.1.el6/fs/dcache.c
5 @@ -280,6 +280,13 @@ int d_invalidate(struct dentry * dentry)
6                 spin_unlock(&dcache_lock);
7                 return 0;
8         }
9 +
10 +       /* network invalidation by Lustre */
11 +       if (dentry->d_flags & DCACHE_LUSTRE_INVALID) {
12 +               spin_unlock(&dcache_lock);
13 +               return 0;
14 +       }
15 +
16         /*
17          * Check whether to do a partial shrink_dcache
18          * to get rid of unused child entries.
19 Index: linux-2.6.32-71.18.1.el6/include/linux/dcache.h
20 ===================================================================
21 --- linux-2.6.32-71.18.1.el6.orig/include/linux/dcache.h
22 +++ linux-2.6.32-71.18.1.el6/include/linux/dcache.h
23 @@ -185,6 +185,7 @@ d_iput:             no              no              no       yes
24  #define DCACHE_MANAGE_TRANSIT  0x40000 /* manage transit from this dirent */
25  #define DCACHE_MANAGED_DENTRY \
26         (DCACHE_MOUNTED|DCACHE_NEED_AUTOMOUNT|DCACHE_MANAGE_TRANSIT)
27 +#define DCACHE_LUSTRE_INVALID  0x4000000  /* Lustre invalidated */
28  
29  extern spinlock_t dcache_lock;
30  extern seqlock_t rename_lock;