]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[XFS] Check that a page has dirty buffers before finding it acceptable for
authorDavid Chinner <dgc@sgi.com>
Wed, 22 Mar 2006 01:47:40 +0000 (12:47 +1100)
committerNathan Scott <nathans@sgi.com>
Wed, 22 Mar 2006 01:47:40 +0000 (12:47 +1100)
rewrite clustering. This prevents writing excessive amounts of clean data
when doing random rewrites of a cached file.

SGI-PV: 951193
SGI-Modid: xfs-linux-melb:xfs-kern:25531a

Signed-off-by: David Chinner <dgc@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
fs/xfs/linux-2.6/xfs_aops.c

index 965757cf15e9397afc6684f12bc240b89ce382ef..97fc056130ebe981ec119964dd0be95e4523643b 100644 (file)
@@ -647,7 +647,7 @@ xfs_is_delayed_page(
                                acceptable = (type == IOMAP_UNWRITTEN);
                        else if (buffer_delay(bh))
                                acceptable = (type == IOMAP_DELAY);
-                       else if (buffer_mapped(bh))
+                       else if (buffer_dirty(bh) && buffer_mapped(bh))
                                acceptable = (type == 0);
                        else
                                break;