]> git.baikalelectronics.ru Git - kernel.git/commit
ext4: prevent online resize with backup superblock
authorTheodore Ts'o <tytso@mit.edu>
Sat, 27 Dec 2014 04:58:21 +0000 (23:58 -0500)
committerTheodore Ts'o <tytso@mit.edu>
Sat, 27 Dec 2014 04:58:21 +0000 (23:58 -0500)
commit8ce6578cc52b95b31e930f4043a07f7edce304c1
tree09233f55cd3aa55cf779f684cd1968cc36a08437
parentfccd070ba0ad3eb26c0161ee4bb318365c39f8a0
ext4: prevent online resize with backup superblock

Prevent BUG or corrupted file systems after the following:

mkfs.ext4 /dev/vdc 100M
mount -t ext4 -o sb=40961 /dev/vdc /vdc
resize2fs /dev/vdc

We previously prevented online resizing using the old resize ioctl.
Move the code to ext4_resize_begin(), so the check applies for all of
the resize ioctl's.

Reported-by: Maxim Malkov <malkov@ispras.ru>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/resize.c