]> git.baikalelectronics.ru Git - kernel.git/commit
laptop-mode: Make flushes per-device
authorMatthew Garrett <mjg@redhat.com>
Tue, 6 Apr 2010 12:25:14 +0000 (14:25 +0200)
committerJens Axboe <jens.axboe@oracle.com>
Tue, 6 Apr 2010 12:25:14 +0000 (14:25 +0200)
commit43563716640d24f85101814ffb2b0507caa49cdf
tree38cd9896cfc6ce106a03431658a9b98a09129034
parent2a6051e0b8f6e8a5bee7842ad8b2a9d2aa5d6fa6
laptop-mode: Make flushes per-device

One of the features of laptop-mode is that it forces a writeout of dirty
pages if something else triggers a physical read or write from a device.
The current implementation flushes pages on all devices, rather than only
the one that triggered the flush. This patch alters the behaviour so that
only the recently accessed block device is flushed, preventing other
disks being spun up for no terribly good reason.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
block/blk-core.c
include/linux/backing-dev.h
include/linux/writeback.h
mm/page-writeback.c