Commit f54ded55 authored by Martin Kaiser's avatar Martin Kaiser Committed by Greg Kroah-Hartman

staging: r8188eu: get reason code from mgmt struct

Read the deauth reson code from the newly added mgmt structure instead of
calculating the offset ourselves.
Signed-off-by: default avatarMartin Kaiser <martin@kaiser.cx>
Tested-by: Philipp Hortmann <philipp.g.hortmann@gmail.com> # Edimax N150
Acked-by: default avatarPavel Skripkin <paskripkin@gmail.com>
Link: https://lore.kernel.org/r/20221015152440.232281-3-martin@kaiser.cxSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c5997186
...@@ -1473,7 +1473,7 @@ unsigned int OnDeAuth(struct adapter *padapter, struct recv_frame *precv_frame) ...@@ -1473,7 +1473,7 @@ unsigned int OnDeAuth(struct adapter *padapter, struct recv_frame *precv_frame)
_set_timer(&pwdinfo->reset_ch_sitesurvey, 10); _set_timer(&pwdinfo->reset_ch_sitesurvey, 10);
} }
reason = le16_to_cpu(*(__le16 *)(pframe + WLAN_HDR_A3_LEN)); reason = le16_to_cpu(mgmt->u.disassoc.reason_code);
if (check_fwstate(pmlmepriv, WIFI_AP_STATE)) { if (check_fwstate(pmlmepriv, WIFI_AP_STATE)) {
struct sta_info *psta; struct sta_info *psta;
......
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