]> git.baikalelectronics.ru Git - kernel.git/commit
mq-deadline: Fix request accounting
authorBart Van Assche <bvanassche@acm.org>
Tue, 24 Aug 2021 17:05:20 +0000 (10:05 -0700)
committerJens Axboe <axboe@kernel.dk>
Tue, 24 Aug 2021 22:18:01 +0000 (16:18 -0600)
commitadc62f941703f9fa41ce778c13e1ffa1e2b7788c
treef94f83b4397f3d895bec7d974ace8e79305627ef
parent4411e5480a68d93a12caaeea17eebbdb0de3a207
mq-deadline: Fix request accounting

The block layer may call the I/O scheduler .finish_request() callback
without having called the .insert_requests() callback. Make sure that the
mq-deadline I/O statistics are correct if the block layer inserts an I/O
request that bypasses the I/O scheduler. This patch prevents that lower
priority I/O is delayed longer than necessary for mixed I/O priority
workloads.

Cc: Niklas Cassel <Niklas.Cassel@wdc.com>
Cc: Damien Le Moal <damien.lemoal@wdc.com>
Cc: Hannes Reinecke <hare@suse.de>
Reported-by: Niklas Cassel <Niklas.Cassel@wdc.com>
Fixes: 68d713c6ed42 ("block/mq-deadline: Add cgroup support")
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Link: https://lore.kernel.org/r/20210824170520.1659173-1-bvanassche@acm.org
Reviewed-by: Niklas Cassel <niklas.cassel@wdc.com>
Tested-by: Niklas Cassel <niklas.cassel@wdc.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/mq-deadline.c