diff options
author | Jens Axboe <jaxboe@fusionio.com> | 2011-04-12 10:28:28 +0200 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2011-04-12 10:28:28 +0200 |
commit | dc6d36c9710d1fed42d1bbe7d8e4f742abd844c6 (patch) | |
tree | 88062deeeb7f8d6973056422f08d47f8c5a27c51 /block/blk-core.c | |
parent | f75664570d8b75469cc468f23c2b27220984983b (diff) | |
download | kernel_goldelico_gta04-dc6d36c9710d1fed42d1bbe7d8e4f742abd844c6.zip kernel_goldelico_gta04-dc6d36c9710d1fed42d1bbe7d8e4f742abd844c6.tar.gz kernel_goldelico_gta04-dc6d36c9710d1fed42d1bbe7d8e4f742abd844c6.tar.bz2 |
block: readd plug trace event
This was removed with the queue plug state. But we can easily readd
by checking if this is the first request going to this queue. It's
good information to have when tracing to see how effective the
plugging is.
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'block/blk-core.c')
-rw-r--r-- | block/blk-core.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/block/blk-core.c b/block/blk-core.c index 76850fc..52e756c 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -1311,7 +1311,15 @@ get_rq: plug = current->plug; if (plug) { - if (!plug->should_sort && !list_empty(&plug->list)) { + /* + * If this is the first request added after a plug, fire + * of a plug trace. If others have been added before, check + * if we have multiple devices in this plug. If so, make a + * note to sort the list before dispatch. + */ + if (list_empty(&plug->list)) + trace_block_plug(q); + else if (!plug->should_sort) { struct request *__rq; __rq = list_entry_rq(plug->list.prev); |