Add the missing unlock before return from function brcmf_notify_vif_event()
in the error handling case.
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
        switch (ifevent->action) {
        case BRCMF_E_IF_ADD:
                /* waiting process may have timed out */
-               if (!cfg->vif_event.vif)
+               if (!cfg->vif_event.vif) {
+                       mutex_unlock(&event->vif_event_lock);
                        return -EBADF;
+               }
 
                ifp->vif = vif;
                vif->ifp = ifp;