summaryrefslogtreecommitdiffstats
path: root/net/mac80211/rate.h
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2012-02-08 19:17:11 +0100
committerJohn W. Linville <linville@tuxdriver.com>2012-02-08 16:07:31 -0500
commit2cfc6fc584a65db87935ca4e4d5e1ad89d5192ee (patch)
treecebba13955a1702bf73ffa29a648b01a5942bcfa /net/mac80211/rate.h
parent42bc0c9716c456a9686fcd4ee5cf115b992b9952 (diff)
downloadblackbird-op-linux-2cfc6fc584a65db87935ca4e4d5e1ad89d5192ee.tar.gz
blackbird-op-linux-2cfc6fc584a65db87935ca4e4d5e1ad89d5192ee.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>
Diffstat (limited to 'net/mac80211/rate.h')
-rw-r--r--net/mac80211/rate.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/mac80211/rate.h b/net/mac80211/rate.h
index 5fc3135a6b45..fbb1efdc4d04 100644
--- a/net/mac80211/rate.h
+++ b/net/mac80211/rate.h
@@ -37,7 +37,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);
OpenPOWER on IntegriCloud