[PATCH 0/3] block: fix lock dependency between freeze and elevator lock

Ming Lei
2025-04-02T04:39:38Z

Hello Jens,

This patchset adds two pair of block internal APIs for addressing recent
lockdep report between freeze and elevator lock.

Thanks,
Ming

Ming Lei (3):
block: add blk_mq_enter_no_io() and blk_mq_exit_no_io()
block: don't call freeze queue in elevator_switch() and
elevator_disable()
block: use blk_mq_no_io() for avoiding lock dependency

block/blk-core.c | 6 ++++--
block/blk-mq.c | 25 ++++++++++++++++++-------
block/blk-mq.h | 19 +++++++++++++++++++
block/blk-sysfs.c | 8 ++++----
block/blk.h | 5 +++--
block/elevator.c | 11 ++---------
include/linux/blkdev.h | 8 ++++++++
7 files changed, 58 insertions(+), 24 deletions(-)

--
2.47.0