]> git.baikalelectronics.ru Git - kernel.git/commit
Revert "scsi, block: fix duplicate bdi name registration crashes"
authorJan Kara <jack@suse.cz>
Wed, 8 Mar 2017 16:48:34 +0000 (17:48 +0100)
committerJens Axboe <axboe@fb.com>
Wed, 8 Mar 2017 17:55:17 +0000 (10:55 -0700)
commitae484d8893e6558148aded17069ddd4f911aaa0e
tree41fe10418d432b17e93898ed9f84b8aebc78c7ad
parent9f56b23f6c2bc9061e2a356e02805966ccf0a418
Revert "scsi, block: fix duplicate bdi name registration crashes"

This reverts commit e993902543ac5693777a168d13352bbda935d9c5. It causes
leaking of device numbers for SCSI when SCSI registers multiple gendisks
for one request_queue in succession. It can be easily reproduced using
Omar's script [1] on kernel with CONFIG_DEBUG_TEST_DRIVER_REMOVE.
Furthermore the protection provided by this commit is not needed anymore
as the problem it was fixing got also fixed by commit 62e779c8065e
"block: Move bdi_unregister() to del_gendisk()".

[1]: http://marc.info/?l=linux-block&m=148554717109098&w=2

Signed-off-by: Jan Kara <jack@suse.cz>
Acked-by: Dan Williams <dan.j.williams@intel.com>
Tested-by: Omar Sandoval <osandov@fb.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-core.c
block/genhd.c
drivers/scsi/sd.c
include/linux/blkdev.h
include/linux/genhd.h