diff options
| author | Jan Kara <jack@suse.cz> | 2013-04-12 00:03:19 -0400 |
|---|---|---|
| committer | Theodore Ts'o <tytso@mit.edu> | 2013-04-12 00:03:19 -0400 |
| commit | 7b001d6a0c0c7b92e989c2c3b1d8e151f1df1acc (patch) | |
| tree | cc23de7c97919ecdf8e7d6b14b00a345f30d1bfb /fs/ext4 | |
| parent | 4eec708d263f0ee10861d69251708a225b64cac7 (diff) | |
ext4: clear buffer_uninit flag when submitting IO
Currently noone cleared buffer_uninit flag. This results in writeback
needlessly marking io_end as needing extent conversion scanning extent
tree for extents to convert. So clear the buffer_uninit flag once the
buffer is submitted for IO and the flag is transformed into
EXT4_IO_END_UNWRITTEN flag.
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Reviewed-by: Zheng Liu <wenqing.lz@taobao.com>
Diffstat (limited to 'fs/ext4')
| -rw-r--r-- | fs/ext4/page-io.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ext4/page-io.c b/fs/ext4/page-io.c index 14f9837350d1..5929cd0baa20 100644 --- a/fs/ext4/page-io.c +++ b/fs/ext4/page-io.c | |||
| @@ -387,7 +387,7 @@ submit_and_retry: | |||
| 387 | if (ret != bh->b_size) | 387 | if (ret != bh->b_size) |
| 388 | goto submit_and_retry; | 388 | goto submit_and_retry; |
| 389 | io_end = io->io_end; | 389 | io_end = io->io_end; |
| 390 | if (buffer_uninit(bh)) | 390 | if (test_clear_buffer_uninit(bh)) |
| 391 | ext4_set_io_unwritten_flag(inode, io_end); | 391 | ext4_set_io_unwritten_flag(inode, io_end); |
| 392 | io_end->size += bh->b_size; | 392 | io_end->size += bh->b_size; |
| 393 | io->io_next_block++; | 393 | io->io_next_block++; |
