]> www.infradead.org Git - users/jedix/linux-maple.git/commit
NVMe: Short-cut removal on surprise hot-unplug
authorKeith Busch <keith.busch@intel.com>
Thu, 12 May 2016 14:37:14 +0000 (08:37 -0600)
committerChuck Anderson <chuck.anderson@oracle.com>
Thu, 1 Jun 2017 20:41:25 +0000 (13:41 -0700)
commitb57406055a1467b68d099baef1454613dac87108
tree4fb1feaf0c25e152ecb16231e57714286042181a
parenta53ca73432674f5794a3f85fde8b65b88656c956
NVMe: Short-cut removal on surprise hot-unplug

This patch adds a new state that when set has the core automatically
kill request queues prior to removing namespaces.

If PCI device is not present at the time the nvme driver's remove is
called, we can kill all IO queues immediately instead of waiting for
the watchdog thread to do that at its polling interval. This improves
scenarios where multiple hot plug events occur at the same time since
it doesn't block the pci enumeration for as long.

Signed-off-by: Keith Busch <keith.busch@intel.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@fb.com>
(cherry picked from commit 0ff9d4e1a284a9282a049bf064f123e27f838907)

Orabug: 25130845

Signed-off-by: Ashok Vairavan <ashok.vairavan@oracle.com>
Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/nvme/host/core.c
drivers/nvme/host/nvme.h
drivers/nvme/host/pci.c