]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm: write_cache_pages optimise page cleaning
authorNick Piggin <npiggin@suse.de>
Tue, 6 Jan 2009 22:39:10 +0000 (14:39 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Sun, 25 Jan 2009 00:41:47 +0000 (16:41 -0800)
commiteac622ef3017044053f24584f5aa233d069078f7
tree1ef1c1e52c07c9d66563bd93aeb296712b692bef
parent281616c6c99df546abaa8182fd0785ddc79b096a
mm: write_cache_pages optimise page cleaning

commit 515f4a037fb9ab736f8bad733fcd2ffd350cf265 upstream.

In write_cache_pages, if we get stuck behind another process that is
cleaning pages, we will be forced to wait for them to finish, then perform
our own writeout (if it was redirtied during the long wait), then wait for
that.

If a page under writeout is still clean, we can skip waiting for it (if
we're part of a data integrity sync, we'll be waiting for all writeout
pages afterwards, so we'll still be waiting for the other guy's write
that's cleaned the page).

Signed-off-by: Nick Piggin <npiggin@suse.de>
Cc: Chris Mason <chris.mason@oracle.com>
Cc: Dave Chinner <david@fromorbit.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
mm/page-writeback.c