summaryrefslogtreecommitdiff
path: root/drivers/scsi/qla4xxx/ql4_nx.c
diff options
context:
space:
mode:
authorJon Mason <jdmason@kudzu.us>2012-07-11 01:57:55 +0400
committerJames Bottomley <JBottomley@Parallels.com>2012-07-20 11:59:02 +0400
commit983bfb5b40157c9fbb7c5290508f18845b7e7234 (patch)
treebb8a687f1aecb75f8eb9d979dfab5932dba66e42 /drivers/scsi/qla4xxx/ql4_nx.c
parent94c122ab01f84332c371dc4ae0f5b70e879173d6 (diff)
downloadlinux-983bfb5b40157c9fbb7c5290508f18845b7e7234.tar.xz
[SCSI] qla4xxx: remove unnecessary read of PCI_CAP_ID_EXP
The PCIE capability offset is saved during PCI bus walking. It will remove an unnecessary search in the PCI configuration space if this value is referenced instead of reacquiring it. Signed-off-by: Jon Mason <jdmason@kudzu.us> Acked-by: Vikas Chaudhary <vikas.chaudhary@qlogic.com> Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Diffstat (limited to 'drivers/scsi/qla4xxx/ql4_nx.c')
-rw-r--r--drivers/scsi/qla4xxx/ql4_nx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/qla4xxx/ql4_nx.c b/drivers/scsi/qla4xxx/ql4_nx.c
index 228b67020d2c..939d7261c37a 100644
--- a/drivers/scsi/qla4xxx/ql4_nx.c
+++ b/drivers/scsi/qla4xxx/ql4_nx.c
@@ -1590,7 +1590,7 @@ qla4_8xxx_start_firmware(struct scsi_qla_host *ha, uint32_t image_start)
}
/* Negotiated Link width */
- pcie_cap = pci_find_capability(ha->pdev, PCI_CAP_ID_EXP);
+ pcie_cap = pci_pcie_cap(ha->pdev);
pci_read_config_word(ha->pdev, pcie_cap + PCI_EXP_LNKSTA, &lnk);
ha->link_width = (lnk >> 4) & 0x3f;