diff options
author | Keith Busch <keith.busch@intel.com> | 2019-05-14 14:10:41 -0600 |
---|---|---|
committer | Keith Busch <keith.busch@intel.com> | 2019-05-17 11:03:00 -0600 |
commit | 39a9dd81f864aa20be896bb34b4bbc2501a2453d (patch) | |
tree | bedcac39016bd78bb52bc03fe60e6e2f76e7a75f /drivers | |
parent | e43269e6e5c49d7fec599e6bba71963935b0e4ba (diff) | |
download | linux-stable-39a9dd81f864aa20be896bb34b4bbc2501a2453d.tar.gz linux-stable-39a9dd81f864aa20be896bb34b4bbc2501a2453d.tar.bz2 linux-stable-39a9dd81f864aa20be896bb34b4bbc2501a2453d.zip |
nvme-pci: Don't disable on timeout in reset state
The reset state doesn't dispatch commands that it needs to wait for
anymore. If a timeout occurs in this state, the reset work is already
disabling the controller, so just reset the request's timer.
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <keith.busch@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/nvme/host/pci.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/nvme/host/pci.c b/drivers/nvme/host/pci.c index d4e442160048..c72755311ffa 100644 --- a/drivers/nvme/host/pci.c +++ b/drivers/nvme/host/pci.c @@ -1298,13 +1298,14 @@ static enum blk_eh_timer_return nvme_timeout(struct request *req, bool reserved) shutdown = true; /* fall through */ case NVME_CTRL_CONNECTING: - case NVME_CTRL_RESETTING: dev_warn_ratelimited(dev->ctrl.device, "I/O %d QID %d timeout, disable controller\n", req->tag, nvmeq->qid); nvme_dev_disable(dev, shutdown); nvme_req(req)->flags |= NVME_REQ_CANCELLED; return BLK_EH_DONE; + case NVME_CTRL_RESETTING: + return BLK_EH_RESET_TIMER; default: break; } |