mirror of
https://github.com/torvalds/linux.git
synced 2026-06-03 20:14:06 +02:00
wifi: rtw89: coex: Update function to get BT RSSI and hardware counter
Correct Bluetooth RSSI count method. The 6dB is the gap between hardware packet sampled value and real RSSI value. Signed-off-by: Ching-Te Ku <ku920601@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/20230412012831.10519-4-pkshih@realtek.com
This commit is contained in:
parent
9fde305628
commit
2380a22031
|
|
@ -1832,7 +1832,8 @@ rtw8852a_btc_set_wl_txpwr_ctrl(struct rtw89_dev *rtwdev, u32 txpwr_val)
|
|||
static
|
||||
s8 rtw8852a_btc_get_bt_rssi(struct rtw89_dev *rtwdev, s8 val)
|
||||
{
|
||||
return clamp_t(s8, val, -100, 0) + 100;
|
||||
/* +6 for compensate offset */
|
||||
return clamp_t(s8, val + 6, -100, 0) + 100;
|
||||
}
|
||||
|
||||
static struct rtw89_btc_rf_trx_para rtw89_btc_8852a_rf_ul[] = {
|
||||
|
|
|
|||
|
|
@ -2279,7 +2279,8 @@ do { \
|
|||
static
|
||||
s8 rtw8852b_btc_get_bt_rssi(struct rtw89_dev *rtwdev, s8 val)
|
||||
{
|
||||
return clamp_t(s8, val, -100, 0) + 100;
|
||||
/* +6 for compensate offset */
|
||||
return clamp_t(s8, val + 6, -100, 0) + 100;
|
||||
}
|
||||
|
||||
static
|
||||
|
|
|
|||
|
|
@ -2533,7 +2533,8 @@ do { \
|
|||
static
|
||||
s8 rtw8852c_btc_get_bt_rssi(struct rtw89_dev *rtwdev, s8 val)
|
||||
{
|
||||
return clamp_t(s8, val, -100, 0) + 100;
|
||||
/* +6 for compensate offset */
|
||||
return clamp_t(s8, val + 6, -100, 0) + 100;
|
||||
}
|
||||
|
||||
static const struct rtw89_btc_rf_trx_para rtw89_btc_8852c_rf_ul[] = {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user