staging: rtl8723au: issue_probersp(): No need to calculate location of IEs, we know...
authorJes Sorensen <Jes.Sorensen@redhat.com>
Sat, 21 Jun 2014 14:50:19 +0000 (16:50 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 21 Jun 2014 20:08:37 +0000 (13:08 -0700)
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723au/core/rtw_mlme_ext.c

index 4f9e5a918bb0717d95ea6f1f4a974872cb6c917b..03ced01ef82b19b927b24090afbc22a797e2c27d 100644 (file)
@@ -2528,7 +2528,6 @@ static void issue_probersp(struct rtw_adapter *padapter, unsigned char *da,
        int ssid_ielen;
        int ssid_ielen_diff;
        u8 buf[MAX_IE_SZ];
-       u8 *ies;
 #endif
        struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
        struct mlme_ext_info *pmlmeinfo = &pmlmeext->mlmext_info;
@@ -2598,12 +2597,10 @@ static void issue_probersp(struct rtw_adapter *padapter, unsigned char *da,
                pattrib->pktlen += cur_network->IELength;
 
                /* retrieve SSID IE from cur_network->Ssid */
-               ies = pmgntframe->buf_addr + TXDESC_OFFSET +
-                       sizeof(struct ieee80211_hdr_3addr);
 
-               ssid_ie = rtw_get_ie23a(ies + _FIXED_IE_LENGTH_, WLAN_EID_SSID,
-                                       &ssid_ielen,
-                                       pframe - ies - _FIXED_IE_LENGTH_);
+               ssid_ie = rtw_get_ie23a(mgmt->u.probe_resp.variable,
+                                       WLAN_EID_SSID, &ssid_ielen,
+                                       pframe - mgmt->u.probe_resp.variable);
 
                ssid_ielen_diff = cur_network->Ssid.ssid_len - ssid_ielen;