aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cxgb4
diff options
context:
space:
mode:
authorDimitris Michailidis <dm@chelsio.com>2010-05-10 15:58:08 +0000
committerDavid S. Miller <davem@davemloft.net>2010-05-12 23:31:16 -0700
commitf1a051b93090ad920e88748023ab0dea3a6e2ad7 (patch)
treeba8e022276a2bad62fd340c2c640382c2331d711 /drivers/net/cxgb4
parentf8f5aafa960883bc3f1b8f85f1cf8199d0c85879 (diff)
downloadkernel_samsung_smdk4412-f1a051b93090ad920e88748023ab0dea3a6e2ad7.tar.gz
kernel_samsung_smdk4412-f1a051b93090ad920e88748023ab0dea3a6e2ad7.tar.bz2
kernel_samsung_smdk4412-f1a051b93090ad920e88748023ab0dea3a6e2ad7.zip
cxgb4: report the PCIe link speed
Report the PCIe link speed (2.5 or 5 Gbps). Signed-off-by: Dimitris Michailidis <dm@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb4')
-rw-r--r--drivers/net/cxgb4/cxgb4_main.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_main.c
index a73cda9c9de..80c3fc5c41c 100644
--- a/drivers/net/cxgb4/cxgb4_main.c
+++ b/drivers/net/cxgb4/cxgb4_main.c
@@ -3080,6 +3080,12 @@ static void __devinit print_port_info(struct adapter *adap)
int i;
char buf[80];
+ const char *spd = "";
+
+ if (adap->params.pci.speed == PCI_EXP_LNKSTA_CLS_2_5GB)
+ spd = " 2.5 GT/s";
+ else if (adap->params.pci.speed == PCI_EXP_LNKSTA_CLS_5_0GB)
+ spd = " 5 GT/s";
for_each_port(adap, i) {
struct net_device *dev = adap->port[i];
@@ -3099,10 +3105,10 @@ static void __devinit print_port_info(struct adapter *adap)
--bufp;
sprintf(bufp, "BASE-%s", base[pi->port_type]);
- netdev_info(dev, "Chelsio %s rev %d %s %sNIC PCIe x%d%s\n",
+ netdev_info(dev, "Chelsio %s rev %d %s %sNIC PCIe x%d%s%s\n",
adap->params.vpd.id, adap->params.rev,
buf, is_offload(adap) ? "R" : "",
- adap->params.pci.width,
+ adap->params.pci.width, spd,
(adap->flags & USING_MSIX) ? " MSI-X" :
(adap->flags & USING_MSI) ? " MSI" : "");
if (adap->name == dev->name)