summaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2009-02-05 14:33:31 +0100
committerIngo Molnar <mingo@elte.hu>2009-02-05 14:33:31 +0100
commit43769f10b4826376cbf4ce17af74a5b4e8dc4fcd (patch)
tree8a7f36985f9ef8e6771163c751eeefd22ee71693 /mm
parentae7462b4f1fe1f36b5d562dbd5202a2eba01f072 (diff)
parenteda58a85ec3fc05855a26654d97a2b53f0e715b9 (diff)
downloadop-kernel-dev-43769f10b4826376cbf4ce17af74a5b4e8dc4fcd.zip
op-kernel-dev-43769f10b4826376cbf4ce17af74a5b4e8dc4fcd.tar.gz
Merge branches 'tracing/ftrace' and 'linus' into tracing/core
Diffstat (limited to 'mm')
-rw-r--r--mm/page-writeback.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/mm/page-writeback.c b/mm/page-writeback.c
index b493db7..dc32dae 100644
--- a/mm/page-writeback.c
+++ b/mm/page-writeback.c
@@ -1051,13 +1051,22 @@ continue_unlock:
}
}
- if (wbc->sync_mode == WB_SYNC_NONE) {
- wbc->nr_to_write--;
- if (wbc->nr_to_write <= 0) {
- done = 1;
- break;
- }
+ if (nr_to_write > 0)
+ nr_to_write--;
+ else if (wbc->sync_mode == WB_SYNC_NONE) {
+ /*
+ * We stop writing back only if we are not
+ * doing integrity sync. In case of integrity
+ * sync we have to keep going because someone
+ * may be concurrently dirtying pages, and we
+ * might have synced a lot of newly appeared
+ * dirty pages, but have not synced all of the
+ * old dirty pages.
+ */
+ done = 1;
+ break;
}
+
if (wbc->nonblocking && bdi_write_congested(bdi)) {
wbc->encountered_congestion = 1;
done = 1;
OpenPOWER on IntegriCloud