diff options
author | Wu Fengguang <fengguang.wu@intel.com> | 2010-08-11 17:17:42 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-08-12 11:43:30 -0400 |
commit | 4ea879b96d437693485d21f4b7e1eb72f7615fc2 (patch) | |
tree | 142899843f2ce27334dbd134cd1bab3058cc8028 /fs/fs-writeback.c | |
parent | 23539afc71937dbaca7de2229669f4475ff4ea7b (diff) |
writeback: fix queue_io() ordering
This was not a bug, since b_io is empty for kupdate writeback. The next
patch will do requeue_io() for non-kupdate writeback, so let's fix it.
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Martin Bligh <mbligh@google.com>
Cc: Michael Rubin <mrubin@google.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Christoph Hellwig <hch@infradead.org>
Cc: Jens Axboe <axboe@kernel.dk>
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.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 1ce364bbb003..863bfb0eb492 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c | |||
@@ -249,10 +249,18 @@ static void move_expired_inodes(struct list_head *delaying_queue, | |||
249 | 249 | ||
250 | /* | 250 | /* |
251 | * Queue all expired dirty inodes for io, eldest first. | 251 | * Queue all expired dirty inodes for io, eldest first. |
252 | * Before | ||
253 | * newly dirtied b_dirty b_io b_more_io | ||
254 | * =============> gf edc BA | ||
255 | * After | ||
256 | * newly dirtied b_dirty b_io b_more_io | ||
257 | * =============> g fBAedc | ||
258 | * | | ||
259 | * +--> dequeue for IO | ||
252 | */ | 260 | */ |
253 | static void queue_io(struct bdi_writeback *wb, unsigned long *older_than_this) | 261 | static void queue_io(struct bdi_writeback *wb, unsigned long *older_than_this) |
254 | { | 262 | { |
255 | list_splice_init(&wb->b_more_io, wb->b_io.prev); | 263 | list_splice_init(&wb->b_more_io, &wb->b_io); |
256 | move_expired_inodes(&wb->b_dirty, &wb->b_io, older_than_this); | 264 | move_expired_inodes(&wb->b_dirty, &wb->b_io, older_than_this); |
257 | } | 265 | } |
258 | 266 | ||