Skip to content

Commit

Permalink
brcmfmac: fix error return code in brcmf_cfg80211_connect()
Browse files Browse the repository at this point in the history
[ Upstream commit 37ff144 ]

Fix to return a negative error code from the error handling
case instead of 0, as done elsewhere in this function.

Fixes: 3b1e0a7 ("brcmfmac: add support for SAE authentication offload")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zhang Changzhong <zhangchangzhong@huawei.com>
Reviewed-by: Chi-hsien Lin <chi-hsien.lin@infineon.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/1605248896-16812-1-git-send-email-zhangchangzhong@huawei.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Zhang Changzhong authored and gregkh committed Dec 30, 2020
1 parent 2c9e1e3 commit 174f218
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/net/wireless/broadcom/brcm80211/brcmfmac/cfg80211.c
Expand Up @@ -2137,7 +2137,8 @@ brcmf_cfg80211_connect(struct wiphy *wiphy, struct net_device *ndev,
BRCMF_WSEC_MAX_PSK_LEN);
else if (profile->use_fwsup == BRCMF_PROFILE_FWSUP_SAE) {
/* clean up user-space RSNE */
if (brcmf_fil_iovar_data_set(ifp, "wpaie", NULL, 0)) {
err = brcmf_fil_iovar_data_set(ifp, "wpaie", NULL, 0);
if (err) {
bphy_err(drvr, "failed to clean up user-space RSNE\n");
goto done;
}
Expand Down

0 comments on commit 174f218

Please sign in to comment.