diff options
author | James Smart <James.Smart@Emulex.Com> | 2006-04-15 11:53:15 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-04-19 20:49:48 -0400 |
commit | 10d4e957e027b96adfed05c3af1d3fd782a242fe (patch) | |
tree | c64384daa94201553bd08fdb7289fc9aba1ff2ce /drivers | |
parent | defbcf11ab56e09965b2135d70f44a82a5ab5fc3 (diff) |
[SCSI] lpfc 8.1.5 : Additional fixes to LOGO, PLOGI, and RSCN processing
Additional fixes to LOGO, PLOGI, and RSCN processing
Signed-off-by: James Smart <James.Smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_els.c | 68 | ||||
-rw-r--r-- | drivers/scsi/lpfc/lpfc_hbadisc.c | 2 |
2 files changed, 37 insertions, 33 deletions
diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c index e3d8b7f47f12..806c337b630b 100644 --- a/drivers/scsi/lpfc/lpfc_els.c +++ b/drivers/scsi/lpfc/lpfc_els.c | |||
@@ -777,25 +777,26 @@ lpfc_cmpl_els_plogi(struct lpfc_hba * phba, struct lpfc_iocbq * cmdiocb, | |||
777 | if (disc && phba->num_disc_nodes) { | 777 | if (disc && phba->num_disc_nodes) { |
778 | /* Check to see if there are more PLOGIs to be sent */ | 778 | /* Check to see if there are more PLOGIs to be sent */ |
779 | lpfc_more_plogi(phba); | 779 | lpfc_more_plogi(phba); |
780 | } | ||
781 | 780 | ||
782 | if (phba->num_disc_nodes == 0) { | 781 | if (phba->num_disc_nodes == 0) { |
783 | spin_lock_irq(phba->host->host_lock); | 782 | spin_lock_irq(phba->host->host_lock); |
784 | phba->fc_flag &= ~FC_NDISC_ACTIVE; | 783 | phba->fc_flag &= ~FC_NDISC_ACTIVE; |
785 | spin_unlock_irq(phba->host->host_lock); | 784 | spin_unlock_irq(phba->host->host_lock); |
786 | 785 | ||
787 | lpfc_can_disctmo(phba); | 786 | lpfc_can_disctmo(phba); |
788 | if (phba->fc_flag & FC_RSCN_MODE) { | 787 | if (phba->fc_flag & FC_RSCN_MODE) { |
789 | /* Check to see if more RSCNs came in while we were | 788 | /* |
790 | * processing this one. | 789 | * Check to see if more RSCNs came in while |
791 | */ | 790 | * we were processing this one. |
792 | if ((phba->fc_rscn_id_cnt == 0) && | 791 | */ |
793 | (!(phba->fc_flag & FC_RSCN_DISCOVERY))) { | 792 | if ((phba->fc_rscn_id_cnt == 0) && |
794 | spin_lock_irq(phba->host->host_lock); | 793 | (!(phba->fc_flag & FC_RSCN_DISCOVERY))) { |
795 | phba->fc_flag &= ~FC_RSCN_MODE; | 794 | spin_lock_irq(phba->host->host_lock); |
796 | spin_unlock_irq(phba->host->host_lock); | 795 | phba->fc_flag &= ~FC_RSCN_MODE; |
797 | } else { | 796 | spin_unlock_irq(phba->host->host_lock); |
798 | lpfc_els_handle_rscn(phba); | 797 | } else { |
798 | lpfc_els_handle_rscn(phba); | ||
799 | } | ||
799 | } | 800 | } |
800 | } | 801 | } |
801 | } | 802 | } |
@@ -1259,7 +1260,7 @@ lpfc_issue_els_logo(struct lpfc_hba * phba, struct lpfc_nodelist * ndlp, | |||
1259 | psli = &phba->sli; | 1260 | psli = &phba->sli; |
1260 | pring = &psli->ring[LPFC_ELS_RING]; | 1261 | pring = &psli->ring[LPFC_ELS_RING]; |
1261 | 1262 | ||
1262 | cmdsize = 2 * (sizeof (uint32_t) + sizeof (struct lpfc_name)); | 1263 | cmdsize = (2 * sizeof (uint32_t)) + sizeof (struct lpfc_name); |
1263 | elsiocb = lpfc_prep_els_iocb(phba, 1, cmdsize, retry, ndlp, | 1264 | elsiocb = lpfc_prep_els_iocb(phba, 1, cmdsize, retry, ndlp, |
1264 | ndlp->nlp_DID, ELS_CMD_LOGO); | 1265 | ndlp->nlp_DID, ELS_CMD_LOGO); |
1265 | if (!elsiocb) | 1266 | if (!elsiocb) |
@@ -1447,22 +1448,23 @@ lpfc_cancel_retry_delay_tmo(struct lpfc_hba *phba, struct lpfc_nodelist * nlp) | |||
1447 | * PLOGIs to be sent | 1448 | * PLOGIs to be sent |
1448 | */ | 1449 | */ |
1449 | lpfc_more_plogi(phba); | 1450 | lpfc_more_plogi(phba); |
1450 | } | ||
1451 | 1451 | ||
1452 | if (phba->num_disc_nodes == 0) { | 1452 | if (phba->num_disc_nodes == 0) { |
1453 | phba->fc_flag &= ~FC_NDISC_ACTIVE; | 1453 | phba->fc_flag &= ~FC_NDISC_ACTIVE; |
1454 | lpfc_can_disctmo(phba); | 1454 | lpfc_can_disctmo(phba); |
1455 | if (phba->fc_flag & FC_RSCN_MODE) { | 1455 | if (phba->fc_flag & FC_RSCN_MODE) { |
1456 | /* Check to see if more RSCNs | 1456 | /* |
1457 | * came in while we were | 1457 | * Check to see if more RSCNs |
1458 | * processing this one. | 1458 | * came in while we were |
1459 | */ | 1459 | * processing this one. |
1460 | if((phba->fc_rscn_id_cnt==0) && | 1460 | */ |
1461 | (!(phba->fc_flag & FC_RSCN_DISCOVERY))) { | 1461 | if((phba->fc_rscn_id_cnt==0) && |
1462 | phba->fc_flag &= ~FC_RSCN_MODE; | 1462 | !(phba->fc_flag & FC_RSCN_DISCOVERY)) { |
1463 | } | 1463 | phba->fc_flag &= ~FC_RSCN_MODE; |
1464 | else { | 1464 | } |
1465 | lpfc_els_handle_rscn(phba); | 1465 | else { |
1466 | lpfc_els_handle_rscn(phba); | ||
1467 | } | ||
1466 | } | 1468 | } |
1467 | } | 1469 | } |
1468 | } | 1470 | } |
diff --git a/drivers/scsi/lpfc/lpfc_hbadisc.c b/drivers/scsi/lpfc/lpfc_hbadisc.c index 2a2e2eb406ac..798977de1a66 100644 --- a/drivers/scsi/lpfc/lpfc_hbadisc.c +++ b/drivers/scsi/lpfc/lpfc_hbadisc.c | |||
@@ -1404,6 +1404,8 @@ lpfc_check_sli_ndlp(struct lpfc_hba * phba, | |||
1404 | if (icmd->ulpContext == (volatile ushort)ndlp->nlp_rpi) | 1404 | if (icmd->ulpContext == (volatile ushort)ndlp->nlp_rpi) |
1405 | return 1; | 1405 | return 1; |
1406 | case CMD_ELS_REQUEST64_CR: | 1406 | case CMD_ELS_REQUEST64_CR: |
1407 | if (icmd->un.elsreq64.remoteID == ndlp->nlp_DID) | ||
1408 | return 1; | ||
1407 | case CMD_XMIT_ELS_RSP64_CX: | 1409 | case CMD_XMIT_ELS_RSP64_CX: |
1408 | if (iocb->context1 == (uint8_t *) ndlp) | 1410 | if (iocb->context1 == (uint8_t *) ndlp) |
1409 | return 1; | 1411 | return 1; |