-----Original Message-----
From: Jon Mason <jdma...@kudzu.us>
To: James Bottomley <jbottom...@parallels.com>
Cc: scsi <linux-scsi@vger.kernel.org>, Ravi Anand <ravi.an...@qlogic.com>,
Vikas <vikas.chaudh...@qlogic.com>, Dept-Eng iSCSI Driver
<dept-iscsidri...@qlogic.com>
Subject: [PATCH RESUBMIT 1/3] 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 <jdma...@kudzu.us>
>Cc: Ravi Anand <ravi.an...@qlogic.com>
>Cc: Vikas Chaudhary <vikas.chaudh...@qlogic.com>
>Cc: iscsi-dri...@qlogic.com
>---
> drivers/scsi/qla4xxx/ql4_nx.c |    2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
>diff --git a/drivers/scsi/qla4xxx/ql4_nx.c b/drivers/scsi/qla4xxx/ql4_nx.c
>index 228b670..939d726 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;

Acked-by: Vikas Chaudhary <vikas.chaudh...@qlogic.com>



This message and any attached documents contain information from QLogic 
Corporation or its wholly-owned subsidiaries that may be confidential. If you 
are not the intended recipient, you may not read, copy, distribute, or use this 
information. If you have received this transmission in error, please notify the 
sender immediately by reply e-mail and then delete this message.

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to