Skip to contentSkip to conversation

wifi: rtw89: fw: correct rtw89_fw_h2c_default_cmac_tbl_be()

PATCH In review Wentao Guan 2 participants 5 messages Jun 11 – Jul 3 Realtek wireless driver (rtw89)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 wifi: rtw89: fw: correct rtw89_fw_h2c_default_cmac_tbl_be()

BE_CCTL_INFO_W2_PRELOAD_ENABLE is for h2c->w2, not h2c->w1. These will cause h2c->w1 wrong overlap by w2 and w2 not initialized.

Fixes c73607b3a8ef ("wifi: rtw89: fw: add CMAC H2C command to initialize default value for RTL8922D")
---
 drivers/net/wireless/realtek/rtw89/fw.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/realtek/rtw89/fw.c +1 -1
index 17704f054727a..af9bcdcef8fbb 100644
@@ -3711,7 +3711,7 @@ int rtw89_fw_h2c_default_cmac_tbl_be(struct rtw89_dev *rtwdev,
 		  le32_encode_bits(4, BE_CCTL_INFO_W1_RTS_RTY_LOWEST_RATE);
 	h2c->m1 = cpu_to_le32(BE_CCTL_INFO_W1_ALL);
 
-	h2c->w1 = le32_encode_bits(preld, BE_CCTL_INFO_W2_PRELOAD_ENABLE);
+	h2c->w2 = le32_encode_bits(preld, BE_CCTL_INFO_W2_PRELOAD_ENABLE);
 	h2c->m2 = cpu_to_le32(BE_CCTL_INFO_W2_ALL);
 
 	h2c->m3 = cpu_to_le32(BE_CCTL_INFO_W3_ALL);
Signature · 1 line
2.30.2
maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 2 lines · Wentao Guan

BE_CCTL_INFO_W2_PRELOAD_ENABLE is for h2c->w2, not h2c->w1. These will cause h2c->w1 wrong overlap by w2 and w2 not initialized.

Thanks for the catch.

Quoted 3 lines
Fixes c73607b3a8ef ("wifi: rtw89: fw: add CMAC H2C command to initialize default value for RTL8922D")
maintainer
#2 lore raw
Quoted 10 lines · Ping-Ke Shih

Sent: Thursday, June 11, 2026 5:06 PM
To: Wentao Guan <[email protected]>
Cc: [email protected]; [email protected]; David Yang(楊典軒) <[email protected]>; [email protected]; [email protected]
Subject: RE: [PATCH] wifi: rtw89: fw: correct rtw89_fw_h2c_default_cmac_tbl_be()

Quoted 2 lines · Wentao Guan

BE_CCTL_INFO_W2_PRELOAD_ENABLE is for h2c->w2, not h2c->w1. These will cause h2c->w1 wrong overlap by w2 and w2 not initialized.

Quoted 8 lines

Thanks for the catch.

Quoted 3 lines
Fixes c73607b3a8ef ("wifi: rtw89: fw: add CMAC H2C command to initialize default value for RTL8922D")

To let subject clear, I'll change it to
" wifi: rtw89: fw: correct preload field of w2 in rtw89_fw_h2c_default_cmac_tbl_be() "

#3 lore raw
Quoted 14 lines
Quoted 13 lines · Ping-Ke Shih

Sent: Thursday, June 11, 2026 5:06 PM
To: Wentao Guan <[email protected]>
Cc: [email protected]; [email protected]; David Yang(楊典軒) <[email protected]>; [email protected]; [email protected]
Subject: RE: [PATCH] wifi: rtw89: fw: correct rtw89_fw_h2c_default_cmac_tbl_be()

Quoted 2 lines · Wentao Guan

BE_CCTL_INFO_W2_PRELOAD_ENABLE is for h2c->w2, not h2c->w1. These will cause h2c->w1 wrong overlap by w2 and w2 not initialized.

Thanks for the catch.

Quoted 1 line
Quoted 8 lines
Quoted 5 lines
Quoted 2 lines
Fixes c73607b3a8ef ("wifi: rtw89: fw: add CMAC H2C command to initialize default value for RTL8922D")

To let subject clear, I'll change it to
" wifi: rtw89: fw: correct preload field of w2 in rtw89_fw_h2c_default_cmac_tbl_be() "

OK, thanks for you review.

BRs
Wentao Guan

maintainer
#4 lore raw
In reply to Wentao Guan
Quoted 6 lines · Wentao Guan

BE_CCTL_INFO_W2_PRELOAD_ENABLE is for h2c->w2, not h2c->w1. These will cause h2c->w1 wrong overlap by w2 and w2 not initialized.

Fixes c73607b3a8ef ("wifi: rtw89: fw: add CMAC H2C command to initialize default value for RTL8922D")

1 patch(es) applied to rtw-next branch of rtw.git, thanks.

e13cd023a4cd wifi: rtw89: fw: correct preload field of w2 in rtw89_fw_h2c_default_cmac_tbl_be()

---
https://github.com/pkshih/rtw.git