On 5/16/23 18:26, Yu Kuai wrote:
在 2023/05/17 6:38, Bart Van Assche 写道:
If anything goes wrong with the counters that track the number of
requests, I/O locks up. Make such scenarios easier to debug by adding
invariant checks for the request counters. Additionally, check that
BFQ queues are empty before these are freed.
Is there any real problems related to those counters?
No, but I encountered an I/O lockup in BFQ while modifying the block
layer core. This code was helpful while analyzing the lockup. All that
is needed to reproduce the lockup is to call bfq_dispatch_request() and
bfq_insert_requests() without calling bfq_finish_requeue_request()
between these two calls.
Bart.