Browse Source

net: cxgb: Use net_device_stats from struct net_device

Instead of using a private copy of struct net_device_stats in struct
port_info, use stats from struct net_device.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Tobias Klauser 8 years ago
parent
commit
a3bb456002

+ 0 - 1
drivers/net/ethernet/chelsio/cxgb/common.h

@@ -223,7 +223,6 @@ struct port_info {
 	struct cmac *mac;
 	struct cphy *phy;
 	struct link_config link_config;
-	struct net_device_stats netstats;
 };
 
 struct sge;

+ 1 - 1
drivers/net/ethernet/chelsio/cxgb/cxgb2.c

@@ -296,7 +296,7 @@ static struct net_device_stats *t1_get_stats(struct net_device *dev)
 {
 	struct adapter *adapter = dev->ml_priv;
 	struct port_info *p = &adapter->port[dev->if_port];
-	struct net_device_stats *ns = &p->netstats;
+	struct net_device_stats *ns = &dev->stats;
 	const struct cmac_statistics *pstats;
 
 	/* Do a full update of the MAC stats */