Skip to content

Commit

Permalink
rtw88: coex: only skip coex triggered by BT info
Browse files Browse the repository at this point in the history
The coex mechanism used to skip upon the freeze flag is raised.
That will cause the coex mechanism being skipped unexpectedly.
Coex only wanted to keep the TDMA table from being changed by
BT side.

So, check the freeze and reason, if the coex reason is coming
from BT info, skip it, to make sure the coex triggered by Wifi
itself can work.

This is required for the AP mode, while the control flow is
different with STA mode. When starting an AP mode, the AP mode
needs to start working immedaitely after leaving IPS, and the
freeze flag could be raised. If the coex info is skipped, then
the AP mode will not set the antenna owner, leads to TX stuck.

Fixes: 4136214 ("rtw88: add BT co-existence support")
Signed-off-by: Yan-Hsuan Chuang <[email protected]>
Signed-off-by: Kalle Valo <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
  • Loading branch information
Yan-Hsuan Chuang authored and Kalle Valo committed Aug 2, 2020
1 parent d8e030c commit 3f194bd
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/realtek/rtw88/coex.c
Original file line number Diff line number Diff line change
Expand Up @@ -1962,7 +1962,8 @@ static void rtw_coex_run_coex(struct rtw_dev *rtwdev, u8 reason)
if (coex_stat->wl_under_ips)
return;

if (coex->freeze && !coex_stat->bt_setup_link)
if (coex->freeze && coex_dm->reason == COEX_RSN_BTINFO &&
!coex_stat->bt_setup_link)
return;

coex_stat->cnt_wl[COEX_CNT_WL_COEXRUN]++;
Expand Down

0 comments on commit 3f194bd

Please sign in to comment.