aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2011-10-14 01:31:09 -0400
committerDavid S. Miller <davem@davemloft.net>2011-10-17 19:00:55 -0400
commit239c562c94dcdd2aeb3d0c0e604627dec043183e (patch)
tree6cc79d08d451ee9c6035966768e46ae8ae1c289f /drivers/net/ethernet
parent39874861f79c660b35ee734f2169be39cf3ae14e (diff)
ehea: Add 64bit statistics
Switch to using ndo_get_stats64 to get 64bit statistics. v3: [cascardo] use rtnl_link_stats64 as port stats Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r--drivers/net/ethernet/ibm/ehea/ehea.h2
-rw-r--r--drivers/net/ethernet/ibm/ehea/ehea_main.c8
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/ethernet/ibm/ehea/ehea.h b/drivers/net/ethernet/ibm/ehea/ehea.h
index 7aa47d86d9d7..c9dbe5258ca4 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea.h
+++ b/drivers/net/ethernet/ibm/ehea/ehea.h
@@ -448,7 +448,7 @@ struct ehea_bcmc_reg_array {
448struct ehea_port { 448struct ehea_port {
449 struct ehea_adapter *adapter; /* adapter that owns this port */ 449 struct ehea_adapter *adapter; /* adapter that owns this port */
450 struct net_device *netdev; 450 struct net_device *netdev;
451 struct net_device_stats stats; 451 struct rtnl_link_stats64 stats;
452 struct ehea_port_res port_res[EHEA_MAX_PORT_RES]; 452 struct ehea_port_res port_res[EHEA_MAX_PORT_RES];
453 struct platform_device ofdev; /* Open Firmware Device */ 453 struct platform_device ofdev; /* Open Firmware Device */
454 struct ehea_mc_list *mc_list; /* Multicast MAC addresses */ 454 struct ehea_mc_list *mc_list; /* Multicast MAC addresses */
diff --git a/drivers/net/ethernet/ibm/ehea/ehea_main.c b/drivers/net/ethernet/ibm/ehea/ehea_main.c
index 289ad4d31f1d..a0a3c5f747c9 100644
--- a/drivers/net/ethernet/ibm/ehea/ehea_main.c
+++ b/drivers/net/ethernet/ibm/ehea/ehea_main.c
@@ -323,10 +323,10 @@ out:
323 spin_unlock_irqrestore(&ehea_bcmc_regs.lock, flags); 323 spin_unlock_irqrestore(&ehea_bcmc_regs.lock, flags);
324} 324}
325 325
326static struct net_device_stats *ehea_get_stats(struct net_device *dev) 326static struct rtnl_link_stats64 *ehea_get_stats64(struct net_device *dev,
327 struct rtnl_link_stats64 *stats)
327{ 328{
328 struct ehea_port *port = netdev_priv(dev); 329 struct ehea_port *port = netdev_priv(dev);
329 struct net_device_stats *stats = &port->stats;
330 u64 rx_packets = 0, tx_packets = 0, rx_bytes = 0, tx_bytes = 0; 330 u64 rx_packets = 0, tx_packets = 0, rx_bytes = 0, tx_bytes = 0;
331 int i; 331 int i;
332 332
@@ -353,7 +353,7 @@ static void ehea_update_stats(struct work_struct *work)
353 struct ehea_port *port = 353 struct ehea_port *port =
354 container_of(work, struct ehea_port, stats_work.work); 354 container_of(work, struct ehea_port, stats_work.work);
355 struct net_device *dev = port->netdev; 355 struct net_device *dev = port->netdev;
356 struct net_device_stats *stats = &port->stats; 356 struct rtnl_link_stats64 *stats = &port->stats;
357 struct hcp_ehea_port_cb2 *cb2; 357 struct hcp_ehea_port_cb2 *cb2;
358 u64 hret; 358 u64 hret;
359 359
@@ -3004,7 +3004,7 @@ static const struct net_device_ops ehea_netdev_ops = {
3004#ifdef CONFIG_NET_POLL_CONTROLLER 3004#ifdef CONFIG_NET_POLL_CONTROLLER
3005 .ndo_poll_controller = ehea_netpoll, 3005 .ndo_poll_controller = ehea_netpoll,
3006#endif 3006#endif
3007 .ndo_get_stats = ehea_get_stats, 3007 .ndo_get_stats64 = ehea_get_stats64,
3008 .ndo_set_mac_address = ehea_set_mac_addr, 3008 .ndo_set_mac_address = ehea_set_mac_addr,
3009 .ndo_validate_addr = eth_validate_addr, 3009 .ndo_validate_addr = eth_validate_addr,
3010 .ndo_set_rx_mode = ehea_set_multicast_list, 3010 .ndo_set_rx_mode = ehea_set_multicast_list,