* [PATCH v2] rtw89: fix HE PHY bandwidth capability
@ 2022-03-01 0:31 Ping-Ke Shih
2022-03-01 0:45 ` Pkshih
0 siblings, 1 reply; 2+ messages in thread
From: Ping-Ke Shih @ 2022-03-01 0:31 UTC (permalink / raw)
To: kvalo; +Cc: linux-wireless, johannes.berg
From: Johannes Berg <johannes.berg@intel.com>
Bit 0 is reserved on 5/6 GHz and bit 1 is reserved on 2.4 GHz,
so the driver should only set the non-reserved bits according
to band.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
---
v2: do rebase onto the latest tree
---
drivers/net/wireless/realtek/rtw89/core.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/drivers/net/wireless/realtek/rtw89/core.c b/drivers/net/wireless/realtek/rtw89/core.c
index a0086b14550a8..fc4c67ab480e1 100644
--- a/drivers/net/wireless/realtek/rtw89/core.c
+++ b/drivers/net/wireless/realtek/rtw89/core.c
@@ -2333,8 +2333,12 @@ static void rtw89_init_he_cap(struct rtw89_dev *rtwdev,
IEEE80211_HE_MAC_CAP4_AMSDU_IN_AMPDU;
if (i == NL80211_IFTYPE_STATION)
mac_cap_info[5] = IEEE80211_HE_MAC_CAP5_HT_VHT_TRIG_FRAME_RX;
- phy_cap_info[0] = IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_IN_2G |
- IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_80MHZ_IN_5G;
+ if (band == NL80211_BAND_2GHZ)
+ phy_cap_info[0] =
+ IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_IN_2G;
+ else
+ phy_cap_info[0] =
+ IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_40MHZ_80MHZ_IN_5G;
if (chip->support_bw160)
phy_cap_info[0] |= IEEE80211_HE_PHY_CAP0_CHANNEL_WIDTH_SET_160MHZ_IN_5G;
phy_cap_info[1] = IEEE80211_HE_PHY_CAP1_DEVICE_CLASS_A |
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* RE: [PATCH v2] rtw89: fix HE PHY bandwidth capability
2022-03-01 0:31 [PATCH v2] rtw89: fix HE PHY bandwidth capability Ping-Ke Shih
@ 2022-03-01 0:45 ` Pkshih
0 siblings, 0 replies; 2+ messages in thread
From: Pkshih @ 2022-03-01 0:45 UTC (permalink / raw)
To: Pkshih, kvalo@kernel.org
Cc: linux-wireless@vger.kernel.org, johannes.berg@intel.com
> -----Original Message-----
> From: Ping-Ke Shih <pkshih@realtek.com>
> Sent: Tuesday, March 1, 2022 8:31 AM
> To: kvalo@kernel.org
> Cc: linux-wireless@vger.kernel.org; johannes.berg@intel.com
> Subject: [PATCH v2] rtw89: fix HE PHY bandwidth capability
>
> From: Johannes Berg <johannes.berg@intel.com>
>
> Bit 0 is reserved on 5/6 GHz and bit 1 is reserved on 2.4 GHz,
> so the driver should only set the non-reserved bits according
> to band.
>
> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
> Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
> ---
> v2: do rebase onto the latest tree
I have sent v3. Please ignore v2.
--
Ping-Ke
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-03-01 0:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-03-01 0:31 [PATCH v2] rtw89: fix HE PHY bandwidth capability Ping-Ke Shih
2022-03-01 0:45 ` Pkshih
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).