Whamcloud - gitweb
b=22514 kernel update for rhel5.5 & oel5.5.
[fs/lustre-release.git] / ldiskfs / kernel_patches / patches / ext4-ext_generation-sles11.patch
1 Index: linux-2.6.27.21-0.1/fs/ext4/ext4_extents.h
2 ===================================================================
3 --- linux-2.6.27.21-0.1.orig/fs/ext4/ext4_extents.h     2009-07-07 14:47:22.000000000 +0530
4 +++ linux-2.6.27.21-0.1/fs/ext4/ext4_extents.h  2009-07-07 14:49:31.000000000 +0530
5 @@ -203,6 +203,11 @@
6         return le16_to_cpu(ext_inode_hdr(inode)->eh_depth);
7  }
8  
9 +static inline void ext4_ext_tree_changed(struct inode *inode)
10 +{
11 +       EXT4_I(inode)->i_ext_generation++;
12 +}
13 +
14  static inline void
15  ext4_ext_invalidate_cache(struct inode *inode)
16  {
17 Index: linux-2.6.27.21-0.1/fs/ext4/ext4.h
18 ===================================================================
19 --- linux-2.6.27.21-0.1.orig/fs/ext4/ext4.h     2009-07-07 14:47:13.000000000 +0530
20 +++ linux-2.6.27.21-0.1/fs/ext4/ext4.h  2009-07-07 14:50:07.000000000 +0530
21 @@ -114,6 +114,7 @@
22         struct inode vfs_inode;
23         struct jbd2_inode jinode;
24  
25 +       unsigned long i_ext_generation;
26         struct ext4_ext_cache i_cached_extent;
27         /*
28          * File creation time. Its function is same as that of
29 Index: linux-2.6.27.21-0.1/fs/ext4/extents.c
30 ===================================================================
31 --- linux-2.6.27.21-0.1.orig/fs/ext4/extents.c  2009-07-07 14:48:03.000000000 +0530
32 +++ linux-2.6.27.21-0.1/fs/ext4/extents.c       2009-07-07 14:48:58.000000000 +0530
33 @@ -1618,6 +1618,7 @@
34                 ext4_ext_drop_refs(npath);
35                 kfree(npath);
36         }
37 +       ext4_ext_tree_changed(inode);
38         ext4_ext_invalidate_cache(inode);
39         return err;
40  }
41 @@ -2279,6 +2280,7 @@
42                 }
43         }
44  out:
45 +       ext4_ext_tree_changed(inode);
46         ext4_ext_drop_refs(path);
47         kfree(path);
48         ext4_journal_stop(handle);