From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=211.75.126.72 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796179072; b=pX7KcLqIK4u5sEa7wJRzMhAduJ4+AZYzoQr7BR+bGO2L8GwETKUjmamTlIyYslAbHuNm vTn1jXfUPS0NGzrSng7SFc2gjTVz70newLV3C67S7teeE9FxZPptZ4FfswctAi4LqF+eX +Gnm679I3L0VKtGdTASlg4Ix9leotYl4VIn3D9DoJf2CA6wIrlCG/68/au8fhc+LjlZVQ Tli5p4usPDVoy2QHT5bFWNIQ6RVs3Fvq5PaPJcJQ6l2MeJItmcjaR1MMqQ2R1M1y855iy zdl4MuNM2Mm8V3aX82O6qdyrMM/jeZdUibfN2xOpgbhsHoGBGUoXbPkz7MqAcztBMDw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796179072; h=DMARC-Filter:X-SpamFilter-By:DKIM-Signature:Received:Received: Received:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID: References:In-Reply-To:Accept-Language:Content-Language: x-originating-ip:Content-Type:Content-Transfer-Encoding:MIME-Version; bh=5kVI97As1Mzu6cb/J+/rkG1nADs2A+NFXAKqv8MsaAA=; b=xYSNv+Bih2q8lgw1Tj3UdQDZxA4H+HK7XXuXjZxM3vjoC3tOWNaeF4CKc4149bnSAvTv 5AaAc7lcPcc9cK0013MTj1x4rG163b3vgU4UgfTQwUBFt3slIscmmWMuKwTL5egQpVBfR JCGpLWaB+RqVwPw8fGfPoCPoCoiSVmZgK0Ait6PmtK2WiSFXsvX4PdktW7SyW1F6UVGOJ Cgz9fnqs39kH7waGsqCKHDqYGLI3NPvrlaXdvB/WW/MnhUQFeT/Sa93KvEbpfODKUrK4R aePMM7t0S6zJLJaowwcMeFpV7Knq+f2O0PO2rwgceT0tXWQF1t1+xYfuO+pzMNRhyVg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=realtek.com; spf=pass smtp.mailfrom=realtek.com; dkim=pass header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=IMmfLXLv; arc=none smtp.remote-ip=211.75.126.72 Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4B1EC606A31A for ; Wed, 2 Dec 2026 02:37:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 4B1EC606A31A Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=realtek.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=realtek.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=IMmfLXLv X-SpamFilter-By: ArmorX SpamTrap 5.80 with qID 6B22bfSeB634279, This message is accepted by code: ctloc85258 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=realtek.com; s=dkim; t=1796179061; bh=5kVI97As1Mzu6cb/J+/rkG1nADs2A+NFXAKqv8MsaAA=; h=From:To:CC:Subject:Date:Message-ID:References:In-Reply-To: Content-Type:Content-Transfer-Encoding:MIME-Version; b=IMmfLXLvqw9NK757yWqRTVzxe+Rhp/CyHBiUctzNe8C1B6shIoBA8TsenzVHlV7Jx BU8RvyetZfmeLvmdaTXg+krd7mp3IZ+5KOVEmfyXMOavwl3JXFurd6UJWDcmcg3yH6 i7WBKuk56nBCTsMRnv9MLfCSu1ZxPL6DlHDkseexvTCLTcGHgObfbib9tPJ/YlP2Tf iEHcVvaex5q0aBnPQcs2Ob8v+NeOFy50AuO++SW6svc1ZRVX6O4p++eC6JnTP5MbG0 Oeftb/7CNR5nSwdfIQdJaIdj6yQzYB0On2XYGeo/G4f3GA+QAZtjdekxDxoySWHfPB 4ovO+j/prLn7g== Received: from mail.realtek.com (rtkexhmbs04.realtek.com.tw[10.21.1.54]) by rtits2.realtek.com.tw (8.15.2/3.29/5.94) with ESMTPS id 6B22bfSeB634279 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 2 Dec 2026 10:37:41 +0800 Received: from RTKEXHMBS06.realtek.com.tw (10.21.1.56) by RTKEXHMBS04.realtek.com.tw (10.21.1.54) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.56; Wed, 2 Dec 2026 10:37:41 +0800 Received: from RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef]) by RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef%10]) with mapi id 15.02.2562.056; Wed, 2 Dec 2026 10:37:41 +0800 From: Ping-Ke Shih To: Ho Jie Feng CC: "linux-wireless@vger.kernel.org" , Bitterblue Smith , Luka Gejak Subject: RE: [PATCH rtw-next v5 6/7] wifi: rtw88: 88xxa: correct carrier-frequency offset Thread-Topic: [PATCH rtw-next v5 6/7] wifi: rtw88: 88xxa: correct carrier-frequency offset Thread-Index: AQHdfplJoR5t7IX2qEueEEBAS82KmLdJDpbw Date: Wed, 2 Dec 2026 02:37:41 +0000 Message-ID: <85c057dbadcc4cbab5dac7b8ed5574bc@realtek.com> References: <20261127180034.1058591-1-hjf3108@gmail.com> <20261127180034.1058591-7-hjf3108@gmail.com> In-Reply-To: <20261127180034.1058591-7-hjf3108@gmail.com> Accept-Language: en-US, zh-TW Content-Language: zh-TW Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Mailing-List: linux-wireless@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Ho Jie Feng wrote: > Use the newly promoted helpers to implement CFO tracking for 88xxa. >=20 > The PHY status of each received frame reports a CFO tail per RF path. > The CFO tracking code averages them and corrects the offset if the > offset is too large. >=20 > RTL8814A has four RF paths, but reports a CFO tail only for paths A > and B, so we only take the CFO tail of 2 paths. >=20 > The crystal cap is 6 bits wide on all chips except RTL8822C. Obtain > the correct value by masking it. For RTL8814A, use 0x20 if the > the efuse is empty, like the vendor driver. >=20 > Signed-off-by: Ho Jie Feng A small nit. Otherwise,=20 Acked-by: Ping-Ke Shih [...] > @@ -1632,6 +1637,17 @@ void rtw88xxa_query_phy_status(struct rtw_dev *rtw= dev, u8 *phy_status, > power_b =3D power_a; >=20 > pkt_stat->signal_power =3D max3(power_a, power_b, min_rx_= power); > + > + pkt_stat->cfo_tail[RF_PATH_A] =3D > + (s8)le32_get_bits(rpt->w2, RTW_JGRPHY_W2_CFO_TAIL= _A); > + pkt_stat->cfo_tail[RF_PATH_B] =3D > + (s8)le32_get_bits(rpt->w2, RTW_JGRPHY_W2_CFO_TAIL= _B); nit: force casting is not necessary.=20 > + > + /* convert to kHz (used only for debugfs) */ > + for (i =3D RF_PATH_A; i < rtwdev->hal.rf_path_num; i++) > + dm_info->cfo_tail[i] =3D (pkt_stat->cfo_tail[i] *= 5) >> 1; > + > + rtw_phy_parsing_cfo(rtwdev, pkt_stat); > } > } > EXPORT_SYMBOL(rtw88xxa_query_phy_status);