Skip to content

Commit e647e29

Browse files
ruippan (潘睿)tytso
authored andcommitted
ext4: fix EXT4_IOC_GROUP_ADD ioctl
Commit e2b911c ("ext4: clean up feature test macros with predicate functions") broke the EXT4_IOC_GROUP_ADD ioctl. This was not noticed since only very old versions of resize2fs (before e2fsprogs 1.42) use this ioctl. However, using a new kernel with an enterprise Linux userspace will cause attempts to use online resize to fail with "No reserved GDT blocks". Fixes: e2b911c ("ext4: clean up feature test macros with predicate...") Cc: stable@kernel.org # v4.4 Signed-off-by: Theodore Ts'o <tytso@mit.edu> Signed-off-by: ruippan (潘睿) <ruippan@tencent.com>
1 parent 361d24d commit e647e29

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎fs/ext4/resize.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1631,7 +1631,7 @@ int ext4_group_add(struct super_block *sb, struct ext4_new_group_data *input)
16311631
}
16321632

16331633
if (reserved_gdb || gdb_off == 0) {
1634-
if (ext4_has_feature_resize_inode(sb) ||
1634+
if (!ext4_has_feature_resize_inode(sb) ||
16351635
!le16_to_cpu(es->s_reserved_gdt_blocks)) {
16361636
ext4_warning(sb,
16371637
"No reserved GDT blocks, can't resize");

0 commit comments

Comments
 (0)