]> www.infradead.org Git - linux.git/commit
wifi: rtw89: fix HW scan timeout due to TSF sync issue
authorChih-Kang Chang <gary.chang@realtek.com>
Fri, 19 Jan 2024 08:15:00 +0000 (16:15 +0800)
committerKalle Valo <kvalo@kernel.org>
Tue, 23 Jan 2024 11:38:16 +0000 (13:38 +0200)
commitf59a98c82534e986b06615ba94e060aa3129b08b
tree91b8201f5d4b75e69ac42a7d19a1b7845729849e
parentbcbefbd032df6bfe925e6afeca82eb9d2cc0cb23
wifi: rtw89: fix HW scan timeout due to TSF sync issue

When STA connects to an AP and doesn't receive any beacon yet, the
hardware scan is triggered. This scan begins with the default TSF
value. Once STA receives a beacon when switches back to the operating
channel, its TSF synchronizes with the AP. However, if there is a
significant difference in TSF values between the default value and
the synchronized value, it will cause firmware fail to trigger
interrupt, and the C2H won't be sent out. As a result, the scan
continues until a timeout occurs. To fix this issue, we disable TSF
synchronization during scanning to prevent drastic TSF changes, and
enable TSF synchronization after scan.

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://msgid.link/20240119081501.25223-8-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/fw.c
drivers/net/wireless/realtek/rtw89/mac.c
drivers/net/wireless/realtek/rtw89/mac.h