FAILED: patch "[PATCH] wifi: brcmfmac: cfg80211: Report port_authorized for 4-way HS offload" failed to apply to 6.12-stable tree
Subsystems (2)
Sasha Levin
maintainerThe patch below does not apply to the 6.12-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
git checkout FETCH_HEAD
git cherry-pick -x 6fff9de5c5b425817588eeed42bd56d665751c13
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '[email protected]' --subject-prefix 'PATCH 6.12.y' 'HEAD^..'
Thanks,
Sasha
------------------ original commit in Linus's tree ------------------
From 6fff9de5c5b425817588eeed42bd56d665751c13 Mon Sep 17 00:00:00 2001
From: Janne Grunau <[email protected]>
Date: Tue, 15 Sep 2026 21:17:38 +0200
Subject: [PATCH] wifi: brcmfmac: cfg80211: Report port_authorized for 4-way HS
offload
Since commit 416386060 ("Mark authorization completed on driver indication during 4-way HS offload") [0] wpa_supplicant expects NL80211_CMD_PORT_AUTHORIZED to complete the authentication when the driver supports 4-way handshake offload.
This was apparently never tested with the upstream brcmfmac driver as it does not report this. This broke authentication on Apple silicon devices (BRCM4378, BRMC4387, BRMC4388) and other devices when wpa_supplicant 2.11 was released [1]. This was initially dealt with by reverting the commit in Fedora [2] and other Linux distributions.
Instead of carrying the revert over to wpa_supplicant 2.12 add the expected NL80211_CMD_PORT_AUTHORIZED when the connection is established.
The "Fixes:" tag is not fully accurate as this has only became an issue after userspace changes years after the change. Since the change is expected to be required in all active stable branches for wpa_supplicant 2.11 / 2.12 compatibility it is helpful even though BRCMF_PROFILE_FWSUP_SAE did not exists then.
--- .../broadcom/brcm80211/brcmfmac/cfg80211.c | 20 +++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c +16 -4
@@ -6588,6 +6588,21 @@ brcmf_bss_roaming_done(struct brcmf_cfg80211_info *cfg,return err; } +static bool +brcmf_fwsup_is_authorized (struct brcmf_cfg80211_profile *profile, +struct cfg80211_connect_resp_params *conn_params) +{ +if ((profile->use_fwsup ==BRCMF_PROFILE_FWSUP_1X || + profile->use_fwsup ==BRCMF_PROFILE_FWSUP_ROAM ) && +brcmf_has_pmkid (conn_params->req_ie, conn_params->req_ie_len)) +return true; +if (profile->use_fwsup ==BRCMF_PROFILE_FWSUP_SAE || + profile->use_fwsup ==BRCMF_PROFILE_FWSUP_PSK ) +return true; + +return false; +} + static s32 brcmf_bss_connect_done(struct brcmf_cfg80211_info *cfg, struct net_device *ndev, const struct brcmf_event_msg *e,
@@ -6625,10 +6640,7 @@ brcmf_bss_connect_done(struct brcmf_cfg80211_info *cfg, conn_params.resp_ie = conn_info->resp_ie; conn_params.resp_ie_len = conn_info->resp_ie_len; authorized = completed && - (profile->use_fwsup ==BRCMF_PROFILE_FWSUP_1X || - profile->use_fwsup ==BRCMF_PROFILE_FWSUP_ROAM ) && -brcmf_has_pmkid (conn_params.req_ie, - conn_params.req_ie_len); +brcmf_fwsup_is_authorized (profile, &conn_params);cfg80211_connect_done (ndev, &conn_params,GFP_KERNEL );if (authorized) cfg80211_port_authorized(ndev, profile->bssid, NULL, 0,
Signature · 1 line
2.53.0
Sasha Levin
maintainerPATCH 1/2 wifi: brcmfmac: detect firmware FBT and OKC support
From: Carella Chen <[email protected]>
[ Upstream commit b1590c5eef0fadb5bc33689f9d98ce58b91154e7 ]
Some firmware advertises Fast BSS Transition and Opportunistic Key Caching support through the firmware capability string. Track those capabilities so later roaming offload handling can be enabled only when firmware reports support.
The existing feature table predates external SAE authentication support. Add the FBT and OKC entries without introducing the unrelated SAE_EXT feature, and preserve the existing SAE capability matching.
Stable-dep-of: 6fff9de5c5b4 ("wifi: brcmfmac: cfg80211: Report port_authorized for 4-way HS offload")
--- drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.c | 2 ++ drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.h | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.c +2 -0
@@ -44,6 +44,8 @@ static const struct brcmf_feat_fwcap brcmf_fwcap_map[] = { { BRCMF_FEAT_DOT11H, "802.11h" }, { BRCMF_FEAT_SAE, "sae" }, { BRCMF_FEAT_FWAUTH, "idauth" }, + { BRCMF_FEAT_FBT, "fbt " }, + { BRCMF_FEAT_OKC, "okc" }, };#ifdef DEBUG
drivers/net/wireless/broadcom/brcm80211/brcmfmac/feature.h +3 -1
@@ -57,7 +57,9 @@ BRCMF_FEAT_DEF(DUMP_OBSS) \ BRCMF_FEAT_DEF(SCAN_V2) \ BRCMF_FEAT_DEF(PMKID_V2) \ - BRCMF_FEAT_DEF(PMKID_V3) + BRCMF_FEAT_DEF(PMKID_V3) \ + BRCMF_FEAT_DEF(FBT) \ + BRCMF_FEAT_DEF(OKC)/* * Quirks:
Signature · 1 line
2.53.0
Sasha Levin
maintainerPATCH 2/2 wifi: brcmfmac: cfg80211: Report port_authorized for 4-way HS offload
From: Janne Grunau <[email protected]>
[ Upstream commit 6fff9de5c5b425817588eeed42bd56d665751c13 ]
Since commit 416386060 ("Mark authorization completed on driver indication during 4-way HS offload") [0] wpa_supplicant expects NL80211_CMD_PORT_AUTHORIZED to complete the authentication when the driver supports 4-way handshake offload.
This was apparently never tested with the upstream brcmfmac driver as it does not report this. This broke authentication on Apple silicon devices (BRCM4378, BRMC4387, BRMC4388) and other devices when wpa_supplicant 2.11 was released [1]. This was initially dealt with by reverting the commit in Fedora [2] and other Linux distributions.
Instead of carrying the revert over to wpa_supplicant 2.12 add the expected NL80211_CMD_PORT_AUTHORIZED when the connection is established.
The "Fixes:" tag is not fully accurate as this has only became an issue after userspace changes years after the change. Since the change is expected to be required in all active stable branches for wpa_supplicant 2.11 / 2.12 compatibility it is helpful even though BRCMF_PROFILE_FWSUP_SAE did not exists then.
--- .../net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 7 +++++++ 1 file changed, 7 insertions(+)
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c +7 -0
@@ -6424,6 +6424,7 @@ brcmf_bss_connect_done(struct brcmf_cfg80211_info *cfg,struct brcmf_cfg80211_profile *profile = &ifp->vif->profile;struct brcmf_cfg80211_connect_info *conn_info =cfg_to_conn (cfg);struct cfg80211_connect_resp_params conn_params; +bool authorized;brcmf_dbg (TRACE ,"Enter\n" );
@@ -6448,7 +6449,13 @@ brcmf_bss_connect_done(struct brcmf_cfg80211_info *cfg, conn_params.req_ie_len = conn_info->req_ie_len; conn_params.resp_ie = conn_info->resp_ie; conn_params.resp_ie_len = conn_info->resp_ie_len; + authorized = completed && + (profile->use_fwsup ==BRCMF_PROFILE_FWSUP_SAE || + profile->use_fwsup ==BRCMF_PROFILE_FWSUP_PSK );cfg80211_connect_done (ndev, &conn_params,GFP_KERNEL ); +if (authorized) +cfg80211_port_authorized (ndev, profile->bssid,NULL ,0 , +GFP_KERNEL );brcmf_dbg (CONN ,"Report connect result - connection %s\n" , completed ?"succeeded" :"failed" ); }
Signature · 1 line
2.53.0