Skip to content

Commit 7aa390e

Browse files
Ming Leiaxboe
authored andcommitted
Revert "block: Fix a lockdep complaint triggered by request queue flushing"
This reverts commit b3c6a59. Now we can avoid nvme-loop lockdep warning of 'lockdep possible recursive locking' by nvme-loop's lock class, no need to apply dynamically allocated lock class key, so revert commit b3c6a59("block: Fix a lockdep complaint triggered by request queue flushing"). This way fixes horrible SCSI probe delay issue on megaraid_sas, and it is reported the whole probe may take more than half an hour. Tested-by: Kashyap Desai <[email protected]> Reported-by: Qian Cai <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Cc: Sumit Saxena <[email protected]> Cc: John Garry <[email protected]> Cc: Kashyap Desai <[email protected]> Cc: Bart Van Assche <[email protected]> Cc: Hannes Reinecke <[email protected]> Signed-off-by: Ming Lei <[email protected]> Reviewed-by: Hannes Reinecke <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent 88c9979 commit 7aa390e

File tree

2 files changed

+0
-6
lines changed

2 files changed

+0
-6
lines changed

block/blk-flush.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@
6969
#include <linux/blkdev.h>
7070
#include <linux/gfp.h>
7171
#include <linux/blk-mq.h>
72-
#include <linux/lockdep.h>
7372

7473
#include "blk.h"
7574
#include "blk-mq.h"
@@ -469,9 +468,6 @@ struct blk_flush_queue *blk_alloc_flush_queue(int node, int cmd_size,
469468
INIT_LIST_HEAD(&fq->flush_queue[1]);
470469
INIT_LIST_HEAD(&fq->flush_data_in_flight);
471470

472-
lockdep_register_key(&fq->key);
473-
lockdep_set_class(&fq->mq_flush_lock, &fq->key);
474-
475471
return fq;
476472

477473
fail_rq:
@@ -486,7 +482,6 @@ void blk_free_flush_queue(struct blk_flush_queue *fq)
486482
if (!fq)
487483
return;
488484

489-
lockdep_unregister_key(&fq->key);
490485
kfree(fq->flush_rq);
491486
kfree(fq);
492487
}

block/blk.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ struct blk_flush_queue {
2525
struct list_head flush_data_in_flight;
2626
struct request *flush_rq;
2727

28-
struct lock_class_key key;
2928
spinlock_t mq_flush_lock;
3029
};
3130

0 commit comments

Comments
 (0)