diff options
author | Jan Kara <jack@suse.cz> | 2013-08-17 09:36:54 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-01-29 17:40:57 -0800 |
commit | 23d5efc071f5f47257e5b33c41534a30b1099cc3 (patch) | |
tree | 156f30d41e8bbc9bca36913fe8df1da7b374336c /drivers/pinctrl/pinctrl-ab9540.c | |
parent | 4e9eb2afbc494a56e35bf6c1a621f579eb1199b2 (diff) |
ext4: fix warning in ext4_da_update_reserve_space()
commit 7d7345322d60edb0fa49a64a89b31360f01d09cb upstream.
reaim workfile.dbase test easily triggers warning in
ext4_da_update_reserve_space():
EXT4-fs warning (device ram0): ext4_da_update_reserve_space:365:
ino 12, allocated 1 with only 0 reserved metadata blocks (releasing 1
blocks with reserved 9 data blocks)
The problem is that (one of) tests creates file and then randomly writes
to it with O_SYNC. That results in writing back pages of the file in
random order so we create extents for written blocks say 0, 2, 4, 6, 8
- this last allocation also allocates new block for extents. Then we
writeout block 1 so we have extents 0-2, 4, 6, 8 and we release
indirect extent block because extents fit in the inode again. Then we
writeout block 10 and we need to allocate indirect extent block again
which triggers the warning because we don't have the reservation
anymore.
Fix the problem by giving back freed metadata blocks resulting from
extent merging into inode's reservation pool.
Signed-off-by: Jan Kara <jack@suse.cz>
Cc: Josh Hunt <johunt@akamai.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/pinctrl/pinctrl-ab9540.c')
0 files changed, 0 insertions, 0 deletions