1 diff -rupN linux-2.6.7/fs/namei.c linux-2.6.7.new/fs/namei.c
2 --- linux-2.6.7/fs/namei.c 2005-03-29 18:54:13.000000000 +0300
3 +++ linux-2.6.7.new/fs/namei.c 2005-03-31 14:42:01.605302456 +0300
4 @@ -422,6 +422,16 @@ static struct dentry * real_lookup(struc
8 + if (!IS_ERR(result)) {
9 + spin_lock(&result->d_lock);
10 + if (result->d_flags & DCACHE_GNS_PENDING) {
11 + spin_unlock(&result->d_lock);
12 + if (result->d_op && result->d_op->d_revalidate)
13 + result->d_op->d_revalidate(result, nd);
15 + spin_unlock(&result->d_lock);
21 diff -rupN linux-2.6.7/fs/namespace.c linux-2.6.7.new/fs/namespace.c
22 --- linux-2.6.7/fs/namespace.c 2005-03-29 18:54:13.000000000 +0300
23 +++ linux-2.6.7.new/fs/namespace.c 2005-03-30 17:51:39.000000000 +0300
24 @@ -60,6 +60,7 @@ struct vfsmount *alloc_vfsmnt(const char
25 INIT_LIST_HEAD(&mnt->mnt_child);
26 INIT_LIST_HEAD(&mnt->mnt_mounts);
27 INIT_LIST_HEAD(&mnt->mnt_list);
28 + INIT_LIST_HEAD(&mnt->mnt_lustre_list);
30 int size = strlen(name)+1;
31 char *newname = kmalloc(size, GFP_KERNEL);
32 @@ -173,6 +174,9 @@ void __mntput(struct vfsmount *mnt)
34 struct super_block *sb = mnt->mnt_sb;
36 + spin_lock(&dcache_lock);
37 + list_del(&mnt->mnt_lustre_list);
38 + spin_unlock(&dcache_lock);
42 diff -rupN linux-2.6.7/include/linux/dcache.h linux-2.6.7.new/include/linux/dcache.h
43 --- linux-2.6.7/include/linux/dcache.h 2005-03-29 18:54:13.000000000 +0300
44 +++ linux-2.6.7.new/include/linux/dcache.h 2005-03-31 14:35:51.589553400 +0300
45 @@ -167,7 +167,9 @@ d_iput: no no no yes
46 #define DCACHE_UNHASHED 0x0010
47 #define DCACHE_LUSTRE_INVALID 0x0020 /* invalidated by Lustre */
49 -#define DCACHE_CROSS_REF 0x0040 /* entry points to inode on another MDS */
50 +#define DCACHE_CROSS_REF 0x0040 /* entry points to inode on another MDS */
51 +#define DCACHE_GNS_PENDING 0x0080 /* entry is GNS pending mount point */
52 +#define DCACHE_GNS_MOUNTING 0x0100 /* entry is GNS mount in progress */
54 extern spinlock_t dcache_lock;