diff options
author | Keith Busch <keith.busch@intel.com> | 2016-04-27 23:51:18 +0200 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2016-05-02 17:03:06 +0200 |
commit | 3b24774e1fb90a40836e96e39a851a774679efff (patch) | |
tree | ed8ababaafe3035d4fd9fba73db45cd6bdf98a1e | |
parent | NVMe: small typo in section BLK_DEV_NVME_SCSI of host/Kconfig (diff) | |
download | linux-3b24774e1fb90a40836e96e39a851a774679efff.tar.xz linux-3b24774e1fb90a40836e96e39a851a774679efff.zip |
NVMe: Fix check_flush_dependency warning
If the controller fails and is degraded after a reset, we need to kill
off all requests queues before removing the inaccessble namespaces. This
will prevent del_gendisk from syncing dirty data, which we can't due
from a WQ_MEM_RECLAIM work queue.
Signed-off-by: Keith Busch <keith.busch@intel.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@fb.com>
-rw-r--r-- | drivers/nvme/host/pci.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c index ff3c8d7ca882..cc46fdf17b16 100644 --- a/drivers/nvme/host/pci.c +++ b/drivers/nvme/host/pci.c @@ -1887,6 +1887,7 @@ static void nvme_reset_work(struct work_struct *work) */ if (dev->online_queues < 2) { dev_warn(dev->ctrl.device, "IO queues not created\n"); + nvme_kill_queues(&dev->ctrl); nvme_remove_namespaces(&dev->ctrl); } else { nvme_start_queues(&dev->ctrl); |