brcmfmac: Fix exception handling.
authorHante Meuleman <meuleman@broadcom.com>
Fri, 18 Sep 2015 20:08:04 +0000 (22:08 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 29 Sep 2015 07:55:44 +0000 (10:55 +0300)
In some exception situations the ifp->vif was not properly assigned
which could result in crash.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/brcm80211/brcmfmac/cfg80211.c

index 600098dd197cba0059de2030c18a48ddaf5b48a0..da24bf0d43f6d2fb564cae9a3441d970decefc02 100644 (file)
@@ -6332,6 +6332,7 @@ wiphy_unreg_out:
 priv_out:
        wl_deinit_priv(cfg);
        brcmf_free_vif(vif);
+       ifp->vif = NULL;
 wiphy_out:
        brcmf_free_wiphy(wiphy);
        return NULL;