fs: don't flush pagecache when expanding block device
authorshunki-fujita <[email protected]>
Thu, 5 Apr 2018 23:20:07 +0000 (16:20 -0700)
committerLinus Torvalds <[email protected]>
Fri, 6 Apr 2018 04:36:23 +0000 (21:36 -0700)
commit849cf55963dfd877ad92996195e0fe7218eaf0e9
tree3c1dab29c873beb615163ff832024b3c9e09752e
parent9421c3e64137ec69e5cf4ed024dc777a09b7779f
fs: don't flush pagecache when expanding block device

When changing the size of a block device, its all caches are freed.
It's necessary on shrinking to prevent spurious I/Os to the disappeared
region.  However, on expanding, such kind of I/Os doesn't happen.

Similar things can be considered for btrfs filesystem resize and
resize2fs, but they are designed not to drop caches when expanding.
Therefore this patch removes unnecessary cache drop.

Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Shunki Fujita <[email protected]>
Cc: Al Viro <[email protected]>
Cc: Jens Axboe <[email protected]>
Cc: Jan Kara <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
fs/block_dev.c