wifi: rtw89: add mac TSF sync function
authorPo-Hao Huang <phhuang@realtek.com>
Fri, 2 Dec 2022 06:15:24 +0000 (14:15 +0800)
committerKalle Valo <kvalo@kernel.org>
Thu, 8 Dec 2022 14:47:58 +0000 (16:47 +0200)
commitfb2b8cec81d75b2b20bdbc2fca7a60a68bc78aac
tree2762ea64b9947b9cdcf5914353171195b4871b88
parent13eb07e0be1b95f1e1fab721fb0f38117edfe80b
wifi: rtw89: add mac TSF sync function

If the interface is in AP/P2P GO mode, we adjust the TSF with random
offset to avoid TBTT of different vifs to overlap and collide.
For every new interface added, we adjust the value and resync for all
interfaces.

Signed-off-by: Po-Hao Huang <phhuang@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/20221202061527.505668-2-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/mac.c
drivers/net/wireless/realtek/rtw89/mac.h
drivers/net/wireless/realtek/rtw89/reg.h