linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/2] mm: make do_writepages() use plugging
@ 2012-02-03 13:27 Amit Sahrawat
  2012-02-03 13:32 ` Peter Zijlstra
  2012-02-03 13:38 ` Wu Fengguang
  0 siblings, 2 replies; 7+ messages in thread
From: Amit Sahrawat @ 2012-02-03 13:27 UTC (permalink / raw)
  To: Wu Fengguang, Jan Kara, Andrew Morton, Peter Zijlstra,
	Johannes Weiner
  Cc: Amit Sahrawat, linux-mm, linux-kernel, Amit Sahrawat

This will cover all the invocations for writepages to be called with
plugging support.

Signed-off-by: Amit Sahrawat <a.sahrawat@samsung.com>
---
 mm/page-writeback.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/mm/page-writeback.c b/mm/page-writeback.c
index 363ba70..2bea32c 100644
--- a/mm/page-writeback.c
+++ b/mm/page-writeback.c
@@ -1866,14 +1866,18 @@ EXPORT_SYMBOL(generic_writepages);
 
 int do_writepages(struct address_space *mapping, struct writeback_control *wbc)
 {
+	struct blk_plug plug;
 	int ret;
 
 	if (wbc->nr_to_write <= 0)
 		return 0;
+
+	blk_start_plug(&plug);
 	if (mapping->a_ops->writepages)
 		ret = mapping->a_ops->writepages(mapping, wbc);
 	else
 		ret = generic_writepages(mapping, wbc);
+	blk_finish_plug(&plug);
 	return ret;
 }
 
-- 
1.7.2.3

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-02-03 14:35 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-03 13:27 [PATCH 2/2] mm: make do_writepages() use plugging Amit Sahrawat
2012-02-03 13:32 ` Peter Zijlstra
2012-02-03 14:01   ` Amit Sahrawat
2012-02-03 14:11     ` Amit Sahrawat
2012-02-03 13:38 ` Wu Fengguang
2012-02-03 14:08   ` Christoph Hellwig
2012-02-03 14:21     ` Chris Mason

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).