rtw89 registers its HE and EHT capabilities for station and AP interfaces only, so mac80211 finds none for a P2P client or a P2P GO. A station that joins a P2P GO is then handled as a station without HE. A GO on 5 GHz sent to an HE phone at HT rates. Let a P2P client use the station capabilities and a P2P GO the AP capabilities. Suggested-by: Zong-Zhe Yang Signed-off-by: Josef Schlehofer --- v2: new patch drivers/net/wireless/realtek/rtw89/core.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/realtek/rtw89/core.c b/drivers/net/wireless/realtek/rtw89/core.c index 2ea4dec5e9e..edd350b8a21 100644 --- a/drivers/net/wireless/realtek/rtw89/core.c +++ b/drivers/net/wireless/realtek/rtw89/core.c @@ -6461,9 +6461,16 @@ static int rtw89_init_he_eht_cap(struct rtw89_dev *rtwdev, return -ENOMEM; for (iftype = 0; iftype < NUM_NL80211_IFTYPES; iftype++) { + u16 types_mask; + switch (iftype) { case NL80211_IFTYPE_STATION: + types_mask = BIT(NL80211_IFTYPE_STATION) | + BIT(NL80211_IFTYPE_P2P_CLIENT); + break; case NL80211_IFTYPE_AP: + types_mask = BIT(NL80211_IFTYPE_AP) | + BIT(NL80211_IFTYPE_P2P_GO); break; default: continue; @@ -6474,7 +6481,7 @@ static int rtw89_init_he_eht_cap(struct rtw89_dev *rtwdev, break; } - iftype_data[idx].types_mask = BIT(iftype); + iftype_data[idx].types_mask = types_mask; rtw89_init_he_cap(rtwdev, band, iftype, &iftype_data[idx]); rtw89_init_eht_cap(rtwdev, band, iftype, &iftype_data[idx]); -- 2.54.0 (Apple Git-157)