diff options
author | James Smart <James.Smart@Emulex.Com> | 2007-10-27 13:37:53 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-01-11 18:22:33 -0600 |
commit | a8adb83208020c913f010cb4e26d09e25300db8e (patch) | |
tree | 2245ca9f0dba5139946c99d45b80e7f2ce324b74 /drivers/scsi/lpfc/lpfc_init.c | |
parent | 87af33fe5f78c27cf9e43c6e586dd6efd4be3e40 (diff) | |
download | blackbird-op-linux-a8adb83208020c913f010cb4e26d09e25300db8e.tar.gz blackbird-op-linux-a8adb83208020c913f010cb4e26d09e25300db8e.zip |
[SCSI] lpfc 8.2.3 : Miscellaneous Small Fixes - part 2
Miscellaneous Small Fixes - part 2
- Fix ndlp left in PLOGI state after link up
- Fix cannot rcv unsol ELS frames after running HBA resets for a few minutes
- Fix HBQ buffer_count implemention
- Fix RPI leak
- Fix crash while deleting vports while HBA is reset
- Revert the FCP Fbits offset back to 7
- Fix panic when deleting vports
- Remove unused code in switch statement outside of a case
- Reject PLOGI from invalid PName or NName of 0
- Ignore PLOGI responses from WWPName or WWNName of 0
- Fix debugfs hbqinfo display for ppc
- Added 8G to list of supported speeds for sysfs parameter
- Defer ndlp cleanup to dev-loss timeout handler
- Added support for WRITE_VPARMS mailbox command by applications
Signed-off-by: James Smart <James.Smart@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_init.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_init.c | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c index ceb185fa3216..db96f7504a14 100644 --- a/drivers/scsi/lpfc/lpfc_init.c +++ b/drivers/scsi/lpfc/lpfc_init.c @@ -1339,6 +1339,7 @@ lpfc_cleanup(struct lpfc_vport *vport) { struct lpfc_hba *phba = vport->phba; struct lpfc_nodelist *ndlp, *next_ndlp; + int i = 0; if (phba->link_state > LPFC_LINK_DOWN) lpfc_port_link_failure(vport); @@ -1351,17 +1352,20 @@ lpfc_cleanup(struct lpfc_vport *vport) NLP_EVT_DEVICE_RM); } - /* At this point, ALL ndlp's should be gone */ + /* At this point, ALL ndlp's should be gone + * because of the previous NLP_EVT_DEVICE_RM. + * Lets wait for this to happen, if needed. + */ while (!list_empty(&vport->fc_nodes)) { - list_for_each_entry_safe(ndlp, next_ndlp, &vport->fc_nodes, - nlp_listp) { + if (i++ > 3000) { lpfc_printf_vlog(vport, KERN_ERR, LOG_DISCOVERY, - "0233 Nodelist x%x not free: %d\n", - ndlp->nlp_DID, - atomic_read(&ndlp->kref.refcount)); - lpfc_drop_node(vport, ndlp); + "0233 Nodelist not empty\n"); + break; } + + /* Wait for any activity on ndlps to settle */ + msleep(10); } return; } @@ -1499,6 +1503,8 @@ lpfc_offline_prep(struct lpfc_hba * phba) for(i = 0; i < LPFC_MAX_VPORTS && vports[i] != NULL; i++) { struct Scsi_Host *shost; + if (vports[i]->load_flag & FC_UNLOADING) + continue; shost = lpfc_shost_from_vport(vports[i]); list_for_each_entry_safe(ndlp, next_ndlp, &vports[i]->fc_nodes, @@ -1771,6 +1777,8 @@ void lpfc_host_attrib_init(struct Scsi_Host *shost) fc_host_supported_speeds(shost) = 0; if (phba->lmt & LMT_10Gb) fc_host_supported_speeds(shost) |= FC_PORTSPEED_10GBIT; + if (phba->lmt & LMT_8Gb) + fc_host_supported_speeds(shost) |= FC_PORTSPEED_8GBIT; if (phba->lmt & LMT_4Gb) fc_host_supported_speeds(shost) |= FC_PORTSPEED_4GBIT; if (phba->lmt & LMT_2Gb) |