Whamcloud - gitweb
LU-6722 ldiskfs: fix credits at ldiskfs_delete_inode
[fs/lustre-release.git] / ldiskfs / kernel_patches / patches / sles11sp2 / export-ext4-3.0.patch
1 ---
2  fs/ext4/balloc.c       |    1 +
3  fs/ext4/ext4.h         |    2 ++
4  fs/ext4/ext4_extents.h |    9 +++++++++
5  fs/ext4/ext4_jbd2.c    |    2 ++
6  fs/ext4/extents.c      |   23 ++++++++++++++++-------
7  fs/ext4/ialloc.c       |    3 ++-
8  fs/ext4/inode.c        |    1 +
9  fs/ext4/mballoc.c      |    4 ++++
10  fs/ext4/super.c        |    9 +++++++++
11  9 files changed, 46 insertions(+), 8 deletions(-)
12
13 Index: linux-stage/fs/ext4/balloc.c
14 ===================================================================
15 --- linux-stage.orig/fs/ext4/balloc.c
16 +++ linux-stage/fs/ext4/balloc.c
17 @@ -231,6 +231,7 @@ struct ext4_group_desc * ext4_get_group_
18                 *bh = sbi->s_group_desc[group_desc];
19         return desc;
20  }
21 +EXPORT_SYMBOL(ext4_get_group_desc);
22  
23  static int ext4_valid_block_bitmap(struct super_block *sb,
24                                         struct ext4_group_desc *desc,
25 Index: linux-stage/fs/ext4/ext4.h
26 ===================================================================
27 --- linux-stage.orig/fs/ext4/ext4.h
28 +++ linux-stage/fs/ext4/ext4.h
29 @@ -1783,6 +1783,8 @@ extern struct inode * ext4_orphan_get(st
30  extern unsigned long ext4_count_free_inodes(struct super_block *);
31  extern unsigned long ext4_count_dirs(struct super_block *);
32  extern void ext4_check_inodes_bitmap(struct super_block *);
33 +extern struct buffer_head *ext4_read_inode_bitmap(struct super_block *sb,
34 +                                                 ext4_group_t block_group);
35  extern void ext4_mark_bitmap_end(int start_bit, int end_bit, char *bitmap);
36  extern int ext4_init_inode_table(struct super_block *sb,
37                                  ext4_group_t group, int barrier);
38 Index: linux-stage/fs/ext4/ext4_extents.h
39 ===================================================================
40 --- linux-stage.orig/fs/ext4/ext4_extents.h
41 +++ linux-stage/fs/ext4/ext4_extents.h
42 @@ -290,5 +290,14 @@ extern struct ext4_ext_path *ext4_ext_fi
43                                                         struct ext4_ext_path *);
44  extern void ext4_ext_drop_refs(struct ext4_ext_path *);
45  extern int ext4_ext_check_inode(struct inode *inode);
46 +extern int ext4_ext_search_right(struct inode *inode,
47 +                                struct ext4_ext_path *path,
48 +                                ext4_lblk_t *logical, ext4_fsblk_t *phys);
49 +extern int ext4_ext_search_left(struct inode *inode,
50 +                               struct ext4_ext_path *path,
51 +                               ext4_lblk_t *logical, ext4_fsblk_t *phys);
52 +extern int ext4_ext_walk_space(struct inode *inode, ext4_lblk_t block,
53 +                               ext4_lblk_t num, ext_prepare_callback func,
54 +                               void *cbdata);
55  #endif /* _EXT4_EXTENTS */
56  
57 Index: linux-stage/fs/ext4/ext4_jbd2.c
58 ===================================================================
59 --- linux-stage.orig/fs/ext4/ext4_jbd2.c
60 +++ linux-stage/fs/ext4/ext4_jbd2.c
61 @@ -19,6 +19,7 @@ int __ext4_journal_get_write_access(cons
62         }
63         return err;
64  }
65 +EXPORT_SYMBOL(__ext4_journal_get_write_access);
66  
67  /*
68   * The ext4 forget function must perform a revoke if we are freeing data
69 @@ -150,3 +151,4 @@ int __ext4_handle_dirty_super(const char
70                 sb->s_dirt = 1;
71         return err;
72  }
73 +EXPORT_SYMBOL(__ext4_handle_dirty_metadata);
74 Index: linux-stage/fs/ext4/extents.c
75 ===================================================================
76 --- linux-stage.orig/fs/ext4/extents.c
77 +++ linux-stage/fs/ext4/extents.c
78 @@ -1236,9 +1236,9 @@ out:
79   * returns 0 at @phys
80   * return value contains 0 (success) or error code
81   */
82 -static int ext4_ext_search_left(struct inode *inode,
83 -                               struct ext4_ext_path *path,
84 -                               ext4_lblk_t *logical, ext4_fsblk_t *phys)
85 +int ext4_ext_search_left(struct inode *inode,
86 +                        struct ext4_ext_path *path,
87 +                        ext4_lblk_t *logical, ext4_fsblk_t *phys)
88  {
89         struct ext4_extent_idx *ix;
90         struct ext4_extent *ex;
91 @@ -1301,9 +1301,9 @@ static int ext4_ext_search_left(struct i
92   * returns 0 at @phys
93   * return value contains 0 (success) or error code
94   */
95 -static int ext4_ext_search_right(struct inode *inode,
96 -                                struct ext4_ext_path *path,
97 -                                ext4_lblk_t *logical, ext4_fsblk_t *phys)
98 +int ext4_ext_search_right(struct inode *inode,
99 +                         struct ext4_ext_path *path,
100 +                         ext4_lblk_t *logical, ext4_fsblk_t *phys)
101  {
102         struct buffer_head *bh = NULL;
103         struct ext4_extent_header *eh;
104 @@ -1878,7 +1878,7 @@ cleanup:
105         return err;
106  }
107  
108 -static int ext4_ext_walk_space(struct inode *inode, ext4_lblk_t block,
109 +extern int ext4_ext_walk_space(struct inode *inode, ext4_lblk_t block,
110                                ext4_lblk_t num, ext_prepare_callback func,
111                                void *cbdata)
112  {
113 @@ -4415,3 +4415,12 @@ int ext4_fiemap(struct inode *inode, str
114  
115         return error;
116  }
117 +
118 +EXPORT_SYMBOL(ext4_ext_search_right);
119 +EXPORT_SYMBOL(ext4_ext_search_left);
120 +EXPORT_SYMBOL(ext4_ext_insert_extent);
121 +EXPORT_SYMBOL(ext4_mb_new_blocks);
122 +EXPORT_SYMBOL(ext4_mark_inode_dirty);
123 +EXPORT_SYMBOL(ext4_ext_walk_space);
124 +EXPORT_SYMBOL(ext4_ext_find_extent);
125 +EXPORT_SYMBOL(ext4_ext_drop_refs);
126 Index: linux-stage/fs/ext4/ialloc.c
127 ===================================================================
128 --- linux-stage.orig/fs/ext4/ialloc.c
129 +++ linux-stage/fs/ext4/ialloc.c
130 @@ -99,7 +99,7 @@ static unsigned ext4_init_inode_bitmap(s
131   *
132   * Return buffer_head of bitmap on success or NULL.
133   */
134 -static struct buffer_head *
135 +struct buffer_head *
136  ext4_read_inode_bitmap(struct super_block *sb, ext4_group_t block_group)
137  {
138         struct ext4_group_desc *desc;
139 @@ -164,6 +164,7 @@ ext4_read_inode_bitmap(struct super_bloc
140         }
141         return bh;
142  }
143 +EXPORT_SYMBOL(ext4_read_inode_bitmap);
144  
145  /*
146   * NOTE! When we get the inode, we're the only people
147 Index: linux-stage/fs/ext4/inode.c
148 ===================================================================
149 --- linux-stage.orig/fs/ext4/inode.c
150 +++ linux-stage/fs/ext4/inode.c
151 @@ -1393,6 +1393,7 @@ int ext4_map_blocks(handle_t *handle, st
152         }
153         return retval;
154  }
155 +EXPORT_SYMBOL(ext4_map_blocks);
156  
157  /* Maximum number of blocks we map for direct IO at once. */
158  #define DIO_MAX_BLOCKS 4096
159 @@ -4689,6 +4690,7 @@ out_stop:
160         ext4_journal_stop(handle);
161         trace_ext4_truncate_exit(inode);
162  }
163 +EXPORT_SYMBOL(ext4_truncate);
164  
165  /*
166   * ext4_get_inode_loc returns with an extra refcount against the inode's
167 @@ -5102,6 +5104,7 @@ bad_inode:
168         iget_failed(inode);
169         return ERR_PTR(ret);
170  }
171 +EXPORT_SYMBOL(ext4_iget);
172  
173  static int ext4_inode_blocks_set(handle_t *handle,
174                                 struct ext4_inode *raw_inode,
175 Index: linux-stage/fs/ext4/mballoc.c
176 ===================================================================
177 --- linux-stage.orig/fs/ext4/mballoc.c
178 +++ linux-stage/fs/ext4/mballoc.c
179 @@ -3856,6 +3856,7 @@ repeat:
180                 call_rcu(&(pa)->u.pa_rcu, ext4_mb_pa_callback);
181         }
182  }
183 +EXPORT_SYMBOL(ext4_discard_preallocations);
184  
185  #ifdef CONFIG_EXT4_DEBUG
186  static void ext4_mb_show_ac(struct ext4_allocation_context *ac)
187 @@ -4976,3 +4977,6 @@ int ext4_trim_fs(struct super_block *sb,
188  
189         return ret;
190  }
191 +
192 +EXPORT_SYMBOL(ext4_free_blocks);
193 +
194 Index: linux-stage/fs/ext4/super.c
195 ===================================================================
196 --- linux-stage.orig/fs/ext4/super.c
197 +++ linux-stage/fs/ext4/super.c
198 @@ -202,6 +202,7 @@ __u32 ext4_itable_unused_count(struct su
199                 (EXT4_DESC_SIZE(sb) >= EXT4_MIN_DESC_SIZE_64BIT ?
200                  (__u32)le16_to_cpu(bg->bg_itable_unused_hi) << 16 : 0);
201  }
202 +EXPORT_SYMBOL(ext4_itable_unused_count);
203  
204  void ext4_block_bitmap_set(struct super_block *sb,
205                            struct ext4_group_desc *bg, ext4_fsblk_t blk)
206 @@ -4280,6 +4282,7 @@ int ext4_force_commit(struct super_block
207  
208         return ret;
209  }
210 +EXPORT_SYMBOL(ext4_force_commit);
211  
212  static void ext4_write_super(struct super_block *sb)
213  {
214 @@ -5210,6 +5213,10 @@ static void __exit ext4_exit_fs(void)
215         ext4_exit_pageio();
216  }
217  
218 +EXPORT_SYMBOL(ext4_bread);
219 +EXPORT_SYMBOL(ext4_journal_start_sb);
220 +EXPORT_SYMBOL(__ext4_journal_stop);
221 +
222  MODULE_AUTHOR("Remy Card, Stephen Tweedie, Andrew Morton, Andreas Dilger, Theodore Ts'o and others");
223  MODULE_DESCRIPTION("Fourth Extended Filesystem");
224  MODULE_LICENSE("GPL");