]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
wifi: rtw89: 8852bt: Remove redundant off_reverse variables
authorLiao Yuanhong <liaoyuanhong@vivo.com>
Thu, 28 Aug 2025 09:47:17 +0000 (17:47 +0800)
committerPing-Ke Shih <pkshih@realtek.com>
Mon, 1 Sep 2025 03:41:23 +0000 (11:41 +0800)
The variable off_reverse and its related code are completely redundant in
the function. Remove them to clean the code.

Signed-off-by: Liao Yuanhong <liaoyuanhong@vivo.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Link: https://patch.msgid.link/20250828094717.599527-1-liaoyuanhong@vivo.com
drivers/net/wireless/realtek/rtw89/rtw8852bt_rfk.c

index 99cb6a973de2d6c7391a8bb9195be66dc4ef4c0f..961b26ba2d3c40245c5c710224ea243820a59c5b 100644 (file)
@@ -1799,19 +1799,14 @@ static void _dpk_onoff(struct rtw89_dev *rtwdev, enum rtw89_rf_path path, bool o
 {
        struct rtw89_dpk_info *dpk = &rtwdev->dpk;
        u8 val, kidx = dpk->cur_idx[path];
-       bool off_reverse;
 
        val = dpk->is_dpk_enable && !off && dpk->bp[path][kidx].path_ok;
 
-       off_reverse = !off;
-
-       val = dpk->is_dpk_enable & off_reverse & dpk->bp[path][kidx].path_ok;
-
        rtw89_phy_write32_mask(rtwdev, R_DPD_CH0A + (path << 8) + (kidx << 2),
                               BIT(24), val);
 
        rtw89_debug(rtwdev, RTW89_DBG_RFK, "[DPK] S%d[%d] DPK %s !!!\n", path,
-                   kidx, str_enable_disable(dpk->is_dpk_enable & off_reverse));
+                   kidx, str_enable_disable(dpk->is_dpk_enable && !off));
 }
 
 static void _dpk_one_shot(struct rtw89_dev *rtwdev, enum rtw89_phy_idx phy,