summaryrefslogtreecommitdiffstats
path: root/fs/fs-writeback.c
diff options
context:
space:
mode:
authorAndrew Morton <akpm@linux-foundation.org>2007-10-17 08:30:37 +0200
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-17 17:43:02 +0200
commit670e4def6ef5f44315d62748134e535b479c784f (patch)
tree808b850c2f08c3d546f6ca06850815324cb770a3 /fs/fs-writeback.c
parentwriteback: fix time ordering of the per superblock dirty inode lists 6 (diff)
downloadlinux-670e4def6ef5f44315d62748134e535b479c784f.tar.xz
linux-670e4def6ef5f44315d62748134e535b479c784f.zip
writeback: fix time ordering of the per superblock dirty inode lists 7
This one fixes four bugs. There are a few situation in there where writeback decides it is going to skip over a blockdev inode on the kernel-internal blockdev superblock. It presently does this by moving the blockdev inode onto the tail of the blockdev superblock's s_dirty. But a) this screws up s_dirty's reverse-time-orderedness and b) refiling the blockdev for writeback in another 30 second is rude. We should try again sooner than that. Fix all this up by using redirty_head(): move the blockdev inode onto the head of the blockdev superblock's s_dirty list for prompt writeback. Cc: Mike Waychison <mikew@google.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/fs-writeback.c')
-rw-r--r--fs/fs-writeback.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
index 30d9383c87c3..39fadfad86f7 100644
--- a/fs/fs-writeback.c
+++ b/fs/fs-writeback.c
@@ -410,14 +410,14 @@ sync_sb_inodes(struct super_block *sb, struct writeback_control *wbc)
wbc->encountered_congestion = 1;
if (!sb_is_blkdev_sb(sb))
break; /* Skip a congested fs */
- list_move(&inode->i_list, &sb->s_dirty);
+ redirty_head(inode);
continue; /* Skip a congested blockdev */
}
if (wbc->bdi && bdi != wbc->bdi) {
if (!sb_is_blkdev_sb(sb))
break; /* fs has the wrong queue */
- list_move(&inode->i_list, &sb->s_dirty);
+ redirty_head(inode);
continue; /* blockdev has wrong queue */
}