summaryrefslogtreecommitdiff
path: root/drivers/scsi/lpfc/lpfc_nvme.h
diff options
context:
space:
mode:
authorJames Smart <jsmart2021@gmail.com>2017-11-21 03:00:40 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2017-12-05 04:32:54 +0300
commitadd9d6be3d650bf897b1c3feadabcf42e216acdb (patch)
treeac974757bc9682ef557f4d957fc8d1fd368f671a /drivers/scsi/lpfc/lpfc_nvme.h
parent3b5bde69bcf91d75e75d6b0ca9ab6346d0744137 (diff)
downloadlinux-add9d6be3d650bf897b1c3feadabcf42e216acdb.tar.xz
scsi: lpfc: Correct driver deregistrations with host nvme transport
The driver's interaction with the host nvme transport has been incorrect for a while. The driver did not wait for the unregister callbacks (waited only 5 jiffies). Thus the driver may remove objects that may be referenced by subsequent abort commands from the transport, and the actual unregister callback was effectively a noop. This was especially problematic if the driver was unloaded. The driver now waits for the unregister callbacks, as it should, before continuing with teardown. Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com> Signed-off-by: James Smart <james.smart@broadcom.com> Reviewed-by: Hannes Reinecke <hare@suse.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_nvme.h')
-rw-r--r--drivers/scsi/lpfc/lpfc_nvme.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/lpfc/lpfc_nvme.h b/drivers/scsi/lpfc/lpfc_nvme.h
index fbfc1786cd04..903ec37f465f 100644
--- a/drivers/scsi/lpfc/lpfc_nvme.h
+++ b/drivers/scsi/lpfc/lpfc_nvme.h
@@ -27,6 +27,8 @@
#define LPFC_NVME_ERSP_LEN 0x20
+#define LPFC_NVME_WAIT_TMO 10
+
struct lpfc_nvme_qhandle {
uint32_t index; /* WQ index to use */
uint32_t qidx; /* queue index passed to create */