]> git.baikalelectronics.ru Git - kernel.git/commit
NVMe: Fix filesystem sync deadlock on removal
authorKeith Busch <keith.busch@intel.com>
Fri, 18 Jul 2014 17:40:20 +0000 (11:40 -0600)
committerJens Axboe <axboe@fb.com>
Tue, 4 Nov 2014 20:17:08 +0000 (13:17 -0700)
commite9fbb6e4f4e7ec7fa8b03fc222da9705a351eb52
tree17f37cd779add019ed67a28cb1508e739ff8278a
parent62e95f3c2b7b79a3a308a47cc982f7b7e46aed8e
NVMe: Fix filesystem sync deadlock on removal

This changes the order of deleting the gendisks so it happens after the
nvme IO queues are freed. If a device is removed while a filesystem has
associated dirty data, the removal will wait on these to complete before
proceeding from del_gendisk, which could have caused deadlock before.

The implication of this is that an orderly removal of a responsive
device won't necessarily wait for dirty data to be written, but we are
not guaranteed the device is even going to respond at this point either.

Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Signed-off-by: Jens Axboe <axboe@fb.com>
drivers/block/nvme-core.c