Skip to contentSkip to conversation

wifi: rtw88: 8723b: don't set channel_invalid in query_phy_status()

PATCH In review Luka Gejak 2 participants 3 messages Oct 9 – Nov 3 Realtek wireless driver (rtw88)

lore
Share & tools
lore

Luka Gejak

author
#0 lore raw

PATCH 1/1 wifi: rtw88: 8723b: don't set channel_invalid in query_phy_status()

rtw8723b_query_phy_status() sets pkt_stat->channel_invalid, which makes rtw_update_rx_freq_for_invalid() call rtw_update_rx_freq_from_ie() and overwrite rx_status->freq with rtwdev->hal.current_channel. rtw_update_channel() keeps the center channel in that field, not the primary one, so on a 40 MHz connection mac80211 is handed a frequency it rejects in ieee80211_rx_beacon_freq_valid() and reports beacon loss for beacons the driver did receive. Only beacons go through that check, so data traffic is unaffected.

Remove it now, so that the non-SDIO members of the 8723B family do not report beacon loss once they are supported. SDIO is unaffected, because rtw_sdio_rx_skb() copies the status into the skb before the update runs.

---
 drivers/net/wireless/realtek/rtw88/rtw8723b.c | 7 -------
 1 file changed, 7 deletions(-)
drivers/net/wireless/realtek/rtw88/rtw8723b.c +0 -7
index 8bb9c03d769c..0c37e981ec84 100644
@@ -1303,13 +1303,6 @@ static void rtw8723b_query_phy_status_ofdm(struct rtw_dev *rtwdev, void *phy_raw
 static void rtw8723b_query_phy_status(struct rtw_dev *rtwdev, u8 *phy_status,
 				      struct rtw_rx_pkt_stat *pkt_stat)
 {
-	/*
-	 * The 8723B PHY status does not report the channel, so we must
-	 * mark it invalid to allow mac80211/rtw88 to parse it from the IE
-	 * during scanning.
-	 */
-	pkt_stat->channel_invalid = true;
-
 	if (pkt_stat->rate <= DESC_RATE11M)
 		rtw8723b_query_phy_status_cck(rtwdev, phy_status, pkt_stat);
 	else
Signature · 1 line
2.55.0
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 9 lines · Luka Gejak

rtw8723b_query_phy_status() sets pkt_stat->channel_invalid, which makes rtw_update_rx_freq_for_invalid() call rtw_update_rx_freq_from_ie() and overwrite rx_status->freq with rtwdev->hal.current_channel. rtw_update_channel() keeps the center channel in that field, not the primary one, so on a 40 MHz connection mac80211 is handed a frequency it rejects in ieee80211_rx_beacon_freq_valid() and reports beacon loss for beacons the driver did receive. Only beacons go through that check, so data traffic is unaffected.

Quoted 6 lines

Remove it now, so that the non-SDIO members of the 8723B family do not report beacon loss once they are supported. SDIO is unaffected, because rtw_sdio_rx_skb() copies the status into the skb before the update runs.

maintainer
#2 lore raw
In reply to Luka Gejak
Quoted 9 lines · Luka Gejak

rtw8723b_query_phy_status() sets pkt_stat->channel_invalid, which makes rtw_update_rx_freq_for_invalid() call rtw_update_rx_freq_from_ie() and overwrite rx_status->freq with rtwdev->hal.current_channel. rtw_update_channel() keeps the center channel in that field, not the primary one, so on a 40 MHz connection mac80211 is handed a frequency it rejects in ieee80211_rx_beacon_freq_valid() and reports beacon loss for beacons the driver did receive. Only beacons go through that check, so data traffic is unaffected.

Quoted 7 lines

Remove it now, so that the non-SDIO members of the 8723B family do not report beacon loss once they are supported. SDIO is unaffected, because rtw_sdio_rx_skb() copies the status into the skb before the update runs.

1 patch(es) applied to rtw-next branch of rtw.git, thanks.

1cca8775c2e5 wifi: rtw88: 8723b: don't set channel_invalid in query_phy_status()

---
https://github.com/pkshih/rtw.git