Skip to contentSkip to conversation

wifi: rtw88: restore channel when leaving idle in monitor mode

PATCH In review Martin 3 participants 5 messages Dec 3 – Dec 4 Realtek wireless driver (rtw88)

lore
Share & tools
lore

Martin

author
#0 lore raw

PATCH v2 1/1 wifi: rtw88: restore channel when leaving idle in monitor mode

After a monitor interface is set up a second time on the same channel (down, monitor, up, same frequency), the chip no longer works on that channel. On 5 GHz the RTL8814AU neither receives nor transmits, and the RTL8812AU does not transmit. Setting up the interface on a different channel works.

Tested with RTL8814AU and RTL8812AU (USB).

---
v2:
- Shorten the commit message and name the tested adapters (Ping-Ke)
- Drop the code comment (Ping-Ke)

v1: https://lore.kernel.org/linux-wireless/[email protected]/

Same check as in rtw89 commit e07c9af7bbc8 ("wifi: rtw89: restore channel when leaving idle on non-chanctx devices").

AI tool use (Documentation/process/generated-content.rst): the analysis, the patch and the changelog were written with help from Claude Code, from the register dumps and mac80211 traces of my tests and the discussion on the list. I reviewed and tested the change.

 drivers/net/wireless/realtek/rtw88/mac80211.c | 6 ++++++
 1 file changed, 6 insertions(+)
drivers/net/wireless/realtek/rtw88/mac80211.c +6 -0
index b14d7fffb98..0e4970d6595 100644
@@ -86,6 +86,12 @@ static int rtw_ops_config(struct ieee80211_hw *hw, int radio_idx, u32 changed)
 
 	rtw_leave_lps_deep(rtwdev);
 
+	if (changed & IEEE80211_CONF_CHANGE_IDLE &&
+	    changed & IEEE80211_CONF_CHANGE_MONITOR &&
+	    !(hw->conf.flags & IEEE80211_CONF_IDLE) &&
+	    hw->conf.flags & IEEE80211_CONF_MONITOR)
+		changed |= IEEE80211_CONF_CHANGE_CHANNEL;
+
 	if ((changed & IEEE80211_CONF_CHANGE_IDLE) &&
 	    !(hw->conf.flags & IEEE80211_CONF_IDLE)) {
 		ret = rtw_leave_ips(rtwdev);
Signature · 1 line
2.43.0
maintainer Acked-by on v2 1/1
#1 lore raw
Quoted 6 lines · Martin

After a monitor interface is set up a second time on the same channel (down, monitor, up, same frequency), the chip no longer works on that channel. On 5 GHz the RTL8814AU neither receives nor transmits, and the RTL8812AU does not transmit. Setting up the interface on a different channel works.

Quoted 7 lines

Tested with RTL8814AU and RTL8812AU (USB).

Closes:
https://lore.kernel.org/linux-wireless/[email protected]
er.de/

Please use your full name. I can edit it during committing if you can share.

#2 lore raw
Quoted 2 lines · Ping-Ke Shih

Please use your full name. I can edit it during committing if you can share.

Sorry about that. Please use

and the same name for the author. Thanks for the ack, and thanks Luka for the review.

Martin

Reviewed-by on v2 1/1
#3 lore raw
In reply to Martin
Quoted 6 lines · Martin

After a monitor interface is set up a second time on the same channel (down, monitor, up, same frequency), the chip no longer works on that channel. On 5 GHz the RTL8814AU neither receives nor transmits, and the RTL8812AU does not transmit. Setting up the interface on a different channel works.

Quoted 6 lines

Tested with RTL8814AU and RTL8812AU (USB).

---

With the corrected SOB line,

Best regards,
Luka Gejak

maintainer
#4 lore raw
In reply to Martin
Quoted 6 lines · Martin

After a monitor interface is set up a second time on the same channel (down, monitor, up, same frequency), the chip no longer works on that channel. On 5 GHz the RTL8814AU neither receives nor transmits, and the RTL8812AU does not transmit. Setting up the interface on a different channel works.

Quoted 8 lines

Tested with RTL8814AU and RTL8812AU (USB).

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

a8429ce158ef wifi: rtw88: restore channel when leaving idle in monitor mode

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