mirror of
https://github.com/chinawrj/rtl8812au
synced 2024-11-09 23:57:10 +00:00
Fix minor indentations
This commit is contained in:
parent
f2b259a389
commit
eccee894cd
@ -4469,8 +4469,8 @@ void rtw_cfg80211_indicate_sta_assoc(_adapter *padapter, u8 *pmgmt_frame, uint f
|
||||
#if defined(RTW_USE_CFG80211_STA_EVENT) || defined(COMPAT_KERNEL_RELEASE)
|
||||
{
|
||||
struct station_info sinfo;
|
||||
u8 ie_offset;
|
||||
_rtw_memset(&sinfo, 0, sizeof(struct station_info));
|
||||
u8 ie_offset;
|
||||
|
||||
if (get_frame_sub_type(pmgmt_frame) == WIFI_ASSOCREQ)
|
||||
ie_offset = _ASOCREQ_IE_OFFSET_;
|
||||
@ -4726,7 +4726,6 @@ dump:
|
||||
pattrib->seqnum = pmlmeext->mgnt_seq;
|
||||
pmlmeext->mgnt_seq++;
|
||||
|
||||
|
||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||
|
||||
dump_mgntframe(padapter, pmgntframe);
|
||||
@ -4734,7 +4733,6 @@ dump:
|
||||
} else
|
||||
RTW_INFO("frame_ctl=0x%x\n", frame_ctl & (RTW_IEEE80211_FCTL_FTYPE | RTW_IEEE80211_FCTL_STYPE));
|
||||
|
||||
|
||||
fail:
|
||||
|
||||
rtw_skb_free(skb);
|
||||
@ -5032,10 +5030,8 @@ static int rtw_add_beacon(_adapter *adapter, const u8 *head, size_t head_len, co
|
||||
struct mlme_priv *pmlmepriv = &(adapter->mlmepriv);
|
||||
/* struct sta_priv *pstapriv = &padapter->stapriv; */
|
||||
|
||||
|
||||
RTW_INFO("%s beacon_head_len=%zu, beacon_tail_len=%zu\n", __FUNCTION__, head_len, tail_len);
|
||||
|
||||
|
||||
if (check_fwstate(pmlmepriv, WIFI_AP_STATE) != _TRUE)
|
||||
return -EINVAL;
|
||||
|
||||
@ -5053,13 +5049,11 @@ static int rtw_add_beacon(_adapter *adapter, const u8 *head, size_t head_len, co
|
||||
if (!pbuf)
|
||||
return -ENOMEM;
|
||||
|
||||
|
||||
/* _rtw_memcpy(&pstapriv->max_num_sta, param->u.bcn_ie.reserved, 2); */
|
||||
|
||||
/* if((pstapriv->max_num_sta>NUM_STA) || (pstapriv->max_num_sta<=0)) */
|
||||
/* pstapriv->max_num_sta = NUM_STA; */
|
||||
|
||||
|
||||
_rtw_memcpy(pbuf, (void *)head + 24, head_len - 24); /* 24=beacon header len. */
|
||||
_rtw_memcpy(pbuf + head_len - 24, (void *)tail, tail_len);
|
||||
|
||||
@ -5113,7 +5107,6 @@ static int rtw_add_beacon(_adapter *adapter, const u8 *head, size_t head_len, co
|
||||
} else
|
||||
ret = -EINVAL;
|
||||
|
||||
|
||||
rtw_mfree(pbuf, head_len + tail_len);
|
||||
|
||||
return ret;
|
||||
@ -5243,11 +5236,11 @@ static int cfg80211_rtw_change_beacon(struct wiphy *wiphy, struct net_device *nd
|
||||
if(ret == 0) {
|
||||
if(info->proberesp_ies && info->proberesp_ies_len > 0) {
|
||||
rtw_cfg80211_set_mgnt_wpsp2pie(ndev, (char *)info->proberesp_ies,
|
||||
info->proberesp_ies_len, 0x2/*PROBE_RESP*/);
|
||||
info->proberesp_ies_len, 0x2 /*PROBE_RESP*/);
|
||||
}
|
||||
if(info->assocresp_ies && info->assocresp_ies_len > 0) {
|
||||
rtw_cfg80211_set_mgnt_wpsp2pie(ndev, (char *)info->assocresp_ies,
|
||||
info->assocresp_ies_len, 0x4/*ASSOC_RESP*/);
|
||||
info->assocresp_ies_len, 0x4 /*ASSOC_RESP*/);
|
||||
}
|
||||
}
|
||||
|
||||
@ -5688,7 +5681,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
||||
if (!target_mac) {
|
||||
RTW_INFO("flush all sta, and cam_entry\n");
|
||||
|
||||
@ -5700,7 +5692,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
RTW_INFO("free sta macaddr =" MAC_FMT "\n", MAC_ARG(target_mac));
|
||||
|
||||
if (target_mac[0] == 0xff && target_mac[1] == 0xff &&
|
||||
@ -5708,7 +5699,6 @@ static int cfg80211_rtw_del_station(struct wiphy *wiphy, struct net_device *ndev
|
||||
target_mac[4] == 0xff && target_mac[5] == 0xff)
|
||||
return -EINVAL;
|
||||
|
||||
|
||||
_enter_critical_bh(&pstapriv->asoc_list_lock, &irqL);
|
||||
|
||||
phead = &pstapriv->asoc_list;
|
||||
@ -5878,7 +5868,7 @@ release_plink_ctl:
|
||||
if (del_sta) {
|
||||
u8 sta_addr[ETH_ALEN];
|
||||
u8 updated = _FALSE;
|
||||
|
||||
|
||||
_rtw_memcpy(sta_addr, del_sta->cmn.mac_addr, ETH_ALEN);
|
||||
updated = ap_free_sta(adapter, del_sta, 0, 0, 1);
|
||||
rtw_mesh_expire_peer(stapriv->padapter, sta_addr);
|
||||
@ -6518,7 +6508,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
u8 *frame_body = (unsigned char *)(buf + sizeof(struct rtw_ieee80211_hdr_3addr));
|
||||
size_t frame_body_len = len - sizeof(struct rtw_ieee80211_hdr_3addr);
|
||||
|
||||
|
||||
RTW_INFO("[%s] In\n", __FUNCTION__);
|
||||
|
||||
/* prepare for building provision_request frame */
|
||||
@ -6552,7 +6541,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if (rtw_get_p2p_ie(frame_body + _PUBLIC_ACTION_IE_OFFSET_, frame_body_len - _PUBLIC_ACTION_IE_OFFSET_, p2p_ie, &p2p_ielen)) {
|
||||
|
||||
rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_DEVICE_INFO, devinfo_content, &devinfo_contentlen);
|
||||
@ -6560,7 +6548,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* start to build provision_request frame */
|
||||
_rtw_memset(wpsie, 0, sizeof(wpsie));
|
||||
_rtw_memset(p2p_ie, 0, sizeof(p2p_ie));
|
||||
@ -6570,7 +6557,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
if (pmgntframe == NULL)
|
||||
return;
|
||||
|
||||
|
||||
/* update attribute */
|
||||
pattrib = &pmgntframe->attrib;
|
||||
update_mgntframe_attrib(padapter, pattrib);
|
||||
@ -6600,7 +6586,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
pframe = rtw_set_fixed_ie(pframe, 1, &(oui_subtype), &(pattrib->pktlen));
|
||||
pframe = rtw_set_fixed_ie(pframe, 1, &(dialogToken), &(pattrib->pktlen));
|
||||
|
||||
|
||||
/* build_prov_disc_request_p2p_ie */
|
||||
/* P2P OUI */
|
||||
p2pielen = 0;
|
||||
@ -6630,7 +6615,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
_rtw_memcpy(p2p_ie + p2pielen, &capability, 2);
|
||||
p2pielen += 2;
|
||||
|
||||
|
||||
/* Device Info ATTR */
|
||||
/* Type: */
|
||||
p2p_ie[p2pielen++] = P2P_ATTR_DEVICE_INFO;
|
||||
@ -6646,7 +6630,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
_rtw_memcpy(p2p_ie + p2pielen, devinfo_content, devinfo_contentlen);
|
||||
p2pielen += devinfo_contentlen;
|
||||
|
||||
|
||||
pframe = rtw_set_ie(pframe, _VENDOR_SPECIFIC_IE_, p2pielen, (unsigned char *) p2p_ie, &p2p_ielen);
|
||||
/* p2pielen = build_prov_disc_request_p2p_ie( pwdinfo, pframe, NULL, 0, pwdinfo->tx_prov_disc_info.peerDevAddr); */
|
||||
/* pframe += p2pielen; */
|
||||
@ -6684,7 +6667,6 @@ void rtw_cfg80211_issue_p2p_provision_request(_adapter *padapter, const u8 *buf,
|
||||
|
||||
pframe = rtw_set_ie(pframe, _VENDOR_SPECIFIC_IE_, wpsielen, (unsigned char *) wpsie, &pattrib->pktlen);
|
||||
|
||||
|
||||
#ifdef CONFIG_WFD
|
||||
wfdielen = build_provdisc_req_wfd_ie(pwdinfo, pframe);
|
||||
pframe += wfdielen;
|
||||
@ -8080,7 +8062,7 @@ void dump_mesh_config(void *sel, const struct mesh_config *conf)
|
||||
RTW_PRINT_SEL(sel, "path_refresh_time:%u\n", conf->path_refresh_time);
|
||||
RTW_PRINT_SEL(sel, "min_discovery_timeout:%u\n", conf->min_discovery_timeout);
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMPactivePathTimeout:%u\n", conf->dot11MeshHWMPactivePathTimeout);
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMPpreqMinInterval:%u\n", conf->dot11MeshHWMPpreqMinInterval);
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMPpreqMinInterval:%u\n", conf->dot11MeshHWMPpreqMinInterval);
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 3, 0))
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMPperrMinInterval:%u\n", conf->dot11MeshHWMPperrMinInterval);
|
||||
#endif
|
||||
@ -8095,11 +8077,11 @@ void dump_mesh_config(void *sel, const struct mesh_config *conf)
|
||||
RTW_PRINT_SEL(sel, "dot11MeshForwarding:%d\n", conf->dot11MeshForwarding);
|
||||
RTW_PRINT_SEL(sel, "rssi_threshold:%d\n", conf->rssi_threshold);
|
||||
#endif
|
||||
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 5, 0))
|
||||
RTW_PRINT_SEL(sel, "ht_opmode:0x%04x\n", conf->ht_opmode);
|
||||
#endif
|
||||
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0))
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMPactivePathToRootTimeout:%u\n", conf->dot11MeshHWMPactivePathToRootTimeout);
|
||||
RTW_PRINT_SEL(sel, "dot11MeshHWMProotInterval:%u\n", conf->dot11MeshHWMProotInterval);
|
||||
@ -8110,7 +8092,7 @@ void dump_mesh_config(void *sel, const struct mesh_config *conf)
|
||||
RTW_PRINT_SEL(sel, "power_mode:%s\n", nl80211_mesh_power_mode_str(conf->power_mode));
|
||||
RTW_PRINT_SEL(sel, "dot11MeshAwakeWindowDuration:%u\n", conf->dot11MeshAwakeWindowDuration);
|
||||
#endif
|
||||
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 11, 0))
|
||||
RTW_PRINT_SEL(sel, "plink_timeout:%u\n", conf->plink_timeout);
|
||||
#endif
|
||||
@ -8246,14 +8228,14 @@ static void rtw_cfg80211_mesh_cfg_set(_adapter *adapter, const struct mesh_confi
|
||||
if (chk_mesh_attr(NL80211_MESHCONF_HT_OPMODE, mask));
|
||||
#endif
|
||||
#endif
|
||||
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0))
|
||||
if (chk_mesh_attr(NL80211_MESHCONF_HWMP_PATH_TO_ROOT_TIMEOUT, mask))
|
||||
mcfg->dot11MeshHWMPactivePathToRootTimeout = conf->dot11MeshHWMPactivePathToRootTimeout;
|
||||
if (chk_mesh_attr(NL80211_MESHCONF_HWMP_ROOT_INTERVAL, mask))
|
||||
mcfg->dot11MeshHWMProotInterval = conf->dot11MeshHWMProotInterval;
|
||||
if (chk_mesh_attr(NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL, mask))
|
||||
mcfg->dot11MeshHWMPconfirmationInterval = conf->dot11MeshHWMPconfirmationInterval;
|
||||
mcfg->dot11MeshHWMPconfirmationInterval = conf->dot11MeshHWMPconfirmationInterval;
|
||||
#endif
|
||||
|
||||
#if 0 /* TBD */
|
||||
@ -8311,7 +8293,7 @@ u8 *rtw_cfg80211_construct_mesh_beacon_ies(struct wiphy *wiphy, _adapter *adapte
|
||||
#endif
|
||||
if (!ch)
|
||||
goto exit;
|
||||
|
||||
|
||||
#if defined(CONFIG_80211AC_VHT) && (LINUX_VERSION_CODE >= KERNEL_VERSION(3, 6, 0))
|
||||
vht = ht && ch > 14 && bw >= CHANNEL_WIDTH_80; /* VHT40/VHT20? */
|
||||
#endif
|
||||
@ -8642,7 +8624,7 @@ static int cfg80211_rtw_join_mesh(struct wiphy *wiphy, struct net_device *dev,
|
||||
ret = -EINVAL;
|
||||
goto exit;
|
||||
}
|
||||
|
||||
|
||||
rtw_mesh_work(&adapter->mesh_work);
|
||||
|
||||
exit:
|
||||
@ -8723,7 +8705,7 @@ static int cfg80211_rtw_del_mpath(struct wiphy *wiphy, struct net_device *dev
|
||||
}
|
||||
} else {
|
||||
rtw_mesh_path_flush_by_iface(adapter);
|
||||
}
|
||||
}
|
||||
|
||||
exit:
|
||||
return ret;
|
||||
@ -9001,7 +8983,6 @@ int cfg80211_rtw_resume(struct wiphy *wiphy) {
|
||||
struct sitesurvey_parm parm;
|
||||
int i, len;
|
||||
|
||||
|
||||
RTW_DBG("==> %s\n",__func__);
|
||||
if (pwrpriv->wowlan_last_wake_reason == RX_PNO) {
|
||||
|
||||
@ -9024,13 +9005,13 @@ int cfg80211_rtw_resume(struct wiphy *wiphy) {
|
||||
//rtw_sitesurvey_cmd(padapter, NULL);
|
||||
rtw_sitesurvey_cmd(padapter, &parm);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
|
||||
|
||||
for (PNOWakeupScanWaitCnt = 0; PNOWakeupScanWaitCnt < 10; PNOWakeupScanWaitCnt++) {
|
||||
if(check_fwstate(pmlmepriv, _FW_UNDER_SURVEY) == _FALSE)
|
||||
break;
|
||||
rtw_msleep_os(1000);
|
||||
}
|
||||
|
||||
|
||||
_enter_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
cfg80211_sched_scan_results(padapter->rtw_wdev->wiphy);
|
||||
_exit_critical_bh(&pmlmepriv->lock, &irqL);
|
||||
@ -9038,7 +9019,7 @@ int cfg80211_rtw_resume(struct wiphy *wiphy) {
|
||||
}
|
||||
RTW_DBG("<== %s\n",__func__);
|
||||
return 0;
|
||||
|
||||
|
||||
}
|
||||
#endif /* CONFIG_PNO_SUPPORT */
|
||||
|
||||
@ -9242,7 +9223,6 @@ static int rtw_cfg80211_set_probe_resp_wpsp2pie(struct net_device *net, char *bu
|
||||
RTW_INFO("Got P2P Capability Attr, grp_cap=0x%x, is_GO\n", grp_cap);
|
||||
}
|
||||
|
||||
|
||||
if (is_GO == _FALSE) {
|
||||
if (pmlmepriv->p2p_probe_resp_ie) {
|
||||
u32 free_len = pmlmepriv->p2p_probe_resp_ie_len;
|
||||
@ -9280,7 +9260,6 @@ static int rtw_cfg80211_set_probe_resp_wpsp2pie(struct net_device *net, char *bu
|
||||
}
|
||||
#endif /* CONFIG_P2P */
|
||||
|
||||
|
||||
#ifdef CONFIG_WFD
|
||||
wfd_ie = rtw_get_wfd_ie(buf, len, NULL, &wfd_ielen);
|
||||
if (wfd_ie) {
|
||||
@ -10040,7 +10019,7 @@ int rtw_hostapd_acs_dump_survey(struct wiphy *wiphy, struct net_device *netdev,
|
||||
#elif defined(CONFIG_RTW_ACS) && defined(CONFIG_BACKGROUND_NOISE_MONITOR)
|
||||
rtw_cfg80211_set_survey_info_with_clm(padapter, idx, info);
|
||||
#else
|
||||
RTW_ERR("%s: unknown acs operation!\n", __func__);
|
||||
RTW_ERR("%s: unknown acs operation!\n", __func__);
|
||||
#endif
|
||||
|
||||
return ret;
|
||||
@ -10392,7 +10371,6 @@ int rtw_wdev_alloc(_adapter *padapter, struct wiphy *wiphy)
|
||||
pwdev_priv->rssi_monitor_min = 0;
|
||||
#endif
|
||||
|
||||
|
||||
exit:
|
||||
return ret;
|
||||
}
|
||||
@ -10579,4 +10557,3 @@ void rtw_cfg80211_dev_res_unregister(struct dvobj_priv *dvobj)
|
||||
}
|
||||
|
||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user