Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ext4: report real fs size after failed resize

Currently when the file system resize using ext4_resize_fs() fails it
will report into log that "resized filesystem to <requested block
count>". However this may not be true in the case of failure. Use the
current block count as returned by ext4_blocks_count() to report the
block count.

Additionally, report a warning that "error occurred during file system
resize"

Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>

authored by

Lukas Czerner and committed by
Theodore Ts'o
6c732840 d64264d6

+5 -1
+5 -1
fs/ext4/resize.c
··· 2080 2080 free_flex_gd(flex_gd); 2081 2081 if (resize_inode != NULL) 2082 2082 iput(resize_inode); 2083 - ext4_msg(sb, KERN_INFO, "resized filesystem to %llu", n_blocks_count); 2083 + if (err) 2084 + ext4_warning(sb, "error (%d) occurred during " 2085 + "file system resize", err); 2086 + ext4_msg(sb, KERN_INFO, "resized filesystem to %llu", 2087 + ext4_blocks_count(es)); 2084 2088 return err; 2085 2089 }