Commit ed4538b7 authored by Keith Busch's avatar Keith Busch Committed by Yang Yingliang
Browse files

nvme-pci: Unblock reset_work on IO failure



mainline inclusion
from mainline-5.2-rc2
commit 2036f726
category: bugfix
bugzilla: 167363
CVE: NA

---------------------------

The reset_work waits for queued IO to complete before setting the
controller to live. If any of these times out and requeues, we won't be
able to restart the controller because the reset_work is already running.

Flush all entered requests to a failed completion if a timeout occurs
in the connecting state, and ensure the controller can't transition to
the live state after we've unblocked it from waiting for completions.

Reviewed-by: default avatarMing Lei <ming.lei@redhat.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarKeith Busch <keith.busch@intel.com>

Conflicts:
	drivers/nvme/host/pci.c
	[ Cleanup patch 3b7dffb9("nvme-pci: mark expected switch
	  fall-through") not applied. ]

Signed-off-by: default avatarZhihao Cheng <chengzhihao1@huawei.com>
Reviewed-by: default avatarHou Tao <houtao1@huawei.com>
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
parent 458f8470
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment