ath9k: set the STBC flag in rate control if the peer supports it
authorFelix Fietkau <nbd@openwrt.org>
Mon, 19 Apr 2010 17:57:37 +0000 (19:57 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 20 Apr 2010 15:52:39 +0000 (11:52 -0400)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/rc.c

index f10bd06dc2188e0511765ab4cf090d5736310714..66bc1f6c8ccf69dd4d4bb6bfd4f703a8cf45537d 100644 (file)
@@ -698,6 +698,10 @@ static void ath_get_rate(void *priv, struct ieee80211_sta *sta, void *priv_sta,
            (sta->ht_cap.cap & IEEE80211_HT_CAP_LDPC_CODING))
                tx_info->flags |= IEEE80211_TX_CTL_LDPC;
 
+       if (conf_is_ht(&sc->hw->conf) &&
+           (sta->ht_cap.cap & IEEE80211_HT_CAP_TX_STBC))
+               tx_info->flags |= (1 << IEEE80211_TX_CTL_STBC_SHIFT);
+
        if (is_probe) {
                /* set one try for probe rates. For the
                 * probes don't enable rts */