Fix the kupdate case, which disregards wbc.more_io and stop writeback
prematurely even when there are more inodes to be synced.
wbc.more_io should always be respected.
Also remove the pages_skipped check. It will set when some page(s) of some
inode(s) cannot be written for now. Such inodes will be delayed for a while.
This variable has nothing to do with whether there are other writeable inodes.
CC: Jan Kara <[email protected]>
CC: Dave Chinner <[email protected]>
CC: Peter Zijlstra <[email protected]>
Signed-off-by: Wu Fengguang <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
/*
* If we ran out of stuff to write, bail unless more_io got set
*/
- if (wbc.nr_to_write > 0 || wbc.pages_skipped > 0) {
- if (wbc.more_io && !wbc.for_kupdate) {
+ if (wbc.nr_to_write > 0) {
+ if (wbc.more_io) {
if (wbc.nr_to_write < MAX_WRITEBACK_PAGES)
continue;
/*