diff options
author | Lukas Czerner <lczerner@redhat.com> | 2015-06-08 11:18:52 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2015-06-08 11:18:52 -0400 |
commit | 41e5b7ed3e9597ccc46b6affc81872e6370936d9 (patch) | |
tree | d431ec519ef7a3735a65cc69d4722693735e8799 /fs/ext4/mballoc.c | |
parent | 6ccaf3e2f302b6af8d9e17ce4e7f0af26b6baa0e (diff) | |
download | lwn-41e5b7ed3e9597ccc46b6affc81872e6370936d9.tar.gz lwn-41e5b7ed3e9597ccc46b6affc81872e6370936d9.zip |
ext4: verify block bitmap even after fresh initialization
If we want to rely on the buffer_verified() flag of the block bitmap
buffer, we have to set it consistently. However currently if we're
initializing uninitialized block bitmap in
ext4_read_block_bitmap_nowait() we're not going to set buffer verified
at all.
We can do this by simply setting the flag on the buffer, but I think
it's actually better to run ext4_validate_block_bitmap() to make sure
that what we did in the ext4_init_block_bitmap() is right.
So run ext4_validate_block_bitmap() even after the block bitmap
initialization. Also bail out early from ext4_validate_block_bitmap() if
we see corrupt bitmap, since we already know it's corrupt and we do not
need to verify that.
Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'fs/ext4/mballoc.c')
0 files changed, 0 insertions, 0 deletions