]> git.baikalelectronics.ru Git - kernel.git/commit
block: don't try to throttle split bio if iops limit isn't set
authorMing Lei <ming.lei@redhat.com>
Wed, 16 Feb 2022 04:45:13 +0000 (12:45 +0800)
committerJens Axboe <axboe@kernel.dk>
Thu, 17 Feb 2022 02:42:28 +0000 (19:42 -0700)
commit92661e9d85bfa0e0a41135327029f89cb2805f8b
treeb7839a03f6554e1c3a7e4e3c58a1ebb5e5b94f25
parent2efdaa62416d30bf9a51012c47527d49f67891fc
block: don't try to throttle split bio if iops limit isn't set

We need to throttle split bio in case of IOPS limit even though the
split bio has been marked as BIO_THROTTLED since block layer
accounts split bio actually.

If only throughput throttle is setup, no need to throttle any more
if BIO_THROTTLED is set since we have accounted & considered the
whole bio bytes already.

Add one flag of THROTL_TG_HAS_IOPS_LIMIT for serving this purpose.

Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20220216044514.2903784-8-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-throttle.c
block/blk-throttle.h