Remove wrapper for memset()

Link: 545d963a9e (diff-16d649c4743131c1aae5f812af5596dae6423bb63eaaf2990b8c89c9a681a913)
This commit is contained in:
Carlos Garcés
2021-10-11 12:07:17 +02:00
parent 76f68bbfcf
commit cf246719f1
58 changed files with 621 additions and 642 deletions

View File

@@ -112,7 +112,7 @@ static void indicate_wx_custom_event(_adapter *padapter, char *msg)
_rtw_memcpy(buff, msg, strlen(msg));
_rtw_memset(&wrqu, 0, sizeof(wrqu));
memset(&wrqu, 0, sizeof(wrqu));
wrqu.data.length = strlen(msg);
RTW_INFO("%s %s\n", __FUNCTION__, buff);
@@ -135,13 +135,13 @@ static void request_wps_pbc_event(_adapter *padapter)
if (!buff)
return;
_rtw_memset(buff, 0, IW_CUSTOM_MAX);
memset(buff, 0, IW_CUSTOM_MAX);
p = buff;
p += sprintf(p, "WPS_PBC_START.request=TRUE");
_rtw_memset(&wrqu, 0, sizeof(wrqu));
memset(&wrqu, 0, sizeof(wrqu));
wrqu.data.length = p - buff;
@@ -186,7 +186,7 @@ void indicate_wx_scan_complete_event(_adapter *padapter)
{
union iwreq_data wrqu;
_rtw_memset(&wrqu, 0, sizeof(union iwreq_data));
memset(&wrqu, 0, sizeof(union iwreq_data));
/* RTW_INFO("+rtw_indicate_wx_scan_complete_event\n"); */
#ifndef CONFIG_IOCTL_CFG80211
@@ -203,7 +203,7 @@ void rtw_indicate_wx_assoc_event(_adapter *padapter)
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
WLAN_BSSID_EX *pnetwork = (WLAN_BSSID_EX *)(&(pmlmeinfo->network));
_rtw_memset(&wrqu, 0, sizeof(union iwreq_data));
memset(&wrqu, 0, sizeof(union iwreq_data));
wrqu.ap_addr.sa_family = ARPHRD_ETHER;
@@ -222,10 +222,10 @@ void rtw_indicate_wx_disassoc_event(_adapter *padapter)
{
union iwreq_data wrqu;
_rtw_memset(&wrqu, 0, sizeof(union iwreq_data));
memset(&wrqu, 0, sizeof(union iwreq_data));
wrqu.ap_addr.sa_family = ARPHRD_ETHER;
_rtw_memset(wrqu.ap_addr.sa_data, 0, ETH_ALEN);
memset(wrqu.ap_addr.sa_data, 0, ETH_ALEN);
#ifndef CONFIG_IOCTL_CFG80211
RTW_PRINT("indicate disassoc\n");
@@ -580,7 +580,7 @@ static inline char *iwe_stream_wpa_wpa2_process(_adapter *padapter,
if (wpa_len > 0) {
_rtw_memset(pbuf, 0, buf_size);
memset(pbuf, 0, buf_size);
p += sprintf(p, "wpa_ie=");
for (i = 0; i < wpa_len; i++)
p += sprintf(p, "%02x", wpa_ie[i]);
@@ -593,28 +593,28 @@ static inline char *iwe_stream_wpa_wpa2_process(_adapter *padapter,
printk("-----------------Len %d----------------\n", wpa_len);
}
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVCUSTOM;
iwe->u.data.length = strlen(pbuf);
start = iwe_stream_add_point(info, start, stop, iwe, pbuf);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVGENIE;
iwe->u.data.length = wpa_len;
start = iwe_stream_add_point(info, start, stop, iwe, wpa_ie);
}
if (rsn_len > 0) {
_rtw_memset(pbuf, 0, buf_size);
memset(pbuf, 0, buf_size);
p += sprintf(p, "rsn_ie=");
for (i = 0; i < rsn_len; i++)
p += sprintf(p, "%02x", rsn_ie[i]);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVCUSTOM;
iwe->u.data.length = strlen(pbuf);
start = iwe_stream_add_point(info, start, stop, iwe, pbuf);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVGENIE;
iwe->u.data.length = rsn_len;
start = iwe_stream_add_point(info, start, stop, iwe, rsn_ie);
@@ -681,17 +681,17 @@ static inline char *iwe_stream_wapi_process(_adapter *padapter,
if (wapi_len > 0) {
p = buf_wapi;
/* _rtw_memset(buf_wapi, 0, MAX_WAPI_IE_LEN*2); */
/* memset(buf_wapi, 0, MAX_WAPI_IE_LEN*2); */
p += sprintf(p, "wapi_ie=");
for (i = 0; i < wapi_len; i++)
p += sprintf(p, "%02x", wapi_ie[i]);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVCUSTOM;
iwe->u.data.length = strlen(buf_wapi);
start = iwe_stream_add_point(info, start, stop, iwe, buf_wapi);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVGENIE;
iwe->u.data.length = wapi_len;
start = iwe_stream_add_point(info, start, stop, iwe, wapi_ie);
@@ -774,7 +774,7 @@ static inline char *iwe_stream_net_rsv_process(_adapter *padapter,
pos = pnetwork->network.Reserved;
p += sprintf(p, "fm=%02X%02X", pos[1], pos[0]);
_rtw_memset(iwe, 0, sizeof(*iwe));
memset(iwe, 0, sizeof(*iwe));
iwe->cmd = IWEVCUSTOM;
iwe->u.data.length = strlen(buf);
start = iwe_stream_add_point(info, start, stop, iwe, buf);
@@ -787,7 +787,7 @@ static char *translate_scan(_adapter *padapter,
{
struct iw_event iwe;
u16 cap = 0;
_rtw_memset(&iwe, 0, sizeof(iwe));
memset(&iwe, 0, sizeof(iwe));
if (_FALSE == search_p2p_wfd_ie(padapter, info, pnetwork, start, stop))
return start;
@@ -1530,14 +1530,14 @@ static int rtw_wx_set_pmkid(struct net_device *dev,
for (j = 0 ; j < NUM_PMKID_CACHE; j++) {
if (_rtw_memcmp(psecuritypriv->PMKIDList[j].Bssid, strIssueBssid, ETH_ALEN) == _TRUE) {
/* BSSID is matched, the same AP => Remove this PMKID information and reset it. */
_rtw_memset(psecuritypriv->PMKIDList[j].Bssid, 0x00, ETH_ALEN);
memset(psecuritypriv->PMKIDList[j].Bssid, 0x00, ETH_ALEN);
psecuritypriv->PMKIDList[j].bUsed = _FALSE;
break;
}
}
} else if (pPMK->cmd == IW_PMKSA_FLUSH) {
RTW_INFO("[rtw_wx_set_pmkid] IW_PMKSA_FLUSH!\n");
_rtw_memset(&psecuritypriv->PMKIDList[0], 0x00, sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE);
memset(&psecuritypriv->PMKIDList[0], 0x00, sizeof(RT_PMKID_LIST) * NUM_PMKID_CACHE);
psecuritypriv->PMKIDIndex = 0;
intReturn = _TRUE;
}
@@ -1584,7 +1584,7 @@ static int rtw_wx_get_range(struct net_device *dev,
wrqu->data.length = sizeof(*range);
_rtw_memset(range, 0, sizeof(*range));
memset(range, 0, sizeof(*range));
/* Let's try to keep this struct in the same order as in
* linux/include/wireless.h
@@ -1853,7 +1853,7 @@ static int rtw_wx_get_wap(struct net_device *dev,
wrqu->ap_addr.sa_family = ARPHRD_ETHER;
_rtw_memset(wrqu->ap_addr.sa_data, 0, ETH_ALEN);
memset(wrqu->ap_addr.sa_data, 0, ETH_ALEN);
@@ -1863,7 +1863,7 @@ static int rtw_wx_get_wap(struct net_device *dev,
_rtw_memcpy(wrqu->ap_addr.sa_data, pcur_bss->MacAddress, ETH_ALEN);
else
_rtw_memset(wrqu->ap_addr.sa_data, 0, ETH_ALEN);
memset(wrqu->ap_addr.sa_data, 0, ETH_ALEN);
return 0;
@@ -2372,7 +2372,7 @@ static int rtw_wx_set_essid(struct net_device *dev,
if (wrqu->essid.length != 33)
RTW_INFO("ssid=%s, len=%d\n", extra, wrqu->essid.length);
_rtw_memset(&ndis_ssid, 0, sizeof(NDIS_802_11_SSID));
memset(&ndis_ssid, 0, sizeof(NDIS_802_11_SSID));
ndis_ssid.SsidLength = len;
_rtw_memcpy(ndis_ssid.Ssid, extra, len);
src_ssid = ndis_ssid.Ssid;
@@ -2709,7 +2709,7 @@ static int rtw_wx_set_enc(struct net_device *dev,
struct pwrctrl_priv *pwrpriv = adapter_to_pwrctl(padapter);
RTW_INFO("+rtw_wx_set_enc, flags=0x%x\n", erq->flags);
_rtw_memset(&wep, 0, sizeof(NDIS_802_11_WEP));
memset(&wep, 0, sizeof(NDIS_802_11_WEP));
key = erq->flags & IW_ENCODE_INDEX;
@@ -3102,10 +3102,10 @@ static int rtw_wx_set_enc_ext(struct net_device *dev,
if (param == NULL)
return -1;
_rtw_memset(param, 0, param_len);
memset(param, 0, param_len);
param->cmd = IEEE_CMD_SET_ENCRYPTION;
_rtw_memset(param->sta_addr, 0xff, ETH_ALEN);
memset(param->sta_addr, 0xff, ETH_ALEN);
switch (pext->alg) {
@@ -4057,7 +4057,7 @@ static int rtw_p2p_profilefound(struct net_device *dev,
if (!rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE)) {
if (extra[0] == '0') {
/* Remove all the profile information of wifidirect_info structure. */
_rtw_memset(&pwdinfo->profileinfo[0], 0x00, sizeof(struct profile_info) * P2P_MAX_PERSISTENT_GROUP_NUM);
memset(&pwdinfo->profileinfo[0], 0x00, sizeof(struct profile_info) * P2P_MAX_PERSISTENT_GROUP_NUM);
pwdinfo->profileindex = 0;
} else {
if (pwdinfo->profileindex >= P2P_MAX_PERSISTENT_GROUP_NUM)
@@ -4092,7 +4092,7 @@ static int rtw_p2p_setDN(struct net_device *dev,
RTW_INFO("[%s] %s %d\n", __FUNCTION__, extra, wrqu->data.length - 1);
_rtw_memset(pwdinfo->device_name, 0x00, WPS_MAX_DEVICE_NAME_LEN);
memset(pwdinfo->device_name, 0x00, WPS_MAX_DEVICE_NAME_LEN);
_rtw_memcpy(pwdinfo->device_name, extra, wrqu->data.length - 1);
pwdinfo->device_name_len = wrqu->data.length - 1;
@@ -4451,7 +4451,7 @@ static int rtw_p2p_get_go_device_address(struct net_device *dev,
/* The P2P Device ID attribute is included in the Beacon frame. */
/* The P2P Device Info attribute is included in the probe response frame. */
_rtw_memset(attr_content, 0x00, 100);
memset(attr_content, 0x00, 100);
if (rtw_get_p2p_attr_content(p2pie, p2pielen, P2P_ATTR_DEVICE_ID, attr_content, &attr_contentlen)) {
/* Handle the P2P Device ID attribute of Beacon first */
blnMatch = 1;
@@ -4678,7 +4678,7 @@ static int rtw_p2p_get_invitation_procedure(struct net_device *dev,
p2pie = rtw_bss_ex_get_p2p_ie(&pnetwork->network, NULL, &p2pielen);
if (p2pie) {
while (p2pie) {
/* _rtw_memset( attr_content, 0x00, 2); */
/* memset( attr_content, 0x00, 2); */
if (rtw_get_p2p_attr_content(p2pie, p2pielen, P2P_ATTR_CAPABILITY, attr_content, &attr_contentlen)) {
/* Handle the P2P capability attribute */
blnMatch = 1;
@@ -4793,8 +4793,8 @@ static int rtw_p2p_connect(struct net_device *dev,
_cancel_timer_ex(&pwdinfo->ap_p2p_switch_timer);
#endif /* CONFIG_CONCURRENT_MODE */
_rtw_memset(&pwdinfo->nego_req_info, 0x00, sizeof(struct tx_nego_req_info));
_rtw_memset(&pwdinfo->groupid_info, 0x00, sizeof(struct group_id_info));
memset(&pwdinfo->nego_req_info, 0x00, sizeof(struct tx_nego_req_info));
memset(&pwdinfo->groupid_info, 0x00, sizeof(struct group_id_info));
pwdinfo->nego_req_info.peer_channel_num[0] = uintPeerChannel;
_rtw_memcpy(pwdinfo->nego_req_info.peerDevAddr, pnetwork->network.MacAddress, ETH_ALEN);
@@ -4892,11 +4892,11 @@ static int rtw_p2p_invite_req(struct net_device *dev,
} else {
/* Reset the content of struct tx_invite_req_info */
pinvite_req_info->benable = _FALSE;
_rtw_memset(pinvite_req_info->go_bssid, 0x00, ETH_ALEN);
_rtw_memset(pinvite_req_info->go_ssid, 0x00, WLAN_SSID_MAXLEN);
memset(pinvite_req_info->go_bssid, 0x00, ETH_ALEN);
memset(pinvite_req_info->go_ssid, 0x00, WLAN_SSID_MAXLEN);
pinvite_req_info->ssidlen = 0x00;
pinvite_req_info->operating_ch = pwdinfo->operating_channel;
_rtw_memset(pinvite_req_info->peer_macaddr, 0x00, ETH_ALEN);
memset(pinvite_req_info->peer_macaddr, 0x00, ETH_ALEN);
pinvite_req_info->token = 3;
}
@@ -5384,9 +5384,9 @@ static int rtw_p2p_prov_disc(struct net_device *dev,
#endif /* CONFIG_INTEL_WIDI */
/* Reset the content of struct tx_provdisc_req_info excluded the wps_config_method_request. */
_rtw_memset(pwdinfo->tx_prov_disc_info.peerDevAddr, 0x00, ETH_ALEN);
_rtw_memset(pwdinfo->tx_prov_disc_info.peerIFAddr, 0x00, ETH_ALEN);
_rtw_memset(&pwdinfo->tx_prov_disc_info.ssid, 0x00, sizeof(NDIS_802_11_SSID));
memset(pwdinfo->tx_prov_disc_info.peerDevAddr, 0x00, ETH_ALEN);
memset(pwdinfo->tx_prov_disc_info.peerIFAddr, 0x00, ETH_ALEN);
memset(&pwdinfo->tx_prov_disc_info.ssid, 0x00, sizeof(NDIS_802_11_SSID));
pwdinfo->tx_prov_disc_info.peer_channel_num[0] = 0;
pwdinfo->tx_prov_disc_info.peer_channel_num[1] = 0;
pwdinfo->tx_prov_disc_info.benable = _FALSE;
@@ -6998,7 +6998,7 @@ static int rtw_set_encryption(struct net_device *dev, struct ieee_param *param,
goto exit;
}
_rtw_memset(pwep, 0, wep_total_len);
memset(pwep, 0, wep_total_len);
pwep->KeyLength = wep_key_len;
pwep->Length = wep_total_len;
@@ -8257,7 +8257,7 @@ int rtw_vendor_ie_get_raw_data(struct net_device *dev, u32 vendor_ie_num,
}
vendor_ie_mask = pmlmepriv->vendor_ie_mask[vendor_ie_num];
_rtw_memset(extra, 0, length);
memset(extra, 0, length);
pstring = extra;
pstring += sprintf(pstring, "%d,%x,", vendor_ie_num, vendor_ie_mask);
@@ -8432,7 +8432,7 @@ int rtw_vendor_ie_set(struct net_device *dev, struct iw_request_info *info, unio
return ret;
_clear_path:
_rtw_memset(pmlmepriv->vendor_ie[vendor_ie_num] , 0 , sizeof(u32) * WLAN_MAX_VENDOR_IE_LEN);
memset(pmlmepriv->vendor_ie[vendor_ie_num] , 0 , sizeof(u32) * WLAN_MAX_VENDOR_IE_LEN);
pmlmepriv->vendor_ielen[vendor_ie_num] = 0;
pmlmepriv->vendor_ie_mask[vendor_ie_num] = 0;
return -EFAULT;
@@ -8657,7 +8657,7 @@ static int rtw_mp_efuse_get(struct net_device *dev,
goto exit;
}
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
shift = blksz * raw_order;
rawdata += shift;
@@ -8705,7 +8705,7 @@ static int rtw_mp_efuse_get(struct net_device *dev,
goto exit;
}
#endif
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
shift = blksz * bt_raw_order;
rawdata += shift;
@@ -9758,7 +9758,7 @@ static int rtw_mp_efuse_set(struct net_device *dev,
for (jj = 0, kk = 0; jj < cnts; jj++, kk += 2)
pEfuseHal->fakeEfuseModifiedMap[addr + jj] = key_2char2num(tmp[2][kk], tmp[2][kk + 1]);
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
sprintf(extra, "wlwfake OK\n");
}
@@ -9797,7 +9797,7 @@ static int rtw_mp_efuse_set(struct net_device *dev,
for (jj = 0, kk = 0; jj < cnts; jj++, kk += 2)
pEfuseHal->fakeEfuseModifiedMap[addr + jj] = key_2char2num(tmp[1][kk], tmp[1][kk + 1]);
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
sprintf(extra, "write mac addr to fake map OK\n");
} else if(strcmp(tmp[0], "update") == 0) {
RTW_INFO("To Use new eFuse map\n");
@@ -9820,12 +9820,12 @@ static int rtw_mp_efuse_set(struct net_device *dev,
err = -EINVAL;
goto exit;
}
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
sprintf(extra, "eFuse Update OK\n");
} else if (strcmp(tmp[0], "analyze") == 0) {
rtw_efuse_analyze(padapter, EFUSE_WIFI, 0);
_rtw_memset(extra, '\0', strlen(extra));
memset(extra, '\0', strlen(extra));
sprintf(extra, "eFuse Analyze OK,please to check kernel log\n");
}
exit:
@@ -9898,7 +9898,7 @@ static int rtw_mp_customer_str(
return -EFAULT;
}
_rtw_memset(param, 0xFF, RTW_CUSTOMER_STR_LEN);
memset(param, 0xFF, RTW_CUSTOMER_STR_LEN);
if (strcmp(pch, "read") == 0) {
read = 1;
@@ -10205,7 +10205,7 @@ static int rtw_mp_sd_iread(struct net_device *dev
goto exit;
}
_rtw_memset(extra, 0, wrqu->length);
memset(extra, 0, wrqu->length);
if (sscanf(input, "%hhu,%lx", &width, &addr) != 2) {
RTW_INFO(FUNC_ADPT_FMT" sscanf fail\n", FUNC_ADPT_ARG(padapter));
@@ -10268,7 +10268,7 @@ static int rtw_mp_sd_iwrite(struct net_device *dev
goto exit;
}
_rtw_memset(extra, 0, wrqu->length);
memset(extra, 0, wrqu->length);
if (sscanf(input, "%hhu,%lx,%lx", &width, &addr, &data) != 3) {
RTW_INFO(FUNC_ADPT_FMT" sscanf fail\n", FUNC_ADPT_ARG(padapter));
@@ -10532,7 +10532,7 @@ static int rtw_tdls_setup(struct net_device *dev,
return ret;
}
_rtw_memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
for (i = 0, j = 0 ; i < ETH_ALEN; i++, j += 3)
txmgmt.peer[i] = key_2char2num(*(extra + j), *(extra + j + 1));
@@ -10576,7 +10576,7 @@ static int rtw_tdls_teardown(struct net_device *dev,
return ret;
}
_rtw_memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
for (i = 0, j = 0; i < ETH_ALEN; i++, j += 3)
txmgmt.peer[i] = key_2char2num(*(extra + j), *(extra + j + 1));
@@ -10609,7 +10609,7 @@ static int rtw_tdls_discovery(struct net_device *dev,
RTW_INFO("[%s] %s %d\n", __FUNCTION__, extra, wrqu->data.length - 1);
_rtw_memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
for (i = 0, j = 0 ; i < ETH_ALEN; i++, j += 3)
txmgmt.peer[i] = key_2char2num(*(extra + j), *(extra + j + 1));
@@ -10696,7 +10696,7 @@ static int rtw_tdls_ch_switch_off(struct net_device *dev,
struct sta_info *ptdls_sta = NULL;
struct tdls_txmgmt txmgmt;
_rtw_memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
memset(&txmgmt, 0x00, sizeof(struct tdls_txmgmt));
RTW_INFO("[%s] %s %d\n", __FUNCTION__, extra, wrqu->data.length - 1);
@@ -10719,7 +10719,7 @@ static int rtw_tdls_ch_switch_off(struct net_device *dev,
pchsw_info->ch_sw_state &= ~(TDLS_CH_SW_INITIATOR_STATE |
TDLS_CH_SWITCH_ON_STATE |
TDLS_PEER_AT_OFF_STATE);
_rtw_memset(pchsw_info->addr, 0x00, ETH_ALEN);
memset(pchsw_info->addr, 0x00, ETH_ALEN);
ptdls_sta->ch_switch_time = 0;
ptdls_sta->ch_switch_timeout = 0;
@@ -11394,7 +11394,7 @@ static s32 initLoopback(PADAPTER padapter)
ploopback->bstop = _TRUE;
ploopback->cnt = 0;
ploopback->size = 300;
_rtw_memset(ploopback->msg, 0, sizeof(ploopback->msg));
memset(ploopback->msg, 0, sizeof(ploopback->msg));
padapter->ploopback = ploopback;
}
@@ -11451,7 +11451,7 @@ static s32 createpseudoadhoc(PADAPTER padapter)
return _FAIL;
passoc_ssid = &pmlmepriv->assoc_ssid;
_rtw_memset(passoc_ssid, 0, sizeof(NDIS_802_11_SSID));
memset(passoc_ssid, 0, sizeof(NDIS_802_11_SSID));
passoc_ssid->SsidLength = sizeof(ssid) - 1;
_rtw_memcpy(passoc_ssid->Ssid, ssid, passoc_ssid->SsidLength);
@@ -11546,12 +11546,12 @@ static struct xmit_frame *createloopbackpkt(PADAPTER padapter, u32 size)
pattrib = &pframe->attrib;
/* init xmitframe attribute */
_rtw_memset(pattrib, 0, sizeof(struct pkt_attrib));
memset(pattrib, 0, sizeof(struct pkt_attrib));
pattrib->ether_type = 0x8723;
_rtw_memcpy(pattrib->src, adapter_mac_addr(padapter), ETH_ALEN);
_rtw_memcpy(pattrib->ta, pattrib->src, ETH_ALEN);
_rtw_memset(pattrib->dst, 0xFF, ETH_ALEN);
memset(pattrib->dst, 0xFF, ETH_ALEN);
_rtw_memcpy(pattrib->ra, pattrib->dst, ETH_ALEN);
/* pattrib->dhcp_pkt = 0;
@@ -11580,7 +11580,7 @@ static struct xmit_frame *createloopbackpkt(PADAPTER padapter, u32 size)
/* 2 4. fill TX descriptor */
desc = (struct tx_desc *)pframe->buf_addr;
_rtw_memset(desc, 0, TXDESC_SIZE);
memset(desc, 0, TXDESC_SIZE);
fill_default_txdesc(pframe, (u8 *)desc);
@@ -11803,9 +11803,9 @@ thread_return lbk_thread(thread_context context)
fail++;
ploopback->txsize = 0;
_rtw_memset(ploopback->txbuf, 0, 0x8000);
memset(ploopback->txbuf, 0, 0x8000);
ploopback->rxsize = 0;
_rtw_memset(ploopback->rxbuf, 0, 0x8000);
memset(ploopback->rxbuf, 0, 0x8000);
freeloopbackpkt(padapter, pxmitframe);
pxmitframe = NULL;