scsi: lpfc: Ensure DA_ID handling completion before deleting an NPIV instance
authorJustin Tee <justin.tee@broadcom.com>
Thu, 12 Sep 2024 23:24:44 +0000 (16:24 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 13 Sep 2024 01:21:19 +0000 (21:21 -0400)
commit0a3c84f71680684c1d41abb92db05f95c09111e8
tree89b79fc270479f37783f362e45c80b89cee02200
parentd1a2ef63fc8b3e3dc5b74b7e08636896b32acbdc
scsi: lpfc: Ensure DA_ID handling completion before deleting an NPIV instance

Deleting an NPIV instance requires all fabric ndlps to be released before
an NPIV's resources can be torn down.  Failure to release fabric ndlps
beforehand opens kref imbalance race conditions.  Fix by forcing the DA_ID
to complete synchronously with usage of wait_queue.

Signed-off-by: Justin Tee <justin.tee@broadcom.com>
Link: https://lore.kernel.org/r/20240912232447.45607-6-justintee8345@gmail.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_ct.c
drivers/scsi/lpfc/lpfc_disc.h
drivers/scsi/lpfc/lpfc_vport.c