Commit 5290cd68 authored by Jes Sorensen's avatar Jes Sorensen Committed by Greg Kroah-Hartman

staging: rtl8723au: rtw_createbss_cmd23a_callback(): Relax holding of pmlmepriv->lock

We only really need to hold pmlmepriv->lock while calling
rtw_indicate_connect23a(). rtw_get_stainfo23a() and
rtw_alloc_stainfo23a() rely on pstapriv->sta_hash_lock and the non
WIFI_AP_STATE path relies on pmlmepvi->scanned_queue.lock, except we
need to used clr_fwstate() instead of _clr_fwstate_().
Signed-off-by: default avatarJes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5d8b411b
......@@ -1505,8 +1505,6 @@ void rtw_createbss_cmd23a_callback(struct rtw_adapter *padapter,
del_timer_sync(&pmlmepriv->assoc_timer);
spin_lock_bh(&pmlmepriv->lock);
if (check_fwstate(pmlmepriv, WIFI_AP_STATE)) {
psta = rtw_get_stainfo23a(&padapter->stapriv,
pnetwork->MacAddress);
......@@ -1521,7 +1519,9 @@ void rtw_createbss_cmd23a_callback(struct rtw_adapter *padapter,
}
}
spin_lock_bh(&pmlmepriv->lock);
rtw_indicate_connect23a(padapter);
spin_unlock_bh(&pmlmepriv->lock);
} else {
pwlan = rtw_alloc_network(pmlmepriv);
spin_lock_bh(&pmlmepriv->scanned_queue.lock);
......@@ -1554,7 +1554,7 @@ void rtw_createbss_cmd23a_callback(struct rtw_adapter *padapter,
/* reset DSConfig */
_clr_fwstate_(pmlmepriv, _FW_UNDER_LINKING);
clr_fwstate(pmlmepriv, _FW_UNDER_LINKING);
spin_unlock_bh(&pmlmepriv->scanned_queue.lock);
/* we will set _FW_LINKED when there is one more sat to
......@@ -1563,8 +1563,6 @@ void rtw_createbss_cmd23a_callback(struct rtw_adapter *padapter,
createbss_cmd_fail:
spin_unlock_bh(&pmlmepriv->lock);
rtw_free_cmd_obj23a(pcmd);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment