Re: [PATCH] block, bfq: protect async queue reset with blkcg locks

From: Jens Axboe

Date: Mon Jun 22 2026 - 18:01:20 EST



On Sun, 21 Jun 2026 21:59:30 +0800, Cen Zhang wrote:
> Writing 0 to BFQ's low_latency attribute ends weight raising for active,
> idle and async queues. The async cgroup path walks q->blkg_list, converts
> each blkg to BFQ policy data and then reads bfqg->async_bfqq and
> bfqg->async_idle_bfqq.
>
> That walk was protected only by bfqd->lock. blkcg release work is
> serialized by q->blkcg_mutex and q->queue_lock instead, and
> blkg_free_workfn() can call BFQ's pd_free_fn before it removes
> blkg->q_node from q->blkg_list. A low_latency reset can therefore still
> find the blkg on the queue list after the BFQ policy data has been freed.
>
> [...]

Applied, thanks!

[1/1] block, bfq: protect async queue reset with blkcg locks
commit: 17b2d950a3c0328ed749476e6118ca869b3ca8b5

Best regards,
--
Jens Axboe