Skip to content

blk-mq/dm-rq: support BLK_MQ_F_BLOCKING for dm-rq

Ming Lei dm-devel linux-block 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 16 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3block: split having srcu from queue blockingblock/blk-core.c block/blk-mq.c block/blk-mq.h +2 more+9 -81 reply
2/3block: add blk_alloc_disk_srcublock/genhd.c include/linux/genhd.h+11 -61 reply
3/3dm: mark dm queue as blocking if any underlying is blockingdrivers/md/dm-rq.c drivers/md/dm-rq.h drivers/md/dm-table.c +2 more+24 -44 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchMike SnitzerJeff Moyer
1/3R-b
2/3R-b
3/3R-b A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/3] blk-mq/dm-rq: support BLK_MQ_F_BLOCKING for dm-rq

Hello,

dm-rq may be built on blk-mq device which marks BLK_MQ_F_BLOCKING, so dm_mq_queue_rq() may become to sleep current context.

Fixes the issue by allowing dm-rq to set BLK_MQ_F_BLOCKING in case that any underlying queue is marked as BLK_MQ_F_BLOCKING.

DM request queue is allocated before allocating tagset, this way is a bit special, so we need to pre-allocate srcu payload, then use the queue flag of QUEUE_FLAG_BLOCKING for locking dispatch.

Ming Lei (3):
block: split having srcu from queue blocking
block: add blk_alloc_disk_srcu
dm: mark dm queue as blocking if any underlying is blocking

 block/blk-core.c       |  2 +-
 block/blk-mq.c         |  6 +++---
 block/blk-mq.h         |  2 +-
 block/blk-sysfs.c      |  2 +-
 block/genhd.c          |  5 +++--
 drivers/md/dm-rq.c     |  5 ++++-
 drivers/md/dm-rq.h     |  3 ++-
 drivers/md/dm-table.c  | 14 ++++++++++++++
 drivers/md/dm.c        |  5 +++--
 drivers/md/dm.h        |  1 +
 include/linux/blkdev.h |  5 +++--
 include/linux/genhd.h  | 12 ++++++++----
 12 files changed, 44 insertions(+), 18 deletions(-)
Signature · 1 line
2.31.1