diff options
author | Brian King <brking@linux.vnet.ibm.com> | 2010-08-05 17:38:31 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2010-08-06 13:26:33 -0400 |
commit | d5da3040d798df4bbb62579b97f8b6b83749da22 (patch) | |
tree | 96efaf510657b9be678a9a31c807988ca7ae3cdd /drivers/scsi/ibmvscsi/ibmvfc.h | |
parent | 161155519c27773b8f35ee3d7a1b49acfc9eee73 (diff) |
[SCSI] ibmvfc: Fix rport add/delete race resulting in oops
Commit 43c8da907ccc656935d1085701f4db83385d8a59 introduced a race
condition which can occur when adding/deleting rports. There are
two possible threads now that can be deleting rports in the ibmvfc
driver, which can result in list_del being called twice, resulting
in an oops. This patch adds a new state to the ibmvfc_target struct
to indicate the target has been removed from the list and is in
the process of being deleted.
Signed-off-by: Brian King <brking@linux.vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/ibmvscsi/ibmvfc.h')
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvfc.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvfc.h b/drivers/scsi/ibmvscsi/ibmvfc.h index d7e8dcd90650..af48172112fa 100644 --- a/drivers/scsi/ibmvscsi/ibmvfc.h +++ b/drivers/scsi/ibmvscsi/ibmvfc.h | |||
@@ -597,6 +597,7 @@ enum ibmvfc_target_action { | |||
597 | IBMVFC_TGT_ACTION_INIT, | 597 | IBMVFC_TGT_ACTION_INIT, |
598 | IBMVFC_TGT_ACTION_INIT_WAIT, | 598 | IBMVFC_TGT_ACTION_INIT_WAIT, |
599 | IBMVFC_TGT_ACTION_DEL_RPORT, | 599 | IBMVFC_TGT_ACTION_DEL_RPORT, |
600 | IBMVFC_TGT_ACTION_DELETED_RPORT, | ||
600 | }; | 601 | }; |
601 | 602 | ||
602 | struct ibmvfc_target { | 603 | struct ibmvfc_target { |