wifi: rtl8xxxu: Remove usage of tx_info->control.rates[0].flags
authorMartin Kaistra <martin.kaistra@linutronix.de>
Fri, 28 Apr 2023 15:08:31 +0000 (17:08 +0200)
committerKalle Valo <kvalo@kernel.org>
Fri, 5 May 2023 07:30:14 +0000 (10:30 +0300)
commit19b396c241cfdcb4431491d07ff586f78436754a
treefb2c31e3f0c96a0003d6b48feb8855d6d0e87cd8
parent07342528f7c8b7ca156ee6d8c132e42579b37bb9
wifi: rtl8xxxu: Remove usage of tx_info->control.rates[0].flags

As this driver uses HAS_RATE_CONTROL, rate_flags will not be provided by
mac80211.

Stop using tx_info->control.rates[0].flags and ieee80211_get_rts_cts_rate()
and use rts_threshold and bss_conf.use_cts_prot instead to determine
when to use RTS and CTS.

Send RTS with 24M rate like the vendor drivers. Also set this RTS rate
for ampdu_enable = true, because we also enable RTS for these frames.

Signed-off-by: Martin Kaistra <martin.kaistra@linutronix.de>
Reviewed-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230428150833.218605-17-martin.kaistra@linutronix.de
drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_core.c