scsi: ibmvfc: Avoid move login if fast fail is enabled
authorBrian King <brking@linux.vnet.ibm.com>
Tue, 11 May 2021 18:12:19 +0000 (13:12 -0500)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sat, 15 May 2021 03:02:42 +0000 (23:02 -0400)
commit5114975eb2de4e70d9d43b57912e1aee12ec090b
treeef9068b8e09e618808b1574c3fab0e72cd3cea57
parentd5b45dd5ba6c944b17118530843e67bf9c096e49
scsi: ibmvfc: Avoid move login if fast fail is enabled

If fast fail is enabled and we encounter a WWPN moving from one port id to
another port id with I/O outstanding, if we use the move login MAD,
although it will work, it will leave any outstanding I/O still outstanding
to the old port id. Eventually, the SCSI command timers will fire and we
will abort these commands, however, this is generally much longer than the
fast fail timeout, which can lead to I/O operations being outstanding for a
long time. This patch changes the behavior to avoid the move login if fast
fail is enabled. Once terminate_rport_io cleans up the rport, then we force
the target back through the delete process, which re-drives the implicit
logout, then kicks us back into discovery where we will discover the WWPN
at the new location and do a PLOGI to it.

Link: https://lore.kernel.org/r/1620756740-7045-3-git-send-email-brking@linux.vnet.ibm.com
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/ibmvscsi/ibmvfc.c
drivers/scsi/ibmvscsi/ibmvfc.h