OSDN Git Service

rtw88: fix hw scan may cause disconnect issue
authorChih-Kang Chang <gary.chang@realtek.com>
Thu, 28 Apr 2022 02:05:21 +0000 (10:05 +0800)
committerKalle Valo <kvalo@kernel.org>
Sun, 1 May 2022 16:13:22 +0000 (19:13 +0300)
commit5b3fd8fd7ceb135d08edf52adf6e833ee92a351e
tree69bc0c7b040e590aca527000495de58913b5a8f0
parent02ee806843bd8ee868a0a2ff4364188807ce321d
rtw88: fix hw scan may cause disconnect issue

After scan aborts we still receive some hw scan c2h packets, and
processing these c2h commands will change current channel. If device
already connect to other AP, driver will set wrong op channel due
to current channel changed. The disconnection happens when hw scan back
to wrong op channel that device can't receive beacon from AP. To fix
this issue, we ignore the late c2h if we are not scanning, and set
current channel back to op channel after scan to align the FW behavior.

Signed-off-by: Chih-Kang Chang <gary.chang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220428020521.8015-3-pkshih@realtek.com
drivers/net/wireless/realtek/rtw88/fw.c