]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
block: only mark bio as tracked if it really is tracked
authorJens Axboe <axboe@kernel.dk>
Sat, 16 Oct 2021 02:06:18 +0000 (20:06 -0600)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 16 Sep 2022 08:52:07 +0000 (10:52 +0200)
commit0a70e7d45700b7c5f00eed0852802a40cf3faadb
tree868b94b0213cc253bb2468fdea35c8746cf8cdb9
parent67e45183061079b6336f2400949ccb1ba2172565
block: only mark bio as tracked if it really is tracked

BugLink: https://bugs.launchpad.net/bugs/1987451
[ Upstream commit 90b8faa0e8de1b02b619fb33f6c6e1e13e7d1d70 ]

We set BIO_TRACKED unconditionally when rq_qos_throttle() is called, even
though we may not even have an rq_qos handler. Only mark it as TRACKED if
it really is potentially tracked.

This saves considerable time for the case where the bio isn't tracked:

     2.64%     -1.65%  [kernel.vmlinux]  [k] bio_endio

Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
block/blk-rq-qos.h