diff options
author | Felix Fietkau <nbd@openwrt.org> | 2012-02-08 19:17:11 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2012-02-15 19:56:06 +0100 |
commit | 216c57b214bd621335ff698b475f6db2802502dc (patch) | |
tree | 3d436e04f60577c634106db5099f39e376b98a86 | |
parent | mac80211: call rate control only after init (diff) | |
download | linux-216c57b214bd621335ff698b475f6db2802502dc.tar.xz linux-216c57b214bd621335ff698b475f6db2802502dc.zip |
mac80211: do not call rate control .tx_status before .rate_init
Most rate control implementations assume .get_rate and .tx_status are only
called once the per-station data has been fully initialized.
minstrel_ht crashes if this assumption is violated.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Tested-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | net/mac80211/rate.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/rate.h b/net/mac80211/rate.h index 2b83f32144fd..80cfc006dd74 100644 --- a/net/mac80211/rate.h +++ b/net/mac80211/rate.h @@ -41,7 +41,7 @@ static inline void rate_control_tx_status(struct ieee80211_local *local, struct ieee80211_sta *ista = &sta->sta; void *priv_sta = sta->rate_ctrl_priv; - if (!ref) + if (!ref || !test_sta_flag(sta, WLAN_STA_RATE_CONTROL)) return; ref->ops->tx_status(ref->priv, sband, ista, priv_sta, skb); |