Skip to content
Commit 07836e65 authored by Keith Busch's avatar Keith Busch
Browse files

NVMe: Fix potential corruption during shutdown



The driver has to end unreturned commands at some point even if the
controller has not provided a completion. The driver tried to be safe by
deleting IO queues prior to ending all unreturned commands. That should
cause the controller to internally abort inflight commands, but IO queue
deletion request does not have to be successful, so all bets are off. We
still have to make progress, so to be extra safe, this patch doesn't
clear a queue to release the dma mapping for a command until after the
pci device has been disabled.

This patch removes the special handling during device initialization
so controller recovery can be done all the time. This is possible since
initialization is not inlined with pci probe anymore.

Reported-by: default avatarNilish Choudhury <nilesh.choudhury@oracle.com>
Signed-off-by: default avatarKeith Busch <keith.busch@intel.com>
parent 2e1d8448
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment