From: Ho Jie Feng <hjf3108@gmail.com>
To: Ping-Ke Shih <pkshih@realtek.com>
Cc: linux-wireless@vger.kernel.org,
Bitterblue Smith <rtl8821cerfe2@gmail.com>,
Luka Gejak <luka.gejak@linux.dev>,
Ho Jie Feng <hjf3108@gmail.com>
Subject: [PATCH rtw-next v7 3/7] wifi: rtw88: correctly expose beamformee capabilities
Date: Thu, 3 Dec 2026 01:24:55 +0800 [thread overview]
Message-ID: <20261202172503.1699801-4-hjf3108@gmail.com> (raw)
In-Reply-To: <20261202172503.1699801-1-hjf3108@gmail.com>
Both SU and MU beamformee flags were set on every VHT chip,
regardless of the chip limits bfer_su_max_num and bfer_mu_max_num.
This is wrong when the chip does not support SU or MU beamformee.
rtw_bf_assoc() also checks these flags. With an AP that is a MU
beamformer, the MU flag makes it take the MU branch and return at
bfer_mu_max_num, so a chip without MU support is never set up as a
SU beamformee either.
Make MU and SU capability flags each depend on the chip declared
maximum instead of setting both flags together.
Signed-off-by: Ho Jie Feng <hjf3108@gmail.com>
Reviewed-by: Luka Gejak <luka.gejak@linux.dev>
Acked-by: Ping-Ke Shih <pkshih@realtek.com>
---
drivers/net/wireless/realtek/rtw88/main.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/drivers/net/wireless/realtek/rtw88/main.c b/drivers/net/wireless/realtek/rtw88/main.c
index e4d975c2ad..d6df7ede3e 100644
--- a/drivers/net/wireless/realtek/rtw88/main.c
+++ b/drivers/net/wireless/realtek/rtw88/main.c
@@ -1614,6 +1614,7 @@ static void rtw_init_ht_cap(struct rtw_dev *rtwdev,
static void rtw_init_vht_cap(struct rtw_dev *rtwdev,
struct ieee80211_sta_vht_cap *vht_cap)
{
+ const struct rtw_chip_info *chip = rtwdev->chip;
struct rtw_efuse *efuse = &rtwdev->efuse;
u16 mcs_map = 0;
__le16 highest;
@@ -1632,10 +1633,13 @@ static void rtw_init_vht_cap(struct rtw_dev *rtwdev,
0;
if (rtwdev->hal.rf_path_num > 1)
vht_cap->cap |= IEEE80211_VHT_CAP_TXSTBC;
- vht_cap->cap |= IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE |
- IEEE80211_VHT_CAP_SU_BEAMFORMEE_CAPABLE;
- vht_cap->cap |= (rtwdev->hal.bfee_sts_cap <<
- IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT);
+ if (chip->bfer_su_max_num) {
+ vht_cap->cap |= IEEE80211_VHT_CAP_SU_BEAMFORMEE_CAPABLE;
+ vht_cap->cap |= rtwdev->hal.bfee_sts_cap <<
+ IEEE80211_VHT_CAP_BEAMFORMEE_STS_SHIFT;
+ }
+ if (chip->bfer_mu_max_num)
+ vht_cap->cap |= IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE;
if (rtw_chip_has_rx_ldpc(rtwdev))
vht_cap->cap |= IEEE80211_VHT_CAP_RXLDPC;
--
2.53.0
next prev parent reply other threads:[~2026-12-02 17:25 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 17:24 [PATCH rtw-next v7 0/7] wifi: rtw88: extend 88xxA support Ho Jie Feng
2026-12-02 17:24 ` [PATCH rtw-next v7 1/7] wifi: rtw88: 8812a, 8814a: enable STBC for HT transmissions Ho Jie Feng
2026-12-02 17:24 ` [PATCH rtw-next v7 2/7] wifi: rtw88: skip the dynamic CSI rate without a cfg_csi_rate op Ho Jie Feng
2026-12-02 17:24 ` Ho Jie Feng [this message]
2026-12-02 17:24 ` [PATCH rtw-next v7 4/7] wifi: rtw88: 88xxa: receive VHT SU beamformed transmissions Ho Jie Feng
2026-12-02 17:24 ` [PATCH rtw-next v7 5/7] wifi: rtw88: prepare frequency-offset correction for more chips Ho Jie Feng
2026-12-02 17:24 ` [PATCH rtw-next v7 6/7] wifi: rtw88: 88xxa: correct carrier-frequency offset Ho Jie Feng
2026-12-02 17:24 ` [PATCH rtw-next v7 7/7] wifi: rtw88: 8812a, 8821a: respect peer A-MPDU size limits Ho Jie Feng
2026-12-03 0:50 ` 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=20261202172503.1699801-4-hjf3108@gmail.com \
--to=hjf3108@gmail.com \
--cc=linux-wireless@vger.kernel.org \
--cc=luka.gejak@linux.dev \
--cc=pkshih@realtek.com \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.