diff options
author | Ilpo Järvinen <ilpo.jarvinen@helsinki.fi> | 2008-11-28 18:52:00 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-11-28 18:52:00 -0500 |
commit | 9fd428761adbd5fbd7e23c312955eec1db8ace7a (patch) | |
tree | 93db00382308da5901ea5852141692ba642e9aa4 | |
parent | 6113b748fb9935399ec2bbca3a3dc82008f6167f (diff) |
niu: use net_device_stats nowadays available in net_device
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/net/niu.c | 16 | ||||
-rw-r--r-- | drivers/net/niu.h | 1 |
2 files changed, 8 insertions, 9 deletions
diff --git a/drivers/net/niu.c b/drivers/net/niu.c index 2f98f7a4117a..022866dc0915 100644 --- a/drivers/net/niu.c +++ b/drivers/net/niu.c | |||
@@ -6078,10 +6078,10 @@ static void niu_get_rx_stats(struct niu *np) | |||
6078 | dropped += rp->rx_dropped; | 6078 | dropped += rp->rx_dropped; |
6079 | errors += rp->rx_errors; | 6079 | errors += rp->rx_errors; |
6080 | } | 6080 | } |
6081 | np->net_stats.rx_packets = pkts; | 6081 | np->dev->stats.rx_packets = pkts; |
6082 | np->net_stats.rx_bytes = bytes; | 6082 | np->dev->stats.rx_bytes = bytes; |
6083 | np->net_stats.rx_dropped = dropped; | 6083 | np->dev->stats.rx_dropped = dropped; |
6084 | np->net_stats.rx_errors = errors; | 6084 | np->dev->stats.rx_errors = errors; |
6085 | } | 6085 | } |
6086 | 6086 | ||
6087 | static void niu_get_tx_stats(struct niu *np) | 6087 | static void niu_get_tx_stats(struct niu *np) |
@@ -6097,9 +6097,9 @@ static void niu_get_tx_stats(struct niu *np) | |||
6097 | bytes += rp->tx_bytes; | 6097 | bytes += rp->tx_bytes; |
6098 | errors += rp->tx_errors; | 6098 | errors += rp->tx_errors; |
6099 | } | 6099 | } |
6100 | np->net_stats.tx_packets = pkts; | 6100 | np->dev->stats.tx_packets = pkts; |
6101 | np->net_stats.tx_bytes = bytes; | 6101 | np->dev->stats.tx_bytes = bytes; |
6102 | np->net_stats.tx_errors = errors; | 6102 | np->dev->stats.tx_errors = errors; |
6103 | } | 6103 | } |
6104 | 6104 | ||
6105 | static struct net_device_stats *niu_get_stats(struct net_device *dev) | 6105 | static struct net_device_stats *niu_get_stats(struct net_device *dev) |
@@ -6109,7 +6109,7 @@ static struct net_device_stats *niu_get_stats(struct net_device *dev) | |||
6109 | niu_get_rx_stats(np); | 6109 | niu_get_rx_stats(np); |
6110 | niu_get_tx_stats(np); | 6110 | niu_get_tx_stats(np); |
6111 | 6111 | ||
6112 | return &np->net_stats; | 6112 | return &dev->stats; |
6113 | } | 6113 | } |
6114 | 6114 | ||
6115 | static void niu_load_hash_xmac(struct niu *np, u16 *hash) | 6115 | static void niu_load_hash_xmac(struct niu *np, u16 *hash) |
diff --git a/drivers/net/niu.h b/drivers/net/niu.h index cf449aad7f15..e1a7392e8d70 100644 --- a/drivers/net/niu.h +++ b/drivers/net/niu.h | |||
@@ -3249,7 +3249,6 @@ struct niu { | |||
3249 | spinlock_t lock; | 3249 | spinlock_t lock; |
3250 | 3250 | ||
3251 | const struct niu_ops *ops; | 3251 | const struct niu_ops *ops; |
3252 | struct net_device_stats net_stats; | ||
3253 | union niu_mac_stats mac_stats; | 3252 | union niu_mac_stats mac_stats; |
3254 | 3253 | ||
3255 | struct rx_ring_info *rx_rings; | 3254 | struct rx_ring_info *rx_rings; |