]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
scsi: lpfc: Fix 16gb hbas failing cq create.
authorJames Smart <jsmart2021@gmail.com>
Fri, 25 May 2018 04:09:00 +0000 (21:09 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 29 May 2018 02:40:33 +0000 (22:40 -0400)
The lancer G5 chip family fails the CQ create with 16k page size.  The
hardware incorrectly reports it supports large page sizes when it is
actually limited to 4k pages.

A prior patch resolved this for the A0 chip revision only.  This patch
excludes all revisions of the G5 asic from using large page sizes. As
knowing the actual chip revision is unnecessary, the now unused definitions
are removed

Signed-off-by: Dick Kennedy <dick.kennedy@broadcom.com>
Signed-off-by: James Smart <james.smart@broadcom.com>
Reviewed-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/lpfc/lpfc_hw4.h
drivers/scsi/lpfc/lpfc_init.c
drivers/scsi/lpfc/lpfc_sli4.h

index 807901af9bbe8c720fb3326281cddcb6af7565e4..f43f0bacb77a283381cd15afc904a0ed894b3119 100644 (file)
@@ -104,17 +104,6 @@ struct lpfc_sli_intf {
 #define LPFC_SLI_INTF_IF_TYPE_VIRT     1
 };
 
-struct lpfc_sli_asic_rev {
-       u32 word0;
-#define LPFC_SLI_ASIC_VER_A    0x0
-#define LPFC_SLI_ASIC_VER_B    0x1
-#define LPFC_SLI_ASIC_VER_C    0x2
-#define LPFC_SLI_ASIC_VER_D    0x3
-#define lpfc_sli_asic_ver_SHIFT                4
-#define lpfc_sli_asic_ver_MASK         0x0000000F
-#define lpfc_sli_asic_ver_WORD         word0
-};
-
 #define LPFC_SLI4_MBX_EMBED    true
 #define LPFC_SLI4_MBX_NEMBED   false
 
index 83bc8d849a0d938bd3c12a02d9d65e0a8f751276..48a5f067cec6e0c6b8e3d479d2edda2455233824 100644 (file)
@@ -9545,11 +9545,6 @@ lpfc_sli4_pci_mem_setup(struct lpfc_hba *phba)
                return error;
        }
 
-       if (pci_read_config_dword(pdev, LPFC_SLI_ASIC_VER,
-                                 &phba->sli4_hba.sli_asic_ver.word0)) {
-               return error;
-       }
-
        /* There is no SLI3 failback for SLI4 devices. */
        if (bf_get(lpfc_sli_intf_valid, &phba->sli4_hba.sli_intf) !=
            LPFC_SLI_INTF_VALID) {
@@ -10711,9 +10706,7 @@ lpfc_get_sli4_parameters(struct lpfc_hba *phba, LPFC_MBOXQ_t *mboxq)
        if ((bf_get(lpfc_sli_intf_if_type, &phba->sli4_hba.sli_intf) ==
            LPFC_SLI_INTF_IF_TYPE_2) &&
            (bf_get(lpfc_sli_intf_sli_family, &phba->sli4_hba.sli_intf) ==
-                LPFC_SLI_INTF_FAMILY_LNCR_A0) &&
-           (bf_get(lpfc_sli_asic_ver, &phba->sli4_hba.sli_asic_ver) ==
-           LPFC_SLI_ASIC_VER_A))
+                LPFC_SLI_INTF_FAMILY_LNCR_A0))
                exp_wqcq_pages = false;
 
        if ((bf_get(cfg_cqpsize, mbx_sli4_parameters) & LPFC_CQ_16K_PAGE_SZ) &&
index 179e870a00b4991c7164061ff758d6aacbd797d7..cf64aca82bd059dceccd7779da96c15fa35cb87d 100644 (file)
@@ -592,7 +592,6 @@ struct lpfc_sli4_hba {
        uint32_t ue_to_sr;
        uint32_t ue_to_rp;
        struct lpfc_register sli_intf;
-       struct lpfc_register sli_asic_ver;
        struct lpfc_pc_sli4_params pc_sli4_params;
        struct lpfc_bbscn_params bbscn_params;
        struct lpfc_hba_eq_hdl *hba_eq_hdl; /* HBA per-WQ handle */