Skip to content

Commit

Permalink
rtw89: coex: set EN bit to PLT register
Browse files Browse the repository at this point in the history
B_AX_PLT_EN is to enable polluted mechanism. If it is enabled and
gnt_bt = 1 while wlan TX, B_AX_BT_PLT_PKT_CNT counter will increase,
but TX counter to BB will not. Without this bit BTCoex mechanism might
have some problems.

Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220208082751.43553-1-pkshih@realtek.com
  • Loading branch information
Ping-Ke Shih authored and Kalle Valo committed Feb 10, 2022
1 parent 3c2c2e2 commit 28e7ea8
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions drivers/net/wireless/realtek/rtw89/mac.c
Original file line number Diff line number Diff line change
Expand Up @@ -3442,7 +3442,7 @@ int rtw89_mac_cfg_gnt(struct rtw89_dev *rtwdev,
int rtw89_mac_cfg_plt(struct rtw89_dev *rtwdev, struct rtw89_mac_ax_plt *plt)
{
u32 reg;
u8 val;
u16 val;
int ret;

ret = rtw89_mac_check_mac_en(rtwdev, plt->band, RTW89_CMAC_SEL);
Expand All @@ -3457,8 +3457,9 @@ int rtw89_mac_cfg_plt(struct rtw89_dev *rtwdev, struct rtw89_mac_ax_plt *plt)
(plt->rx & RTW89_MAC_AX_PLT_LTE_RX ? B_AX_RX_PLT_GNT_LTE_RX : 0) |
(plt->rx & RTW89_MAC_AX_PLT_GNT_BT_TX ? B_AX_RX_PLT_GNT_BT_TX : 0) |
(plt->rx & RTW89_MAC_AX_PLT_GNT_BT_RX ? B_AX_RX_PLT_GNT_BT_RX : 0) |
(plt->rx & RTW89_MAC_AX_PLT_GNT_WL ? B_AX_RX_PLT_GNT_WL : 0);
rtw89_write8(rtwdev, reg, val);
(plt->rx & RTW89_MAC_AX_PLT_GNT_WL ? B_AX_RX_PLT_GNT_WL : 0) |
B_AX_PLT_EN;
rtw89_write16(rtwdev, reg, val);

return 0;
}
Expand Down

0 comments on commit 28e7ea8

Please sign in to comment.