1 Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ext4.h
2 ===================================================================
3 --- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/ext4.h
4 +++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ext4.h
5 @@ -1427,6 +1427,8 @@ static inline void ext4_clear_state_flag
7 #define NEXT_ORPHAN(inode) EXT4_I(inode)->i_dtime
9 +#define JOURNAL_START_HAS_3ARGS 1
12 * Codes for operating systems
14 @@ -1527,7 +1427,21 @@ static inline void ext4_clear_state_flag
18 -EXTN_FEATURE_FUNCS(4)
19 +static inline bool ext4_has_unknown_ext4_compat_features(struct super_block *sb)
21 + return ((EXT4_SB(sb)->s_es->s_feature_compat &
22 + cpu_to_le32(~EXT4_FEATURE_COMPAT_SUPP)) != 0);
24 +static inline bool ext4_has_unknown_ext4_ro_compat_features(struct super_block *sb)
26 + return ((EXT4_SB(sb)->s_es->s_feature_ro_compat &
27 + cpu_to_le32(~EXT4_FEATURE_RO_COMPAT_SUPP)) != 0);
29 +static inline bool ext4_has_unknown_ext4_incompat_features(struct super_block *sb)
31 + return ((EXT4_SB(sb)->s_es->s_feature_incompat &
32 + cpu_to_le32(~EXT4_FEATURE_INCOMPAT_SUPP)) != 0);
35 static inline bool ext4_has_compat_features(struct super_block *sb)
37 @@ -2612,6 +2614,11 @@ struct ext4_extent;
39 extern int ext4_ext_tree_init(handle_t *handle, struct inode *);
40 extern int ext4_ext_writepage_trans_blocks(struct inode *, int);
41 +extern struct buffer_head *ext4_read_inode_bitmap(struct super_block *sb,
42 + ext4_group_t block_group);
43 +extern struct buffer_head *ext4_append(handle_t *handle,
44 + struct inode *inode,
45 + ext4_lblk_t *block);
46 extern int ext4_ext_index_trans_blocks(struct inode *inode, int extents);
48 extern int ext4_ext_map_blocks(handle_t *handle, struct inode *inode,
49 Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/namei.c
50 ===================================================================
51 --- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/namei.c
52 +++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/namei.c
54 #define NAMEI_RA_BLOCKS 4
55 #define NAMEI_RA_SIZE (NAMEI_RA_CHUNKS * NAMEI_RA_BLOCKS)
57 -static struct buffer_head *ext4_append(handle_t *handle,
58 +struct buffer_head *ext4_append(handle_t *handle,
62 @@ -155,6 +155,7 @@ static struct buffer_head *__ext4_read_d
66 +EXPORT_SYMBOL(ext4_append);
69 #define assert(test) J_ASSERT(test)
70 @@ -2210,7 +2211,7 @@ out:
71 * DIR_NLINK feature is set if 1) nlinks > EXT4_LINK_MAX or 2) nlinks == 2,
72 * since this indicates that nlinks count was previously 1.
74 -static void ext4_inc_count(handle_t *handle, struct inode *inode)
75 +void ext4_inc_count(handle_t *handle, struct inode *inode)
78 if (is_dx(inode) && inode->i_nlink > 1) {
79 @@ -2222,16 +2223,18 @@ static void ext4_inc_count(handle_t *han
83 +EXPORT_SYMBOL(ext4_inc_count);
86 * If a directory had nlink == 1, then we should let it be 1. This indicates
87 * directory has >EXT4_LINK_MAX subdirs.
89 -static void ext4_dec_count(handle_t *handle, struct inode *inode)
90 +void ext4_dec_count(handle_t *handle, struct inode *inode)
92 if (!S_ISDIR(inode->i_mode) || inode->i_nlink > 2)
95 +EXPORT_SYMBOL(ext4_dec_count);
98 static int ext4_add_nondir(handle_t *handle,
99 Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ialloc.c
100 ===================================================================
101 --- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/ialloc.c
102 +++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/ialloc.c
103 @@ -111,7 +111,7 @@ void ext4_end_bitmap_read(struct buffer_
105 * Return buffer_head of bitmap on success or NULL.
107 -static struct buffer_head *
108 +struct buffer_head *
109 ext4_read_inode_bitmap(struct super_block *sb, ext4_group_t block_group)
111 struct ext4_group_desc *desc;
112 @@ -191,6 +191,7 @@ verify:
113 set_buffer_verified(bh);
116 +EXPORT_SYMBOL(ext4_read_inode_bitmap);
119 * NOTE! When we get the inode, we're the only people
120 Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/inode.c
121 ===================================================================
122 --- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/inode.c
123 +++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/inode.c
124 @@ -5281,3 +5281,17 @@ out:
125 sb_end_pagefault(inode->i_sb);
128 +EXPORT_SYMBOL(ext4_map_blocks);
129 +EXPORT_SYMBOL(ext4_truncate);
130 +EXPORT_SYMBOL(ext4_iget);
131 +EXPORT_SYMBOL(ext4_bread);
132 +EXPORT_SYMBOL(ext4_itable_unused_count);
133 +EXPORT_SYMBOL(ext4_force_commit);
134 +EXPORT_SYMBOL(ext4_mark_inode_dirty);
135 +EXPORT_SYMBOL(ext4_get_group_desc);
136 +EXPORT_SYMBOL(__ext4_journal_get_write_access);
137 +EXPORT_SYMBOL(__ext4_journal_start_sb);
138 +EXPORT_SYMBOL(__ext4_journal_stop);
139 +EXPORT_SYMBOL(__ext4_handle_dirty_metadata);
140 +EXPORT_SYMBOL(__ext4_std_error);
141 +EXPORT_SYMBOL(ext4fs_dirhash);
142 Index: linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/mballoc.c
143 ===================================================================
144 --- linux-3.10.0-123.13.2.el7.x86_64.orig/fs/ext4/mballoc.c
145 +++ linux-3.10.0-123.13.2.el7.x86_64/fs/ext4/mballoc.c
146 @@ -5281,7 +5281,6 @@ out:
147 void *buddy, void *bitmap, ext4_group_t group)
149 struct ext4_group_info *grp = ext4_get_group_info(sb, group);
150 - struct ext4_sb_info *sbi = EXT4_SB(sb);
151 ext4_grpblk_t max = EXT4_CLUSTERS_PER_GROUP(sb);