* [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures
@ 2020-05-12 10:03 Chi-Hsien Lin
2020-05-12 10:42 ` Kalle Valo
2020-05-13 15:48 ` Kalle Valo
0 siblings, 2 replies; 4+ messages in thread
From: Chi-Hsien Lin @ 2020-05-12 10:03 UTC (permalink / raw)
To: linux-wireless
Cc: brcm80211-dev-list, brcm80211-dev-list, Arend van Spriel,
Franky Lin, Hante Meuleman, Wright Feng, Kalle Valo,
Chung-Hsien Hsu, Chi-Hsien Lin
From: Chung-Hsien Hsu <stanley.hsu@cypress.com>
An incorrect value of use_fwsup is set for 4-way handshake offload for
WPA//WPA2-PSK, caused by commit 3b1e0a7bdfee ("brcmfmac: add support for
SAE authentication offload"). It results in missing bit
BRCMF_VIF_STATUS_EAP_SUCCESS set in brcmf_is_linkup() and causes the
failure. This patch correct the value for the case.
Also setting bit BRCMF_VIF_STATUS_EAP_SUCCESS for SAE offload case in
brcmf_is_linkup() to fix SAE offload failure.
Fixes: 3b1e0a7bdfee ("brcmfmac: add support for SAE authentication
offload")
Signed-off-by: Chung-Hsien Hsu <stanley.hsu@cypress.com>
Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
---
drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
index 4bd69d85fab9..bc6a1c48affa 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
@@ -1819,6 +1819,10 @@ brcmf_set_key_mgmt(struct net_device *ndev, struct cfg80211_connect_params *sme)
switch (sme->crypto.akm_suites[0]) {
case WLAN_AKM_SUITE_SAE:
val = WPA3_AUTH_SAE_PSK;
+ if (sme->crypto.sae_pwd) {
+ brcmf_dbg(INFO, "using SAE offload\n");
+ profile->use_fwsup = BRCMF_PROFILE_FWSUP_SAE;
+ }
break;
default:
bphy_err(drvr, "invalid cipher group (%d)\n",
@@ -2104,11 +2108,6 @@ brcmf_cfg80211_connect(struct wiphy *wiphy, struct net_device *ndev,
goto done;
}
- if (sme->crypto.sae_pwd) {
- brcmf_dbg(INFO, "using SAE offload\n");
- profile->use_fwsup = BRCMF_PROFILE_FWSUP_SAE;
- }
-
if (sme->crypto.psk &&
profile->use_fwsup != BRCMF_PROFILE_FWSUP_SAE) {
if (WARN_ON(profile->use_fwsup != BRCMF_PROFILE_FWSUP_NONE)) {
@@ -5505,7 +5504,8 @@ static bool brcmf_is_linkup(struct brcmf_cfg80211_vif *vif,
u32 event = e->event_code;
u32 status = e->status;
- if (vif->profile.use_fwsup == BRCMF_PROFILE_FWSUP_PSK &&
+ if ((vif->profile.use_fwsup == BRCMF_PROFILE_FWSUP_PSK ||
+ vif->profile.use_fwsup == BRCMF_PROFILE_FWSUP_SAE) &&
event == BRCMF_E_PSK_SUP &&
status == BRCMF_E_STATUS_FWSUP_COMPLETED)
set_bit(BRCMF_VIF_STATUS_EAP_SUCCESS, &vif->sme_state);
--
2.1.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures
2020-05-12 10:03 [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures Chi-Hsien Lin
@ 2020-05-12 10:42 ` Kalle Valo
2020-05-12 10:50 ` Chi-Hsien Lin
2020-05-13 15:48 ` Kalle Valo
1 sibling, 1 reply; 4+ messages in thread
From: Kalle Valo @ 2020-05-12 10:42 UTC (permalink / raw)
To: Chi-Hsien Lin
Cc: linux-wireless, brcm80211-dev-list, brcm80211-dev-list,
Arend van Spriel, Franky Lin, Hante Meuleman, Wright Feng,
Chung-Hsien Hsu
Chi-Hsien Lin <chi-hsien.lin@cypress.com> writes:
> From: Chung-Hsien Hsu <stanley.hsu@cypress.com>
>
> An incorrect value of use_fwsup is set for 4-way handshake offload for
> WPA//WPA2-PSK, caused by commit 3b1e0a7bdfee ("brcmfmac: add support for
> SAE authentication offload"). It results in missing bit
> BRCMF_VIF_STATUS_EAP_SUCCESS set in brcmf_is_linkup() and causes the
> failure. This patch correct the value for the case.
>
> Also setting bit BRCMF_VIF_STATUS_EAP_SUCCESS for SAE offload case in
> brcmf_is_linkup() to fix SAE offload failure.
>
> Fixes: 3b1e0a7bdfee ("brcmfmac: add support for SAE authentication
> offload")
Fixes line needs to be in one line. I can fix that during commit, no
need to resend because of this.
--
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures
2020-05-12 10:42 ` Kalle Valo
@ 2020-05-12 10:50 ` Chi-Hsien Lin
0 siblings, 0 replies; 4+ messages in thread
From: Chi-Hsien Lin @ 2020-05-12 10:50 UTC (permalink / raw)
To: Kalle Valo
Cc: linux-wireless, brcm80211-dev-list, brcm80211-dev-list,
Arend van Spriel, Franky Lin, Hante Meuleman, Wright Feng,
Chung-Hsien Hsu
On 05/12/2020 6:42, Kalle Valo wrote:
> Chi-Hsien Lin <chi-hsien.lin@cypress.com> writes:
>
>> From: Chung-Hsien Hsu <stanley.hsu@cypress.com>
>>
>> An incorrect value of use_fwsup is set for 4-way handshake offload for
>> WPA//WPA2-PSK, caused by commit 3b1e0a7bdfee ("brcmfmac: add support for
>> SAE authentication offload"). It results in missing bit
>> BRCMF_VIF_STATUS_EAP_SUCCESS set in brcmf_is_linkup() and causes the
>> failure. This patch correct the value for the case.
>>
>> Also setting bit BRCMF_VIF_STATUS_EAP_SUCCESS for SAE offload case in
>> brcmf_is_linkup() to fix SAE offload failure.
>>
>> Fixes: 3b1e0a7bdfee ("brcmfmac: add support for SAE authentication
>> offload")
>
> Fixes line needs to be in one line. I can fix that during commit, no
> need to resend because of this.
Thanks a lot for fixing it. We'll use one line going forward.
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures
2020-05-12 10:03 [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures Chi-Hsien Lin
2020-05-12 10:42 ` Kalle Valo
@ 2020-05-13 15:48 ` Kalle Valo
1 sibling, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2020-05-13 15:48 UTC (permalink / raw)
To: Chi-Hsien Lin
Cc: linux-wireless, brcm80211-dev-list, brcm80211-dev-list,
Arend van Spriel, Franky Lin, Hante Meuleman, Wright Feng,
Chung-Hsien Hsu, Chi-Hsien Lin
Chi-Hsien Lin <chi-hsien.lin@cypress.com> wrote:
> From: Chung-Hsien Hsu <stanley.hsu@cypress.com>
>
> An incorrect value of use_fwsup is set for 4-way handshake offload for
> WPA//WPA2-PSK, caused by commit 3b1e0a7bdfee ("brcmfmac: add support for
> SAE authentication offload"). It results in missing bit
> BRCMF_VIF_STATUS_EAP_SUCCESS set in brcmf_is_linkup() and causes the
> failure. This patch correct the value for the case.
>
> Also setting bit BRCMF_VIF_STATUS_EAP_SUCCESS for SAE offload case in
> brcmf_is_linkup() to fix SAE offload failure.
>
> Fixes: 3b1e0a7bdfee ("brcmfmac: add support for SAE authentication offload")
> Signed-off-by: Chung-Hsien Hsu <stanley.hsu@cypress.com>
> Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
Patch applied to wireless-drivers-next.git, thanks.
b2fe11f07773 brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures
--
https://patchwork.kernel.org/patch/11542809/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-05-13 15:48 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-05-12 10:03 [PATCH] brcmfmac: fix WPA/WPA2-PSK 4-way handshake offload and SAE offload failures Chi-Hsien Lin
2020-05-12 10:42 ` Kalle Valo
2020-05-12 10:50 ` Chi-Hsien Lin
2020-05-13 15:48 ` Kalle Valo
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).