summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath5k/base.c
diff options
context:
space:
mode:
authorBen Greear <greearb@candelatech.com>2010-10-01 10:54:04 -0700
committerJohn W. Linville <linville@tuxdriver.com>2010-10-05 13:35:25 -0400
commitb72acddbbe521d1372e7e9106e9d72e1cbab3010 (patch)
treeceddb7117ff551d9b65468f81b065212e35e139e /drivers/net/wireless/ath/ath5k/base.c
parent1be7fe8de9f25e173282f8f989f83bc5b5decfe9 (diff)
ath5k: Print rx/tx bytes in debugfs
This adds counters for tx and rx bytes, including any errored packets as well as all wireless headers. Signed-off-by: Ben Greear <greearb@candelatech.com> Acked-by: Bruno Randolf <br1@einfach.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/base.c')
-rw-r--r--drivers/net/wireless/ath/ath5k/base.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
index 2ed327a8d690..d914a31cb0b6 100644
--- a/drivers/net/wireless/ath/ath5k/base.c
+++ b/drivers/net/wireless/ath/ath5k/base.c
@@ -1433,6 +1433,7 @@ static bool
ath5k_receive_frame_ok(struct ath5k_softc *sc, struct ath5k_rx_status *rs)
{
sc->stats.rx_all_count++;
+ sc->stats.rx_bytes_count += rs->rs_datalen;
if (unlikely(rs->rs_status)) {
if (rs->rs_status & AR5K_RXERR_CRC)
@@ -1611,6 +1612,7 @@ ath5k_tx_frame_completed(struct ath5k_softc *sc, struct sk_buff *skb,
int i;
sc->stats.tx_all_count++;
+ sc->stats.tx_bytes_count += skb->len;
info = IEEE80211_SKB_CB(skb);
ieee80211_tx_info_clear_status(info);