aboutsummaryrefslogtreecommitdiff
path: root/net/mac80211/rx.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2007-08-24 11:29:34 -0700
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 16:49:31 -0700
commit68aae11674b9d6598b660d1148ffba9eef3f895f (patch)
treed5213c5b624e9908b948f2642b7e15721021b4ee /net/mac80211/rx.c
parent24338793eea9dcc0865826e1115af86a19af8d18 (diff)
[MAC80211]: use internal network device stats
Stats are now available for device usage inside network_device Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Acked-by: Johannes Berg <johannes@sipsolutions.net> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mac80211/rx.c')
-rw-r--r--net/mac80211/rx.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 28b8b6af4c4..a5619d1f9a3 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -137,7 +137,6 @@ ieee80211_rx_monitor(struct net_device *dev, struct sk_buff *skb,
struct ieee80211_rx_status *status)
{
struct ieee80211_local *local = wdev_priv(dev->ieee80211_ptr);
- struct ieee80211_sub_if_data *sdata;
struct ieee80211_rate *rate;
struct ieee80211_rtap_hdr {
struct ieee80211_radiotap_header hdr;
@@ -150,8 +149,6 @@ ieee80211_rx_monitor(struct net_device *dev, struct sk_buff *skb,
skb->dev = dev;
- sdata = IEEE80211_DEV_TO_SUB_IF(dev);
-
if (status->flag & RX_FLAG_RADIOTAP)
goto out;
@@ -184,8 +181,8 @@ ieee80211_rx_monitor(struct net_device *dev, struct sk_buff *skb,
rthdr->antsignal = status->ssi;
out:
- sdata->stats.rx_packets++;
- sdata->stats.rx_bytes += skb->len;
+ dev->stats.rx_packets++;
+ dev->stats.rx_bytes += skb->len;
skb_set_mac_header(skb, 0);
skb->ip_summed = CHECKSUM_UNNECESSARY;
@@ -1053,8 +1050,8 @@ ieee80211_rx_h_data(struct ieee80211_txrx_data *rx)
skb2 = NULL;
- sdata->stats.rx_packets++;
- sdata->stats.rx_bytes += skb->len;
+ dev->stats.rx_packets++;
+ dev->stats.rx_bytes += skb->len;
if (local->bridge_packets && (sdata->type == IEEE80211_IF_TYPE_AP
|| sdata->type == IEEE80211_IF_TYPE_VLAN) &&