]> www.infradead.org Git - users/hch/misc.git/commit
block: flush all throttled bios when deleting the cgroup
authorLi Lingfeng <lilingfeng3@huawei.com>
Sat, 17 Aug 2024 07:11:08 +0000 (15:11 +0800)
committerJens Axboe <axboe@kernel.dk>
Tue, 22 Oct 2024 14:16:43 +0000 (08:16 -0600)
commit919b5139bd1d557a4d4cd4b2466e2440dda65484
tree5a83eba03fef1affe1b4ba8de466ed5ed362f997
parent96a9fe64bfd486ebeeacf1e6011801ffe89dae18
block: flush all throttled bios when deleting the cgroup

When a process migrates to another cgroup and the original cgroup is deleted,
the restrictions of throttled bios cannot be removed. If the restrictions
are set too low, it will take a long time to complete these bios.

Refer to the process of deleting a disk to remove the restrictions and
issue bios when deleting the cgroup.

This makes difference on the behavior of throttled bios:
Before: the limit of the throttled bios can't be changed and the bios will
complete under this limit;
Now: the limit will be canceled and the throttled bios will be flushed
immediately.

References:
[1] https://lore.kernel.org/r/20220318130144.1066064-4-ming.lei@redhat.com
[2] https://lore.kernel.org/all/da861d63-58c6-3ca0-2535-9089993e9e28@huaweicloud.com/

Signed-off-by: Li Lingfeng <lilingfeng3@huawei.com>
Acked-by: Tejun Heo <tj@kernel.org>
Link: https://lore.kernel.org/r/20240817071108.1919729-1-lilingfeng@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-throttle.c