aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/qlcnic/qlcnic_init.c
diff options
context:
space:
mode:
authorSucheta Chakraborty <sucheta.chakraborty@qlogic.com>2010-03-07 19:14:46 -0500
committerDavid S. Miller <davem@davemloft.net>2010-03-08 13:45:29 -0500
commit8bfe8b91b8b877066c8ac788f59a40324eaac6d8 (patch)
treea2347ff6e35f69af10a673e9173630a5e7e7eebd /drivers/net/qlcnic/qlcnic_init.c
parent8bae5698616ac336938684ce7a7370299bd55d01 (diff)
qlcnic: additional driver statistics.
Statistics added for lro/lso bytes, count for tx stop queue and wake queue and skb alloc failure count. Signed-off-by: Sucheta Chakraborty <sucheta.chakraborty@qlogic.com> Signed-off-by: Amit Kumar Salecha <amit.salecha@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/qlcnic/qlcnic_init.c')
-rw-r--r--drivers/net/qlcnic/qlcnic_init.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/net/qlcnic/qlcnic_init.c b/drivers/net/qlcnic/qlcnic_init.c
index ea00ab4d4feb..f0df9717aece 100644
--- a/drivers/net/qlcnic/qlcnic_init.c
+++ b/drivers/net/qlcnic/qlcnic_init.c
@@ -1114,8 +1114,10 @@ qlcnic_alloc_rx_skb(struct qlcnic_adapter *adapter,
1114 struct pci_dev *pdev = adapter->pdev; 1114 struct pci_dev *pdev = adapter->pdev;
1115 1115
1116 buffer->skb = dev_alloc_skb(rds_ring->skb_size); 1116 buffer->skb = dev_alloc_skb(rds_ring->skb_size);
1117 if (!buffer->skb) 1117 if (!buffer->skb) {
1118 adapter->stats.skb_alloc_failure++;
1118 return -ENOMEM; 1119 return -ENOMEM;
1120 }
1119 1121
1120 skb = buffer->skb; 1122 skb = buffer->skb;
1121 1123
@@ -1289,7 +1291,7 @@ qlcnic_process_lro(struct qlcnic_adapter *adapter,
1289 netif_receive_skb(skb); 1291 netif_receive_skb(skb);
1290 1292
1291 adapter->stats.lro_pkts++; 1293 adapter->stats.lro_pkts++;
1292 adapter->stats.rxbytes += length; 1294 adapter->stats.lrobytes += length;
1293 1295
1294 return buffer; 1296 return buffer;
1295} 1297}
@@ -1505,6 +1507,8 @@ qlcnic_process_rcv_diag(struct qlcnic_adapter *adapter,
1505 adapter->diag_cnt++; 1507 adapter->diag_cnt++;
1506 1508
1507 dev_kfree_skb_any(skb); 1509 dev_kfree_skb_any(skb);
1510 adapter->stats.rx_pkts++;
1511 adapter->stats.rxbytes += length;
1508 1512
1509 return buffer; 1513 return buffer;
1510} 1514}