]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: block2mtd: throttle writes by calling balance_dirty_pages_ratelimited.
authorNeilBrown <neilb@suse.de>
Wed, 12 Dec 2012 08:32:15 +0000 (19:32 +1100)
committerArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Thu, 13 Dec 2012 11:39:44 +0000 (13:39 +0200)
commit910f901fa2ae442f658ee3ae3945f9ec506a1906
tree450de5893032902a23a09a7373e24e51cb8297ae
parent28c1aff000744dbbe0c1081747818b8bf84de994
mtd: block2mtd: throttle writes by calling balance_dirty_pages_ratelimited.

If you create a block2mtd device that is larger than main memory,
and write to all of it, then lots of pages will be dirtied but
they will never be flushed out as nothing calls any variant of
balance_dirty_pages.

It would be nice to call set_page_dirty_balance(), but that isn't exported,
so just call balance_dirty_pages_ratelimited() directly.

Signed-off-by: NeilBrown <neilb@suse.de>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
drivers/mtd/devices/block2mtd.c