All of lore.kernel.org
 help / color / mirror / Atom feed
* [patch]mm: add more blk plug
@ 2011-09-26  2:30 Shaohua Li
  2011-09-26  7:30 ` Christoph Hellwig
  0 siblings, 1 reply; 12+ messages in thread
From: Shaohua Li @ 2011-09-26  2:30 UTC (permalink / raw)
  To: Jens Axboe; +Cc: Andrew Morton, Christoph Hellwig, lkml

Some filesystems implement .writepages. We don't have blk plug
in such filesystems for .writepages.

Signed-off-by: Shaohua Li <shaohua.li@intel.com>

diff --git a/mm/page-writeback.c b/mm/page-writeback.c
index 0e309cd..b9e73a1 100644
--- a/mm/page-writeback.c
+++ b/mm/page-writeback.c
@@ -1253,13 +1253,16 @@ EXPORT_SYMBOL(generic_writepages);
 int do_writepages(struct address_space *mapping, struct writeback_control *wbc)
 {
 	int ret;
+	struct blk_plug plug;
 
 	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;
 }
 



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

end of thread, other threads:[~2011-10-12  0:46 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-26  2:30 [patch]mm: add more blk plug Shaohua Li
2011-09-26  7:30 ` Christoph Hellwig
2011-09-26  7:38   ` Shaohua Li
2011-09-26  9:45     ` Christoph Hellwig
2011-09-28  3:09       ` [patch]ext4: add block plug for .writepages Shaohua Li
2011-10-09  6:09         ` Shaohua Li
2011-10-10 16:51         ` Ted Ts'o
2011-10-11  0:07           ` NamJae Jeon
2011-10-11  0:07             ` NamJae Jeon
2011-10-11 10:40           ` Kyungmin Park
2011-10-11 10:40             ` Kyungmin Park
2011-10-12  0:53             ` Shaohua Li

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.