From: Ping-Ke Shih <pkshih@realtek.com>
To: Bitterblue Smith <rtl8821cerfe2@gmail.com>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Cc: PierluigiFrullani <pierluigi.frullani@frumar.it>
Subject: RE: [PATCH rtw-next] wifi: rtw89: Override antenna number for RTL8852BE-VS
Date: Wed, 7 Oct 2026 02:03:05 +0000 [thread overview]
Message-ID: <766d080156ef42518e9b50f52eae7523@realtek.com> (raw)
In-Reply-To: <826c8df5-2ee2-4a6a-93d1-2ec4f16840e5@gmail.com>
Bitterblue Smith <rtl8821cerfe2@gmail.com> wrote:
[...]
> diff --git a/drivers/net/wireless/realtek/rtw89/rtw8852b.c
> b/drivers/net/wireless/realtek/rtw89/rtw8852b.c
> index c3c53a6b8119..9d834ea36c1a 100644
> --- a/drivers/net/wireless/realtek/rtw89/rtw8852b.c
> +++ b/drivers/net/wireless/realtek/rtw89/rtw8852b.c
> @@ -353,6 +353,19 @@ static const struct rtw89_btc_fbtc_mreg rtw89_btc_8852b_mon_reg[] = {
> static const u8 rtw89_btc_8852b_wl_rssi_thres[BTC_WL_RSSI_THMAX] = {70, 60, 50, 40};
> static const u8 rtw89_btc_8852b_bt_rssi_thres[BTC_BT_RSSI_THMAX] = {50, 40, 30, 20};
>
> +static int rtw8852b_read_efuse(struct rtw89_dev *rtwdev, u8 *log_map,
> + enum rtw89_efuse_block block)
> +{
> + int ret;
> +
> + ret = rtw8852bx_read_efuse(rtwdev, log_map, block);
I think here should check ret and return directly if not zero.
> +
> + if (rtwdev->efuse.rfe_type == 41)
> + set_bit(RTW89_QUIRK_1ANT, rtwdev->quirks);
> +
> + return ret;
here, return 0;
Though the result is the same, it looks reasonable.
> +}
> +
> static void rtw8852b_pwr_sps_ana(struct rtw89_dev *rtwdev)
> {
> rtw89_write16(rtwdev, R_AX_SPS_ANA_ON_CTRL2, RTL8852B_DEFAULT_SPS_ANA);
> @@ -768,6 +781,13 @@ static void rtw8852b_btc_set_rfe(struct rtw89_dev *rtwdev)
> } else {
> md->ant.type = BTC_ANT_SHARED;
> md->bt0_pos = BTC_BT_BTG;
> +
> + if (test_bit(RTW89_QUIRK_1ANT, rtwdev->quirks)) {
> + md->ant.num = 1;
> + md->ant.single_pos = RF_PATH_B;
> + md->ant.btg_pos = RF_PATH_B;
> + md->ant.stream_cnt = 1;
> + }
The patch [1] in progress also modify here. Maybe, you can rebase after I
merge the patch, or just send v2 based on the patchset if you hurry.
(I'd merge the patch and send pull-request for -next tomorrow.)
[1] https://patchwork.kernel.org/project/linux-wireless/patch/20261004034520.33695-12-pkshih@realtek.com/
> }
> rtwdev->btc.btg_pos = md->ant.btg_pos;
> rtwdev->btc.ant_type = md->ant.type;
next prev parent reply other threads:[~2026-10-07 2:03 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-06 17:37 [PATCH rtw-next] wifi: rtw89: Override antenna number for RTL8852BE-VS Bitterblue Smith
2026-10-07 2:03 ` Ping-Ke Shih [this message]
2026-10-07 5:31 ` Ping-Ke Shih
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=766d080156ef42518e9b50f52eae7523@realtek.com \
--to=pkshih@realtek.com \
--cc=linux-wireless@vger.kernel.org \
--cc=pierluigi.frullani@frumar.it \
--cc=rtl8821cerfe2@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox