All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] blk-mq: allow to run queue if queue refcount is held
@ 2019-03-31  3:09 Ming Lei
  2019-03-31  3:09 ` [PATCH 1/5] blk-mq: re-organize blk_mq_exit_hctx() into two parts Ming Lei
                   ` (5 more replies)
  0 siblings, 6 replies; 39+ messages in thread
From: Ming Lei @ 2019-03-31  3:09 UTC (permalink / raw)
  To: Jens Axboe
  Cc: linux-block, Ming Lei, James Smart, Bart Van Assche, linux-scsi,
	Martin K . Petersen, Christoph Hellwig, James E . J . Bottomley,
	jianchao wang

Hi,

Since 45a9c9d909b2 ("blk-mq: Fix a use-after-free"), run queue isn't
allowed during cleanup queue even though queue refcount is held.

This change has caused lots of kernel oops triggered in run queue path,
turns out it isn't easy to fix them all.

So move freeing of hw queue resources into queue's release handler, then
the above issue is fixed. Meantime, this way is safe given freeing hw
queue resource doesn't require to use tags.

Thanks,

Ming Lei (5):
  blk-mq: re-organize blk_mq_exit_hctx() into two parts
  blk-mq: re-organize blk_mq_exit_hw_queues() into two parts
  blk-mq: free hw queues in queue's release handler
  block: don't drain in-progress dispatch in blk_cleanup_queue()
  SCSI: don't grab queue usage counter before run queue

 block/blk-core.c        | 14 +-------------
 block/blk-mq.c          | 32 +++++++++++++++++++++++++-------
 block/blk-mq.h          |  3 ++-
 drivers/scsi/scsi_lib.c |  7 -------
 4 files changed, 28 insertions(+), 28 deletions(-)

Cc: James Smart <james.smart@broadcom.com>
Cc: Bart Van Assche <bart.vanassche@wdc.com>
Cc: linux-scsi@vger.kernel.org,
Cc: Martin K . Petersen <martin.petersen@oracle.com>,
Cc: Christoph Hellwig <hch@lst.de>,
Cc: James E . J . Bottomley <jejb@linux.vnet.ibm.com>,
Cc: jianchao wang <jianchao.w.wang@oracle.com>

-- 
2.9.5


^ permalink raw reply	[flat|nested] 39+ messages in thread

end of thread, other threads:[~2019-04-03  8:43 UTC | newest]

Thread overview: 39+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-31  3:09 [PATCH 0/5] blk-mq: allow to run queue if queue refcount is held Ming Lei
2019-03-31  3:09 ` [PATCH 1/5] blk-mq: re-organize blk_mq_exit_hctx() into two parts Ming Lei
2019-04-01  1:40   ` Dongli Zhang
2019-04-01  2:06     ` Ming Lei
2019-03-31  3:09 ` [PATCH 2/5] blk-mq: re-organize blk_mq_exit_hw_queues() " Ming Lei
2019-03-31  3:09 ` [PATCH 3/5] blk-mq: free hw queues in queue's release handler Ming Lei
2019-03-31  3:09 ` [PATCH 4/5] block: don't drain in-progress dispatch in blk_cleanup_queue() Ming Lei
2019-04-01  1:50   ` Dongli Zhang
2019-04-01  2:08     ` Ming Lei
2019-03-31  3:09 ` [PATCH 5/5] SCSI: don't grab queue usage counter before run queue Ming Lei
2019-04-01  1:53   ` Dongli Zhang
2019-03-31 15:27 ` [PATCH 0/5] blk-mq: allow to run queue if queue refcount is held Bart Van Assche
2019-04-01  2:00   ` Ming Lei
2019-04-01  2:39     ` Bart Van Assche
2019-04-01  2:44       ` jianchao.wang
2019-04-02 18:07         ` Bart Van Assche
2019-04-01  2:52       ` Ming Lei
2019-04-01  3:25         ` jianchao.wang
2019-04-01  3:28           ` Ming Lei
2019-04-01  9:19             ` jianchao.wang
2019-04-01 10:03               ` Ming Lei
2019-04-02  2:02                 ` jianchao.wang
2019-04-02  2:55                   ` Ming Lei
2019-04-02  8:07                     ` jianchao.wang
2019-04-02 11:05                       ` Ming Lei
2019-04-02 17:53                         ` Bart Van Assche
2019-04-03  3:20                           ` Ming Lei
2019-04-03  8:29                             ` Ming Lei
2019-04-03  8:43                               ` Ming Lei
2019-04-02 18:11                     ` Bart Van Assche
2019-04-03  3:24                       ` Ming Lei
2019-04-01  5:05         ` Dongli Zhang
2019-04-01  5:16           ` Ming Lei
2019-04-01  5:30             ` Dongli Zhang
2019-04-01  7:15               ` Ming Lei
2019-04-02  2:10                 ` Dongli Zhang
2019-04-02  2:20                   ` Ming Lei
2019-04-01  3:27       ` Ming Lei
2019-04-01  3:32         ` jianchao.wang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.