diff options
author | adrian <adrian@FreeBSD.org> | 2012-04-08 04:51:25 +0000 |
---|---|---|
committer | adrian <adrian@FreeBSD.org> | 2012-04-08 04:51:25 +0000 |
commit | f16af2226ba072844f58cb8b0d7fcbd4f48ec99d (patch) | |
tree | eca6434a25244159833ec37231b9e39b582ee119 /sys/net80211/ieee80211_ht.c | |
parent | ba0f3fb560cc3c6f37441370a2a2eef98e7a0f3d (diff) | |
download | FreeBSD-src-f16af2226ba072844f58cb8b0d7fcbd4f48ec99d.zip FreeBSD-src-f16af2226ba072844f58cb8b0d7fcbd4f48ec99d.tar.gz |
Add some statistics to track BAR TX.
Diffstat (limited to 'sys/net80211/ieee80211_ht.c')
-rw-r--r-- | sys/net80211/ieee80211_ht.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/sys/net80211/ieee80211_ht.c b/sys/net80211/ieee80211_ht.c index d403220..db6b605 100644 --- a/sys/net80211/ieee80211_ht.c +++ b/sys/net80211/ieee80211_ht.c @@ -2182,10 +2182,13 @@ bar_timeout(void *arg) if ((tap->txa_flags & IEEE80211_AGGR_BARPEND) == 0) return; /* XXX ? */ - if (tap->txa_attempts >= ieee80211_bar_maxtries) + if (tap->txa_attempts >= ieee80211_bar_maxtries) { + ni->ni_vap->iv_stats.is_ampdu_bar_tx_fail++; ieee80211_ampdu_stop(ni, tap, IEEE80211_REASON_TIMEOUT); - else + } else { + ni->ni_vap->iv_stats.is_ampdu_bar_tx_retry++; ieee80211_send_bar(ni, tap, tap->txa_seqpending); + } } static void @@ -2210,6 +2213,7 @@ bar_tx_complete(struct ieee80211_node *ni, void *arg, int status) __func__, tap->txa_ac, tap->txa_flags, callout_pending(&tap->txa_timer), status); + ni->ni_vap->iv_stats.is_ampdu_bar_tx++; /* XXX locking */ if ((tap->txa_flags & IEEE80211_AGGR_BARPEND) && callout_pending(&tap->txa_timer)) { @@ -2325,6 +2329,7 @@ ieee80211_send_bar(struct ieee80211_node *ni, if (ret != 0) { /* xmit failed, clear state flag */ tap->txa_flags &= ~IEEE80211_AGGR_BARPEND; + vap->iv_stats.is_ampdu_bar_tx_fail++; return ret; } /* XXX hack against tx complete happening before timer is started */ @@ -2332,6 +2337,7 @@ ieee80211_send_bar(struct ieee80211_node *ni, bar_start_timer(tap); return 0; bad: + vap->iv_stats.is_ampdu_bar_tx_fail++; ieee80211_free_node(ni); return ret; #undef senderr |