diff options
author | Jamie Wellnitz <Jamie.Wellnitz@emulex.com> | 2006-02-28 22:33:04 -0500 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-03-06 10:45:43 -0500 |
commit | 74b72a59b8d42d31aa6ffac8f10ca7a784be392c (patch) | |
tree | 524eabfe74685220fb9a0778149ec5e696277422 /drivers/scsi/lpfc/lpfc_ct.c | |
parent | 42ab03609cca4ef5079e248296f015650c626899 (diff) |
[PATCH] lpfc 8.1.3: Derive supported speeds from LMT field in the READ_CONFIG
Derive supported speeds from LMT field in the READ_CONFIG
Driver was keying off internal cores. Use what the firmware reports instead.
Signed-off-by: Jamie Wellnitz <Jamie.Wellnitz@emulex.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_ct.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_ct.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/scsi/lpfc/lpfc_ct.c b/drivers/scsi/lpfc/lpfc_ct.c index 0c982bbc4c77..f3b280313a74 100644 --- a/drivers/scsi/lpfc/lpfc_ct.c +++ b/drivers/scsi/lpfc/lpfc_ct.c | |||
@@ -1014,19 +1014,19 @@ lpfc_fdmi_cmd(struct lpfc_hba * phba, struct lpfc_nodelist * ndlp, int cmdcode) | |||
1014 | ae = (ATTRIBUTE_ENTRY *) ((uint8_t *) pab + size); | 1014 | ae = (ATTRIBUTE_ENTRY *) ((uint8_t *) pab + size); |
1015 | ae->ad.bits.AttrType = be16_to_cpu(SUPPORTED_SPEED); | 1015 | ae->ad.bits.AttrType = be16_to_cpu(SUPPORTED_SPEED); |
1016 | ae->ad.bits.AttrLen = be16_to_cpu(FOURBYTES + 4); | 1016 | ae->ad.bits.AttrLen = be16_to_cpu(FOURBYTES + 4); |
1017 | if (FC_JEDEC_ID(vp->rev.biuRev) == VIPER_JEDEC_ID) | 1017 | |
1018 | ae->un.SupportSpeed = 0; | ||
1019 | if (phba->lmt & LMT_10Gb) | ||
1018 | ae->un.SupportSpeed = HBA_PORTSPEED_10GBIT; | 1020 | ae->un.SupportSpeed = HBA_PORTSPEED_10GBIT; |
1019 | else if (FC_JEDEC_ID(vp->rev.biuRev) == HELIOS_JEDEC_ID) | 1021 | if (phba->lmt & LMT_8Gb) |
1020 | ae->un.SupportSpeed = HBA_PORTSPEED_4GBIT; | 1022 | ae->un.SupportSpeed |= HBA_PORTSPEED_8GBIT; |
1021 | else if ((FC_JEDEC_ID(vp->rev.biuRev) == | 1023 | if (phba->lmt & LMT_4Gb) |
1022 | CENTAUR_2G_JEDEC_ID) | 1024 | ae->un.SupportSpeed |= HBA_PORTSPEED_4GBIT; |
1023 | || (FC_JEDEC_ID(vp->rev.biuRev) == | 1025 | if (phba->lmt & LMT_2Gb) |
1024 | PEGASUS_JEDEC_ID) | 1026 | ae->un.SupportSpeed |= HBA_PORTSPEED_2GBIT; |
1025 | || (FC_JEDEC_ID(vp->rev.biuRev) == | 1027 | if (phba->lmt & LMT_1Gb) |
1026 | THOR_JEDEC_ID)) | 1028 | ae->un.SupportSpeed |= HBA_PORTSPEED_1GBIT; |
1027 | ae->un.SupportSpeed = HBA_PORTSPEED_2GBIT; | 1029 | |
1028 | else | ||
1029 | ae->un.SupportSpeed = HBA_PORTSPEED_1GBIT; | ||
1030 | pab->ab.EntryCnt++; | 1030 | pab->ab.EntryCnt++; |
1031 | size += FOURBYTES + 4; | 1031 | size += FOURBYTES + 4; |
1032 | 1032 | ||