linux-sg2042/drivers/nvme/host
James Smart cf25809bec nvme_fc: fix ctrl create failures racing with workq items
If there are errors during initial controller create, the transport
will teardown the partially initialized controller struct and free
the ctlr memory.  Trouble is - most of those errors can occur due
to asynchronous events happening such io timeouts and subsystem
connectivity failures. Those failures invoke async workq items to
reset the controller and attempt reconnect.  Those may be in progress
as the main thread frees the ctrl memory, resulting in NULL ptr oops.

Prevent this from happening by having the main ctrl failure thread
changing state to DELETING followed by synchronously cancelling any
pending queued work item. The change of state will prevent the
scheduling of resets or reconnect events.

Signed-off-by: James Smart <james.smart@broadcom.com>
Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2018-03-26 08:53:43 -06:00
..
Kconfig nvme: implement multipath access to nvme subsystems 2017-11-10 19:53:25 -07:00
Makefile nvme: Add fault injection feature 2018-03-26 08:53:43 -06:00
core.c nvme: centralize ctrl removal prints 2018-03-26 08:53:43 -06:00
fabrics.c nvme-fabrics: don't check for non-NULL module in nvmf_register_transport 2018-02-22 01:45:30 -07:00
fabrics.h nvme: rename NVME_CTRL_RECONNECTING state to NVME_CTRL_CONNECTING 2018-02-08 18:35:53 +02:00
fault_inject.c nvme: Add fault injection feature 2018-03-26 08:53:43 -06:00
fc.c nvme_fc: fix ctrl create failures racing with workq items 2018-03-26 08:53:43 -06:00
lightnvm.c lightnvm: make geometry structures 2.0 ready 2018-01-05 08:50:12 -07:00
multipath.c nvme: change namespaces_mutext to namespaces_rwsem 2018-03-26 08:53:43 -06:00
nvme.h nvme: change namespaces_mutext to namespaces_rwsem 2018-03-26 08:53:43 -06:00
pci.c nvme-pci: disable APST for Samsung NVMe SSD 960 EVO + ASUS PRIME Z370-A 2018-03-26 08:53:43 -06:00
rdma.c nvme: centralize ctrl removal prints 2018-03-26 08:53:43 -06:00
trace.c nvme: add tracepoint for nvme_setup_cmd 2018-01-26 12:34:40 +01:00
trace.h nvme: add tracepoint for nvme_complete_rq 2018-01-26 12:34:40 +01:00