Commit f01bb82f authored by Theodore Ts'o's avatar Theodore Ts'o Committed by Ben Hutchings
Browse files

ext4: add more paranoia checking in ext4_expand_extra_isize handling

commit 4ea99936 upstream.

It's possible to specify a non-zero s_want_extra_isize via debugging
option, and this can cause bad things(tm) to happen when using a file
system with an inode size of 128 bytes.

Add better checking when the file system is mounted, as well as when
we are actually doing the trying to do the inode expansion.

Link: https://lore.kernel.org/r/20191110121510.GH23325@mit.edu


Reported-by: default avatar <syzbot+f8d6f8386ceacdbfff57@syzkaller.appspotmail.com>
Reported-by: default avatar <syzbot+33d7ea72e47de3bdf4e1@syzkaller.appspotmail.com>
Reported-by: default avatar <syzbot+44b6763edfc17144296f@syzkaller.appspotmail.com>
Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
[bwh: Backported to 3.16:
 - Use EIO instead of EFSCORRUPTED
 - Adjust context]
Signed-off-by: default avatarBen Hutchings <ben@decadent.org.uk>
parent 1bbf3c86
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment