Message ID | 20220222195524.1e3cc6f7e4c3.I72ea8a9cad5eff93bcb3a0912727d03605ddb6e6@changeid (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Kalle Valo |
Headers | show |
Series | rtw89: fix HE PHY bandwidth capability | expand |
> -----Original Message----- > From: Johannes Berg <johannes@sipsolutions.net> > Sent: Wednesday, February 23, 2022 2:55 AM > To: linux-wireless@vger.kernel.org > Cc: Pkshih <pkshih@realtek.com>; Johannes Berg <johannes.berg@intel.com> > Subject: [PATCH] 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> Acked-by: Ping-Ke Shih <pkshih@realtek.com> Thanks for the fix. > --- > 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 a0737eea9f81..1f0bea9a148c 100644 > --- a/drivers/net/wireless/realtek/rtw89/core.c > +++ b/drivers/net/wireless/realtek/rtw89/core.c > @@ -2087,8 +2087,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; > phy_cap_info[1] = IEEE80211_HE_PHY_CAP1_DEVICE_CLASS_A | > IEEE80211_HE_PHY_CAP1_LDPC_CODING_IN_PAYLOAD | > IEEE80211_HE_PHY_CAP1_HE_LTF_AND_GI_FOR_HE_PPDUS_0_8US; > -- > 2.35.1
Johannes Berg <johannes@sipsolutions.net> wrote: > 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> > Acked-by: Ping-Ke Shih <pkshih@realtek.com> Failed to apply: Recorded preimage for 'drivers/net/wireless/realtek/rtw89/core.c' error: Failed to merge in the changes. hint: Use 'git am --show-current-patch=diff' to see the failed patch Applying: rtw89: fix HE PHY bandwidth capability Using index info to reconstruct a base tree... M drivers/net/wireless/realtek/rtw89/core.c Falling back to patching base and 3-way merge... Auto-merging drivers/net/wireless/realtek/rtw89/core.c CONFLICT (content): Merge conflict in drivers/net/wireless/realtek/rtw89/core.c Patch failed at 0001 rtw89: fix HE PHY bandwidth capability Patch set to Changes Requested.
diff --git a/drivers/net/wireless/realtek/rtw89/core.c b/drivers/net/wireless/realtek/rtw89/core.c index a0737eea9f81..1f0bea9a148c 100644 --- a/drivers/net/wireless/realtek/rtw89/core.c +++ b/drivers/net/wireless/realtek/rtw89/core.c @@ -2087,8 +2087,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; phy_cap_info[1] = IEEE80211_HE_PHY_CAP1_DEVICE_CLASS_A | IEEE80211_HE_PHY_CAP1_LDPC_CODING_IN_PAYLOAD | IEEE80211_HE_PHY_CAP1_HE_LTF_AND_GI_FOR_HE_PPDUS_0_8US;