mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2024-11-22 04:23:39 +00:00
rtl8188eu: Remove CONFIG_IOCTL_CFG80211 and others
The other parameters are CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER, CONFIG_SET_SCAN_DENY_TIMER, CONFIG_DRV_ISSUE_PROV_REQ, and RTW_USE_CFG80211_STA_EVENT. None of these are defined. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
7333ca4047
commit
f2c2552bb1
20 changed files with 807 additions and 6584 deletions
1
Makefile
1
Makefile
|
@ -76,7 +76,6 @@ endif
|
||||||
HCI_NAME = usb
|
HCI_NAME = usb
|
||||||
|
|
||||||
_OS_INTFS_FILES := \
|
_OS_INTFS_FILES := \
|
||||||
os_dep/ioctl_cfg80211.o \
|
|
||||||
os_dep/ioctl_linux.o \
|
os_dep/ioctl_linux.o \
|
||||||
os_dep/mlme_linux.o \
|
os_dep/mlme_linux.o \
|
||||||
os_dep/os_intfs.o \
|
os_dep/os_intfs.o \
|
||||||
|
|
|
@ -1970,20 +1970,7 @@ u8 ap_free_sta(_adapter *padapter, struct sta_info *psta, bool active, u16 reaso
|
||||||
psta->state &= ~_FW_LINKED;
|
psta->state &= ~_FW_LINKED;
|
||||||
_exit_critical_bh(&psta->lock, &irqL);
|
_exit_critical_bh(&psta->lock, &irqL);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (1) {
|
|
||||||
#ifdef COMPAT_KERNEL_RELEASE
|
|
||||||
rtw_cfg80211_indicate_sta_disassoc(padapter, psta->hwaddr, reason);
|
|
||||||
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER)
|
|
||||||
rtw_cfg80211_indicate_sta_disassoc(padapter, psta->hwaddr, reason);
|
|
||||||
#else /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
/* will call rtw_cfg80211_indicate_sta_disassoc() in cmd_thread for old API context */
|
|
||||||
#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
} else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
rtw_indicate_sta_disassoc_event(padapter, psta);
|
rtw_indicate_sta_disassoc_event(padapter, psta);
|
||||||
}
|
|
||||||
|
|
||||||
report_del_sta_event(padapter, psta->hwaddr, reason);
|
report_del_sta_event(padapter, psta->hwaddr, reason);
|
||||||
|
|
||||||
|
@ -1993,9 +1980,7 @@ u8 ap_free_sta(_adapter *padapter, struct sta_info *psta, bool active, u16 reaso
|
||||||
rtw_free_stainfo(padapter, psta);
|
rtw_free_stainfo(padapter, psta);
|
||||||
_exit_critical_bh(&(pstapriv->sta_hash_lock), &irqL);
|
_exit_critical_bh(&(pstapriv->sta_hash_lock), &irqL);
|
||||||
|
|
||||||
|
|
||||||
return beacon_updated;
|
return beacon_updated;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int rtw_ap_inform_ch_switch (_adapter *padapter, u8 new_ch, u8 ch_offset)
|
int rtw_ap_inform_ch_switch (_adapter *padapter, u8 new_ch, u8 ch_offset)
|
||||||
|
|
|
@ -136,15 +136,6 @@ void rtw_free_mlme_priv_ie_data(struct mlme_priv *pmlmepriv)
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->p2p_go_probe_resp_ie, &pmlmepriv->p2p_go_probe_resp_ie_len);
|
rtw_free_mlme_ie_data(&pmlmepriv->p2p_go_probe_resp_ie, &pmlmepriv->p2p_go_probe_resp_ie_len);
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->p2p_assoc_req_ie, &pmlmepriv->p2p_assoc_req_ie_len);
|
rtw_free_mlme_ie_data(&pmlmepriv->p2p_assoc_req_ie, &pmlmepriv->p2p_assoc_req_ie_len);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CONFIG_WFD) && defined(CONFIG_IOCTL_CFG80211)
|
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->wfd_beacon_ie, &pmlmepriv->wfd_beacon_ie_len);
|
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->wfd_probe_req_ie, &pmlmepriv->wfd_probe_req_ie_len);
|
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->wfd_probe_resp_ie, &pmlmepriv->wfd_probe_resp_ie_len);
|
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->wfd_go_probe_resp_ie, &pmlmepriv->wfd_go_probe_resp_ie_len);
|
|
||||||
rtw_free_mlme_ie_data(&pmlmepriv->wfd_assoc_req_ie, &pmlmepriv->wfd_assoc_req_ie_len);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void _rtw_free_mlme_priv (struct mlme_priv *pmlmepriv)
|
void _rtw_free_mlme_priv (struct mlme_priv *pmlmepriv)
|
||||||
|
@ -1106,10 +1097,6 @@ _func_enter_;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_cfg80211_surveydone_event_callback(adapter);
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
_func_exit_;
|
_func_exit_;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1747,38 +1734,6 @@ _func_enter_;
|
||||||
psta = rtw_get_stainfo(&adapter->stapriv, pstassoc->macaddr);
|
psta = rtw_get_stainfo(&adapter->stapriv, pstassoc->macaddr);
|
||||||
if (psta)
|
if (psta)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#ifdef COMPAT_KERNEL_RELEASE
|
|
||||||
|
|
||||||
#elif (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)) || defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER)
|
|
||||||
u8 *passoc_req = NULL;
|
|
||||||
u32 assoc_req_len;
|
|
||||||
|
|
||||||
_enter_critical_bh(&psta->lock, &irqL);
|
|
||||||
if (psta->passoc_req && psta->assoc_req_len>0)
|
|
||||||
{
|
|
||||||
passoc_req = rtw_zmalloc(psta->assoc_req_len);
|
|
||||||
if (passoc_req)
|
|
||||||
{
|
|
||||||
assoc_req_len = psta->assoc_req_len;
|
|
||||||
_rtw_memcpy(passoc_req, psta->passoc_req, assoc_req_len);
|
|
||||||
|
|
||||||
_rtw_mfree(psta->passoc_req , psta->assoc_req_len);
|
|
||||||
psta->passoc_req = NULL;
|
|
||||||
psta->assoc_req_len = 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
_exit_critical_bh(&psta->lock, &irqL);
|
|
||||||
|
|
||||||
if (passoc_req && assoc_req_len>0)
|
|
||||||
{
|
|
||||||
rtw_cfg80211_indicate_sta_assoc(adapter, passoc_req, assoc_req_len);
|
|
||||||
|
|
||||||
_rtw_mfree(passoc_req, assoc_req_len);
|
|
||||||
}
|
|
||||||
#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)) || defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
/* bss_cap_update_on_sta_join(adapter, psta); */
|
/* bss_cap_update_on_sta_join(adapter, psta); */
|
||||||
/* sta_info_update(adapter, psta); */
|
/* sta_info_update(adapter, psta); */
|
||||||
ap_sta_info_defer_update(adapter, psta);
|
ap_sta_info_defer_update(adapter, psta);
|
||||||
|
@ -1881,18 +1836,7 @@ _func_enter_;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (check_fwstate(pmlmepriv, WIFI_AP_STATE))
|
if (check_fwstate(pmlmepriv, WIFI_AP_STATE))
|
||||||
{
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#ifdef COMPAT_KERNEL_RELEASE
|
|
||||||
|
|
||||||
#elif (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)) || defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER)
|
|
||||||
rtw_cfg80211_indicate_sta_disassoc(adapter, pstadel->macaddr, *(u16*)pstadel->rsvd);
|
|
||||||
#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(2,6,37)) || defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
mlmeext_sta_del_event_callback(adapter);
|
mlmeext_sta_del_event_callback(adapter);
|
||||||
|
|
||||||
|
@ -2152,34 +2096,6 @@ void rtw_dynamic_check_timer_handlder(_adapter *adapter)
|
||||||
#endif /* (LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 35)) */
|
#endif /* (LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 35)) */
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
inline bool rtw_is_scan_deny(_adapter *adapter)
|
|
||||||
{
|
|
||||||
struct mlme_priv *mlmepriv = &adapter->mlmepriv;
|
|
||||||
return (ATOMIC_READ(&mlmepriv->set_scan_deny) != 0) ? true : false;
|
|
||||||
}
|
|
||||||
|
|
||||||
inline void rtw_clear_scan_deny(_adapter *adapter)
|
|
||||||
{
|
|
||||||
struct mlme_priv *mlmepriv = &adapter->mlmepriv;
|
|
||||||
ATOMIC_SET(&mlmepriv->set_scan_deny, 0);
|
|
||||||
if (0)
|
|
||||||
DBG_88E(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(adapter));
|
|
||||||
}
|
|
||||||
|
|
||||||
void rtw_set_scan_deny_timer_hdl(_adapter *adapter)
|
|
||||||
{
|
|
||||||
rtw_clear_scan_deny(adapter);
|
|
||||||
}
|
|
||||||
|
|
||||||
void rtw_set_scan_deny(_adapter *adapter, u32 ms)
|
|
||||||
{
|
|
||||||
struct mlme_priv *mlmepriv = &adapter->mlmepriv;
|
|
||||||
ATOMIC_SET(&mlmepriv->set_scan_deny, 1);
|
|
||||||
_set_timer(&mlmepriv->set_scan_deny_timer, ms);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(IEEE80211_SCAN_RESULT_EXPIRE)
|
#if defined(IEEE80211_SCAN_RESULT_EXPIRE)
|
||||||
#define RTW_SCAN_RESULT_EXPIRE IEEE80211_SCAN_RESULT_EXPIRE/HZ*1000 -1000 /* 3000 -1000 */
|
#define RTW_SCAN_RESULT_EXPIRE IEEE80211_SCAN_RESULT_EXPIRE/HZ*1000 -1000 /* 3000 -1000 */
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -658,26 +658,11 @@ static u32 p2p_listen_state_process(_adapter *padapter, unsigned char *da)
|
||||||
{
|
{
|
||||||
bool response = true;
|
bool response = true;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled == false
|
|
||||||
|| padapter->mlmepriv.wps_probe_resp_ie == NULL
|
|
||||||
|| padapter->mlmepriv.p2p_probe_resp_ie == NULL
|
|
||||||
)
|
|
||||||
{
|
|
||||||
DBG_88E("DON'T issue_probersp_p2p: p2p_enabled:%d, wps_probe_resp_ie:%p, p2p_probe_resp_ie:%p\n",
|
|
||||||
wdev_to_priv(padapter->rtw_wdev)->p2p_enabled,
|
|
||||||
padapter->mlmepriv.wps_probe_resp_ie,
|
|
||||||
padapter->mlmepriv.p2p_probe_resp_ie);
|
|
||||||
response = false;
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
|
|
||||||
/* do nothing if the device name is empty */
|
/* do nothing if the device name is empty */
|
||||||
if ( !padapter->wdinfo.device_name_len )
|
if ( !padapter->wdinfo.device_name_len )
|
||||||
{
|
{
|
||||||
response = false;
|
response = false;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
if (response == true)
|
if (response == true)
|
||||||
issue_probersp_p2p( padapter, da);
|
issue_probersp_p2p( padapter, da);
|
||||||
|
@ -732,10 +717,8 @@ unsigned int OnProbeReq(_adapter *padapter, union recv_frame *precv_frame)
|
||||||
{
|
{
|
||||||
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_DEVICE))
|
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_DEVICE))
|
||||||
{
|
{
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
/* FIXME */
|
/* FIXME */
|
||||||
report_survey_event(padapter, precv_frame);
|
report_survey_event(padapter, precv_frame);
|
||||||
#endif
|
|
||||||
p2p_listen_state_process( padapter, get_sa(pframe));
|
p2p_listen_state_process( padapter, get_sa(pframe));
|
||||||
|
|
||||||
return _SUCCESS;
|
return _SUCCESS;
|
||||||
|
@ -1790,35 +1773,7 @@ unsigned int OnAssocReq(_adapter *padapter, union recv_frame *precv_frame)
|
||||||
|
|
||||||
/* 2 - report to upper layer */
|
/* 2 - report to upper layer */
|
||||||
DBG_88E("indicate_sta_join_event to upper layer - hostapd\n");
|
DBG_88E("indicate_sta_join_event to upper layer - hostapd\n");
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (1) {
|
|
||||||
#ifdef COMPAT_KERNEL_RELEASE
|
|
||||||
rtw_cfg80211_indicate_sta_assoc(padapter, pframe, pkt_len);
|
|
||||||
#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER)
|
|
||||||
rtw_cfg80211_indicate_sta_assoc(padapter, pframe, pkt_len);
|
|
||||||
#else /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
_enter_critical_bh(&pstat->lock, &irqL);
|
|
||||||
if (pstat->passoc_req)
|
|
||||||
{
|
|
||||||
rtw_mfree(pstat->passoc_req, pstat->assoc_req_len);
|
|
||||||
pstat->passoc_req = NULL;
|
|
||||||
pstat->assoc_req_len = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
pstat->passoc_req = rtw_zmalloc(pkt_len);
|
|
||||||
if (pstat->passoc_req)
|
|
||||||
{
|
|
||||||
_rtw_memcpy(pstat->passoc_req, pframe, pkt_len);
|
|
||||||
pstat->assoc_req_len = pkt_len;
|
|
||||||
}
|
|
||||||
_exit_critical_bh(&pstat->lock, &irqL);
|
|
||||||
#endif /* LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) */
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
rtw_indicate_sta_assoc_event(padapter, pstat);
|
rtw_indicate_sta_assoc_event(padapter, pstat);
|
||||||
}
|
|
||||||
|
|
||||||
/* 3-(1) report sta add event */
|
/* 3-(1) report sta add event */
|
||||||
report_add_sta_event(padapter, pstat->hwaddr, pstat->aid);
|
report_add_sta_event(padapter, pstat->hwaddr, pstat->aid);
|
||||||
|
@ -4032,11 +3987,6 @@ void issue_probersp_p2p(_adapter *padapter, unsigned char *da)
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
u32 wfdielen = 0;
|
u32 wfdielen = 0;
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
struct cfg80211_wifidirect_info *pcfg80211_wdinfo = &padapter->cfg80211_wdinfo;
|
|
||||||
struct ieee80211_channel *ieee_ch = &pcfg80211_wdinfo->remain_on_ch_channel;
|
|
||||||
u8 listen_channel = (u8) ieee80211_frequency_to_channel(ieee_ch->center_freq);
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
if ((pmgntframe = alloc_mgtxmitframe(pxmitpriv)) == NULL)
|
if ((pmgntframe = alloc_mgtxmitframe(pxmitpriv)) == NULL)
|
||||||
return;
|
return;
|
||||||
|
@ -4095,38 +4045,10 @@ void issue_probersp_p2p(_adapter *padapter, unsigned char *da)
|
||||||
pframe = rtw_set_ie(pframe, _SUPPORTEDRATES_IE_, 8, pwdinfo->support_rate, &pattrib->pktlen);
|
pframe = rtw_set_ie(pframe, _SUPPORTEDRATES_IE_, 8, pwdinfo->support_rate, &pattrib->pktlen);
|
||||||
|
|
||||||
/* DS parameter set */
|
/* DS parameter set */
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled && listen_channel !=0 )
|
|
||||||
{
|
|
||||||
pframe = rtw_set_ie(pframe, _DSSET_IE_, 1, (unsigned char *)&listen_channel, &pattrib->pktlen);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
{
|
||||||
pframe = rtw_set_ie(pframe, _DSSET_IE_, 1, (unsigned char *)&pwdinfo->listen_channel, &pattrib->pktlen);
|
pframe = rtw_set_ie(pframe, _DSSET_IE_, 1, (unsigned char *)&pwdinfo->listen_channel, &pattrib->pktlen);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
if ( pmlmepriv->wps_probe_resp_ie != NULL && pmlmepriv->p2p_probe_resp_ie != NULL )
|
|
||||||
{
|
|
||||||
/* WPS IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wps_probe_resp_ie, pmlmepriv->wps_probe_resp_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->wps_probe_resp_ie_len;
|
|
||||||
pframe += pmlmepriv->wps_probe_resp_ie_len;
|
|
||||||
|
|
||||||
/* P2P IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->p2p_probe_resp_ie, pmlmepriv->p2p_probe_resp_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->p2p_probe_resp_ie_len;
|
|
||||||
pframe += pmlmepriv->p2p_probe_resp_ie_len;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
|
|
||||||
/* Todo: WPS IE */
|
/* Todo: WPS IE */
|
||||||
/* Noted by Albert 20100907 */
|
/* Noted by Albert 20100907 */
|
||||||
/* According to the WPS specification, all the WPS attribute is presented by Big Endian. */
|
/* According to the WPS specification, all the WPS attribute is presented by Big Endian. */
|
||||||
|
@ -4294,35 +4216,18 @@ void issue_probersp_p2p(_adapter *padapter, unsigned char *da)
|
||||||
p2pielen = build_probe_resp_p2p_ie(pwdinfo, pframe);
|
p2pielen = build_probe_resp_p2p_ie(pwdinfo, pframe);
|
||||||
pframe += p2pielen;
|
pframe += p2pielen;
|
||||||
pattrib->pktlen += p2pielen;
|
pattrib->pktlen += p2pielen;
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if ( true == pwdinfo->wfd_info->wfd_enable )
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
wfdielen = build_probe_resp_wfd_ie(pwdinfo, pframe, 0);
|
wfdielen = build_probe_resp_wfd_ie(pwdinfo, pframe, 0);
|
||||||
pframe += wfdielen;
|
pframe += wfdielen;
|
||||||
pattrib->pktlen += wfdielen;
|
pattrib->pktlen += wfdielen;
|
||||||
}
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
else if (pmlmepriv->wfd_probe_resp_ie != NULL && pmlmepriv->wfd_probe_resp_ie_len>0)
|
|
||||||
{
|
|
||||||
/* WFD IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wfd_probe_resp_ie, pmlmepriv->wfd_probe_resp_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->wfd_probe_resp_ie_len;
|
|
||||||
pframe += pmlmepriv->wfd_probe_resp_ie_len;
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
|
|
||||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||||
|
|
||||||
|
|
||||||
dump_mgntframe(padapter, pmgntframe);
|
dump_mgntframe(padapter, pmgntframe);
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int _issue_probereq_p2p(_adapter *padapter, u8 *da, int wait_ack)
|
static int _issue_probereq_p2p(_adapter *padapter, u8 *da, int wait_ack)
|
||||||
|
@ -4407,25 +4312,6 @@ static int _issue_probereq_p2p(_adapter *padapter, u8 *da, int wait_ack)
|
||||||
/* Use the OFDM rate in the P2P probe request frame. ( 6(B), 9(B), 12(B), 24(B), 36, 48, 54 ) */
|
/* Use the OFDM rate in the P2P probe request frame. ( 6(B), 9(B), 12(B), 24(B), 36, 48, 54 ) */
|
||||||
pframe = rtw_set_ie(pframe, _SUPPORTEDRATES_IE_, 8, pwdinfo->support_rate, &pattrib->pktlen);
|
pframe = rtw_set_ie(pframe, _SUPPORTEDRATES_IE_, 8, pwdinfo->support_rate, &pattrib->pktlen);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
if ( pmlmepriv->wps_probe_req_ie != NULL && pmlmepriv->p2p_probe_req_ie != NULL )
|
|
||||||
{
|
|
||||||
/* WPS IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wps_probe_req_ie, pmlmepriv->wps_probe_req_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->wps_probe_req_ie_len;
|
|
||||||
pframe += pmlmepriv->wps_probe_req_ie_len;
|
|
||||||
|
|
||||||
/* P2P IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->p2p_probe_req_ie, pmlmepriv->p2p_probe_req_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->p2p_probe_req_ie_len;
|
|
||||||
pframe += pmlmepriv->p2p_probe_req_ie_len;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
|
|
||||||
/* WPS IE */
|
/* WPS IE */
|
||||||
/* Noted by Albert 20110221 */
|
/* Noted by Albert 20110221 */
|
||||||
|
@ -4637,26 +4523,11 @@ static int _issue_probereq_p2p(_adapter *padapter, u8 *da, int wait_ack)
|
||||||
pattrib->pktlen += pmlmepriv->wps_probe_req_ie_len;
|
pattrib->pktlen += pmlmepriv->wps_probe_req_ie_len;
|
||||||
pframe += pmlmepriv->wps_probe_req_ie_len;
|
pframe += pmlmepriv->wps_probe_req_ie_len;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if ( true == pwdinfo->wfd_info->wfd_enable )
|
|
||||||
#endif
|
|
||||||
{
|
|
||||||
wfdielen = build_probe_req_wfd_ie(pwdinfo, pframe);
|
wfdielen = build_probe_req_wfd_ie(pwdinfo, pframe);
|
||||||
pframe += wfdielen;
|
pframe += wfdielen;
|
||||||
pattrib->pktlen += wfdielen;
|
pattrib->pktlen += wfdielen;
|
||||||
}
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
else if (pmlmepriv->wfd_probe_req_ie != NULL && pmlmepriv->wfd_probe_req_ie_len>0)
|
|
||||||
{
|
|
||||||
/* WFD IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wfd_probe_req_ie, pmlmepriv->wfd_probe_req_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->wfd_probe_req_ie_len;
|
|
||||||
pframe += pmlmepriv->wfd_probe_req_ie_len;
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
|
|
||||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||||
|
@ -4780,14 +4651,6 @@ static unsigned int on_action_public_p2p(union recv_frame *precv_frame)
|
||||||
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
_cancel_timer_ex( &pwdinfo->reset_ch_sitesurvey );
|
_cancel_timer_ex( &pwdinfo->reset_ch_sitesurvey );
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
rtw_cfg80211_rx_p2p_action_public(padapter, pframe, len);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
/* Do nothing if the driver doesn't enable the P2P function. */
|
/* Do nothing if the driver doesn't enable the P2P function. */
|
||||||
if (rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE) || rtw_p2p_chk_state(pwdinfo, P2P_STATE_IDLE))
|
if (rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE) || rtw_p2p_chk_state(pwdinfo, P2P_STATE_IDLE))
|
||||||
return _SUCCESS;
|
return _SUCCESS;
|
||||||
|
@ -5124,7 +4987,6 @@ static unsigned int on_action_public_p2p(union recv_frame *precv_frame)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
|
||||||
#endif /* CONFIG_P2P */
|
#endif /* CONFIG_P2P */
|
||||||
|
|
||||||
return _SUCCESS;
|
return _SUCCESS;
|
||||||
|
@ -5160,11 +5022,6 @@ static unsigned int on_action_public_default(union recv_frame *precv_frame, u8 a
|
||||||
if (rtw_action_public_decache(precv_frame, token) == _FAIL)
|
if (rtw_action_public_decache(precv_frame, token) == _FAIL)
|
||||||
goto exit;
|
goto exit;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
cnt += sprintf((msg+cnt), "%s(token:%u)", action_public_str(action), token);
|
|
||||||
rtw_cfg80211_rx_action(adapter, pframe, frame_len, msg);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
ret = _SUCCESS;
|
ret = _SUCCESS;
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
|
@ -5236,13 +5093,6 @@ unsigned int OnAction_p2p(_adapter *padapter, union recv_frame *precv_frame)
|
||||||
if (be32_to_cpu(*((__be32 * )(frame_body + 1))) != P2POUI)
|
if (be32_to_cpu(*((__be32 * )(frame_body + 1))) != P2POUI)
|
||||||
return _SUCCESS;
|
return _SUCCESS;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled) {
|
|
||||||
rtw_cfg80211_rx_action_p2p(padapter, pframe, len);
|
|
||||||
return _SUCCESS;
|
|
||||||
} else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
len -= sizeof(struct rtw_ieee80211_hdr_3addr);
|
len -= sizeof(struct rtw_ieee80211_hdr_3addr);
|
||||||
OUI_Subtype = frame_body[5];
|
OUI_Subtype = frame_body[5];
|
||||||
|
|
||||||
|
@ -5259,9 +5109,7 @@ unsigned int OnAction_p2p(_adapter *padapter, union recv_frame *precv_frame)
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
#endif /* CONFIG_P2P */
|
#endif /* CONFIG_P2P */
|
||||||
|
|
||||||
return _SUCCESS;
|
return _SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -5546,34 +5394,6 @@ void issue_beacon(_adapter *padapter, int timeout_ms)
|
||||||
|
|
||||||
remainder_ielen = cur_network->IELength - wps_offset - wpsielen;
|
remainder_ielen = cur_network->IELength - wps_offset - wpsielen;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
if (pmlmepriv->wps_beacon_ie && pmlmepriv->wps_beacon_ie_len>0)
|
|
||||||
{
|
|
||||||
_rtw_memcpy(pframe, cur_network->IEs, wps_offset);
|
|
||||||
pframe += wps_offset;
|
|
||||||
pattrib->pktlen += wps_offset;
|
|
||||||
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wps_beacon_ie, pmlmepriv->wps_beacon_ie_len);
|
|
||||||
pframe += pmlmepriv->wps_beacon_ie_len;
|
|
||||||
pattrib->pktlen += pmlmepriv->wps_beacon_ie_len;
|
|
||||||
|
|
||||||
/* copy remainder_ie to pframe */
|
|
||||||
_rtw_memcpy(pframe, premainder_ie, remainder_ielen);
|
|
||||||
pframe += remainder_ielen;
|
|
||||||
pattrib->pktlen += remainder_ielen;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
_rtw_memcpy(pframe, cur_network->IEs, cur_network->IELength);
|
|
||||||
pframe += cur_network->IELength;
|
|
||||||
pattrib->pktlen += cur_network->IELength;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
pframe_wscie = pframe + wps_offset;
|
pframe_wscie = pframe + wps_offset;
|
||||||
_rtw_memcpy(pframe, cur_network->IEs, wps_offset+wpsielen);
|
_rtw_memcpy(pframe, cur_network->IEs, wps_offset+wpsielen);
|
||||||
pframe += (wps_offset + wpsielen);
|
pframe += (wps_offset + wpsielen);
|
||||||
|
@ -5629,7 +5449,6 @@ void issue_beacon(_adapter *padapter, int timeout_ms)
|
||||||
pframe += remainder_ielen;
|
pframe += remainder_ielen;
|
||||||
pattrib->pktlen += remainder_ielen;
|
pattrib->pktlen += remainder_ielen;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
else
|
else
|
||||||
#endif /* CONFIG_P2P */
|
#endif /* CONFIG_P2P */
|
||||||
{
|
{
|
||||||
|
@ -5663,39 +5482,12 @@ void issue_beacon(_adapter *padapter, int timeout_ms)
|
||||||
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO))
|
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO))
|
||||||
{
|
{
|
||||||
u32 len;
|
u32 len;
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
len = pmlmepriv->p2p_beacon_ie_len;
|
|
||||||
if (pmlmepriv->p2p_beacon_ie && len>0)
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->p2p_beacon_ie, len);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
len = build_beacon_p2p_ie(pwdinfo, pframe);
|
len = build_beacon_p2p_ie(pwdinfo, pframe);
|
||||||
}
|
|
||||||
|
|
||||||
pframe += len;
|
pframe += len;
|
||||||
pattrib->pktlen += len;
|
pattrib->pktlen += len;
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (true == pwdinfo->wfd_info->wfd_enable)
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
len = build_beacon_wfd_ie( pwdinfo, pframe );
|
len = build_beacon_wfd_ie( pwdinfo, pframe );
|
||||||
}
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
else
|
|
||||||
{
|
|
||||||
len = 0;
|
|
||||||
if (pmlmepriv->wfd_beacon_ie && pmlmepriv->wfd_beacon_ie_len>0)
|
|
||||||
{
|
|
||||||
len = pmlmepriv->wfd_beacon_ie_len;
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wfd_beacon_ie, len);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
pframe += len;
|
pframe += len;
|
||||||
pattrib->pktlen += len;
|
pattrib->pktlen += len;
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
|
@ -5954,41 +5746,13 @@ void issue_probersp(_adapter *padapter, unsigned char *da, u8 is_valid_p2p_probe
|
||||||
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO) && is_valid_p2p_probereq)
|
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO) && is_valid_p2p_probereq)
|
||||||
{
|
{
|
||||||
u32 len;
|
u32 len;
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled)
|
|
||||||
{
|
|
||||||
/* if pwdinfo->role == P2P_ROLE_DEVICE will call issue_probersp_p2p() */
|
|
||||||
len = pmlmepriv->p2p_go_probe_resp_ie_len;
|
|
||||||
if (pmlmepriv->p2p_go_probe_resp_ie && len>0)
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->p2p_go_probe_resp_ie, len);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
len = build_probe_resp_p2p_ie(pwdinfo, pframe);
|
len = build_probe_resp_p2p_ie(pwdinfo, pframe);
|
||||||
}
|
|
||||||
|
|
||||||
pframe += len;
|
pframe += len;
|
||||||
pattrib->pktlen += len;
|
pattrib->pktlen += len;
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (true == pwdinfo->wfd_info->wfd_enable)
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
len = build_probe_resp_wfd_ie(pwdinfo, pframe, 0);
|
len = build_probe_resp_wfd_ie(pwdinfo, pframe, 0);
|
||||||
}
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
else
|
|
||||||
{
|
|
||||||
len = 0;
|
|
||||||
if (pmlmepriv->wfd_probe_resp_ie && pmlmepriv->wfd_probe_resp_ie_len>0)
|
|
||||||
{
|
|
||||||
len = pmlmepriv->wfd_probe_resp_ie_len;
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wfd_probe_resp_ie, len);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
pframe += len;
|
pframe += len;
|
||||||
pattrib->pktlen += len;
|
pattrib->pktlen += len;
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
|
@ -6430,7 +6194,6 @@ void issue_asocrsp(_adapter *padapter, unsigned short status, struct sta_info *p
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO) && (pstat->is_p2p_device == true)) {
|
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO) && (pstat->is_p2p_device == true)) {
|
||||||
u32 len;
|
u32 len;
|
||||||
|
|
||||||
|
@ -6439,14 +6202,8 @@ void issue_asocrsp(_adapter *padapter, unsigned short status, struct sta_info *p
|
||||||
pframe += len;
|
pframe += len;
|
||||||
pattrib->pktlen += len;
|
pattrib->pktlen += len;
|
||||||
}
|
}
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO)
|
if (rtw_p2p_chk_role(pwdinfo, P2P_ROLE_GO)) {
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
&& (true == pwdinfo->wfd_info->wfd_enable)
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
)
|
|
||||||
{
|
|
||||||
wfdielen = build_assoc_resp_wfd_ie(pwdinfo, pframe);
|
wfdielen = build_assoc_resp_wfd_ie(pwdinfo, pframe);
|
||||||
pframe += wfdielen;
|
pframe += wfdielen;
|
||||||
pattrib->pktlen += wfdielen;
|
pattrib->pktlen += wfdielen;
|
||||||
|
@ -6683,16 +6440,6 @@ void issue_assocreq(_adapter *padapter)
|
||||||
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled) {
|
|
||||||
if (pmlmepriv->p2p_assoc_req_ie && pmlmepriv->p2p_assoc_req_ie_len > 0) {
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->p2p_assoc_req_ie, pmlmepriv->p2p_assoc_req_ie_len);
|
|
||||||
pframe += pmlmepriv->p2p_assoc_req_ie_len;
|
|
||||||
pattrib->pktlen += pmlmepriv->p2p_assoc_req_ie_len;
|
|
||||||
}
|
|
||||||
} else
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
if (!rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE) && !rtw_p2p_chk_state(pwdinfo, P2P_STATE_IDLE)) {
|
if (!rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE) && !rtw_p2p_chk_state(pwdinfo, P2P_STATE_IDLE)) {
|
||||||
/* Should add the P2P IE in the association request frame. */
|
/* Should add the P2P IE in the association request frame. */
|
||||||
/* P2P OUI */
|
/* P2P OUI */
|
||||||
|
@ -6822,35 +6569,14 @@ void issue_assocreq(_adapter *padapter)
|
||||||
p2pielen += ETH_ALEN;
|
p2pielen += ETH_ALEN;
|
||||||
|
|
||||||
pframe = rtw_set_ie(pframe, _VENDOR_SPECIFIC_IE_, p2pielen, (unsigned char *) p2pie, &pattrib->pktlen );
|
pframe = rtw_set_ie(pframe, _VENDOR_SPECIFIC_IE_, p2pielen, (unsigned char *) p2pie, &pattrib->pktlen );
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
|
||||||
/* wfdielen = build_assoc_req_wfd_ie(pwdinfo, pframe); */
|
|
||||||
/* pframe += wfdielen; */
|
|
||||||
/* pattrib->pktlen += wfdielen; */
|
|
||||||
#endif /* CONFIG_WFD */
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* CONFIG_P2P */
|
#endif /* CONFIG_P2P */
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if ( true == pwdinfo->wfd_info->wfd_enable )
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
{
|
|
||||||
wfdielen = build_assoc_req_wfd_ie(pwdinfo, pframe);
|
wfdielen = build_assoc_req_wfd_ie(pwdinfo, pframe);
|
||||||
pframe += wfdielen;
|
pframe += wfdielen;
|
||||||
pattrib->pktlen += wfdielen;
|
pattrib->pktlen += wfdielen;
|
||||||
}
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
else if (pmlmepriv->wfd_assoc_req_ie != NULL && pmlmepriv->wfd_assoc_req_ie_len>0)
|
|
||||||
{
|
|
||||||
/* WFD IE */
|
|
||||||
_rtw_memcpy(pframe, pmlmepriv->wfd_assoc_req_ie, pmlmepriv->wfd_assoc_req_ie_len);
|
|
||||||
pattrib->pktlen += pmlmepriv->wfd_assoc_req_ie_len;
|
|
||||||
pframe += pmlmepriv->wfd_assoc_req_ie_len;
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
#endif /* CONFIG_WFD */
|
#endif /* CONFIG_WFD */
|
||||||
|
|
||||||
pattrib->last_txcmdsz = pattrib->pktlen;
|
pattrib->last_txcmdsz = pattrib->pktlen;
|
||||||
|
@ -7939,16 +7665,12 @@ void site_survey(_adapter *padapter)
|
||||||
/* switch back to the original channel */
|
/* switch back to the original channel */
|
||||||
/* SelectChannel(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset); */
|
/* SelectChannel(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset); */
|
||||||
|
|
||||||
{
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
if ( rtw_p2p_chk_state(pwdinfo, P2P_STATE_LISTEN) )
|
if ( rtw_p2p_chk_state(pwdinfo, P2P_STATE_LISTEN) )
|
||||||
{
|
{
|
||||||
set_channel_bwmode(padapter, pwdinfo->listen_channel, HAL_PRIME_CHNL_OFFSET_DONT_CARE, HT_CHANNEL_WIDTH_20);
|
set_channel_bwmode(padapter, pwdinfo->listen_channel, HAL_PRIME_CHNL_OFFSET_DONT_CARE, HT_CHANNEL_WIDTH_20);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
set_channel_bwmode(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode);
|
set_channel_bwmode(padapter, pmlmeext->cur_channel, pmlmeext->cur_ch_offset, pmlmeext->cur_bwmode);
|
||||||
}
|
|
||||||
|
|
||||||
/* flush 4-AC Queue after site_survey */
|
/* flush 4-AC Queue after site_survey */
|
||||||
/* val8 = 0; */
|
/* val8 = 0; */
|
||||||
|
@ -9896,14 +9618,6 @@ u8 sitesurvey_cmd_hdl(_adapter *padapter, u8 *pbuf)
|
||||||
Switch_DM_Func(padapter, DYNAMIC_FUNC_DISABLE, false);
|
Switch_DM_Func(padapter, DYNAMIC_FUNC_DISABLE, false);
|
||||||
|
|
||||||
/* config the initial gain under scaning, need to write the BB registers */
|
/* config the initial gain under scaning, need to write the BB registers */
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if ((wdev_to_priv(padapter->rtw_wdev))->p2p_enabled == true)
|
|
||||||
{
|
|
||||||
initialgain = 0x30;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
initialgain = 0x1E;
|
|
||||||
#else /* go through the WEXT interface CONFIG_IOCTL_CFG80211 */
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
if ( rtw_p2p_chk_state( pwdinfo, P2P_STATE_NONE ) )
|
if ( rtw_p2p_chk_state( pwdinfo, P2P_STATE_NONE ) )
|
||||||
initialgain = 0x1E;
|
initialgain = 0x1E;
|
||||||
|
@ -9912,7 +9626,6 @@ u8 sitesurvey_cmd_hdl(_adapter *padapter, u8 *pbuf)
|
||||||
#else /* CONFIG_P2P */
|
#else /* CONFIG_P2P */
|
||||||
initialgain = 0x1E;
|
initialgain = 0x1E;
|
||||||
#endif /* CONFIG_P2P */
|
#endif /* CONFIG_P2P */
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
rtw_hal_set_hwreg(padapter, HW_VAR_INITIAL_GAIN, (u8 *)(&initialgain));
|
rtw_hal_set_hwreg(padapter, HW_VAR_INITIAL_GAIN, (u8 *)(&initialgain));
|
||||||
|
|
||||||
|
|
378
core/rtw_p2p.c
378
core/rtw_p2p.c
|
@ -3183,381 +3183,13 @@ _func_enter_;
|
||||||
_func_exit_;
|
_func_exit_;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
static void ro_ch_handler( _adapter* padapter )
|
|
||||||
{
|
|
||||||
struct cfg80211_wifidirect_info *pcfg80211_wdinfo = &padapter->cfg80211_wdinfo;
|
|
||||||
struct wifidirect_info *pwdinfo = &padapter->wdinfo;
|
|
||||||
struct pwrctrl_priv *pwrpriv = &padapter->pwrctrlpriv;
|
|
||||||
struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
|
|
||||||
_func_enter_;
|
|
||||||
|
|
||||||
{
|
|
||||||
if ( pcfg80211_wdinfo->restore_channel != pmlmeext->cur_channel )
|
|
||||||
{
|
|
||||||
if ( !check_fwstate(&padapter->mlmepriv, _FW_LINKED ) )
|
|
||||||
pmlmeext->cur_channel = pcfg80211_wdinfo->restore_channel;
|
|
||||||
|
|
||||||
set_channel_bwmode(padapter, pmlmeext->cur_channel, HAL_PRIME_CHNL_OFFSET_DONT_CARE, HT_CHANNEL_WIDTH_20);
|
|
||||||
}
|
|
||||||
|
|
||||||
rtw_p2p_set_state(pwdinfo, rtw_p2p_pre_state(pwdinfo));
|
|
||||||
#ifdef CONFIG_DEBUG_CFG80211
|
|
||||||
DBG_88E("%s, role=%d, p2p_state=%d\n", __func__, rtw_p2p_role(pwdinfo), rtw_p2p_state(pwdinfo));
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
pcfg80211_wdinfo->is_ro_ch = false;
|
|
||||||
|
|
||||||
DBG_88E("cfg80211_remain_on_channel_expired\n");
|
|
||||||
|
|
||||||
cfg80211_remain_on_channel_expired(pcfg80211_wdinfo->remain_on_ch_dev,
|
|
||||||
pcfg80211_wdinfo->remain_on_ch_cookie,
|
|
||||||
&pcfg80211_wdinfo->remain_on_ch_channel,
|
|
||||||
pcfg80211_wdinfo->remain_on_ch_type, GFP_KERNEL);
|
|
||||||
_func_exit_;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void ro_ch_timer_process (void *FunctionContext)
|
|
||||||
{
|
|
||||||
_adapter *adapter = (_adapter *)FunctionContext;
|
|
||||||
struct rtw_wdev_priv *pwdev_priv = wdev_to_priv(adapter->rtw_wdev);
|
|
||||||
|
|
||||||
p2p_protocol_wk_cmd( adapter, P2P_RO_CH_WK);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void rtw_cfg80211_adjust_p2pie_channel(_adapter *padapter, const u8 *frame_body, u32 len)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
|
||||||
void rtw_append_wfd_ie(_adapter *padapter, u8 *buf, u32* len)
|
|
||||||
{
|
|
||||||
unsigned char *frame_body;
|
|
||||||
u8 category, action, OUI_Subtype, dialogToken=0;
|
|
||||||
u32 wfdielen = 0;
|
|
||||||
struct rtw_wdev_priv *pwdev_priv = wdev_to_priv(padapter->rtw_wdev);
|
|
||||||
|
|
||||||
frame_body = (unsigned char *)(buf + sizeof(struct rtw_ieee80211_hdr_3addr));
|
|
||||||
category = frame_body[0];
|
|
||||||
|
|
||||||
if (category == RTW_WLAN_CATEGORY_PUBLIC)
|
|
||||||
{
|
|
||||||
action = frame_body[1];
|
|
||||||
if (action == ACT_PUBLIC_VENDOR
|
|
||||||
&& _rtw_memcmp(frame_body+2, P2P_OUI, 4) == true
|
|
||||||
)
|
|
||||||
{
|
|
||||||
OUI_Subtype = frame_body[6];
|
|
||||||
dialogToken = frame_body[7];
|
|
||||||
switch ( OUI_Subtype )/* OUI Subtype */
|
|
||||||
{
|
|
||||||
case P2P_GO_NEGO_REQ:
|
|
||||||
{
|
|
||||||
wfdielen = build_nego_req_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_GO_NEGO_RESP:
|
|
||||||
{
|
|
||||||
wfdielen = build_nego_resp_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_GO_NEGO_CONF:
|
|
||||||
{
|
|
||||||
wfdielen = build_nego_confirm_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_INVIT_REQ:
|
|
||||||
{
|
|
||||||
wfdielen = build_invitation_req_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_INVIT_RESP:
|
|
||||||
{
|
|
||||||
wfdielen = build_invitation_resp_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_DEVDISC_REQ:
|
|
||||||
break;
|
|
||||||
case P2P_DEVDISC_RESP:
|
|
||||||
|
|
||||||
break;
|
|
||||||
case P2P_PROVISION_DISC_REQ:
|
|
||||||
{
|
|
||||||
wfdielen = build_provdisc_req_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_PROVISION_DISC_RESP:
|
|
||||||
{
|
|
||||||
wfdielen = build_provdisc_resp_wfd_ie( &padapter->wdinfo, buf + ( *len ) );
|
|
||||||
(*len) += wfdielen;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default:
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
else if (category == RTW_WLAN_CATEGORY_P2P)
|
|
||||||
{
|
|
||||||
OUI_Subtype = frame_body[5];
|
|
||||||
dialogToken = frame_body[6];
|
|
||||||
|
|
||||||
#ifdef CONFIG_DEBUG_CFG80211
|
|
||||||
DBG_88E("ACTION_CATEGORY_P2P: OUI=0x%x, OUI_Subtype=%d, dialogToken=%d\n",
|
|
||||||
cpu_to_be32( *( ( u32* ) ( frame_body + 1 ) ) ), OUI_Subtype, dialogToken);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
switch (OUI_Subtype)
|
|
||||||
{
|
|
||||||
case P2P_NOTICE_OF_ABSENCE:
|
|
||||||
|
|
||||||
break;
|
|
||||||
case P2P_PRESENCE_REQUEST:
|
|
||||||
|
|
||||||
break;
|
|
||||||
case P2P_PRESENCE_RESPONSE:
|
|
||||||
|
|
||||||
break;
|
|
||||||
case P2P_GO_DISC_REQUEST:
|
|
||||||
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
DBG_88E("%s, action frame category=%d\n", __func__, category);
|
|
||||||
/* is_p2p_frame = (-1); */
|
|
||||||
}
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int rtw_p2p_check_frames(_adapter *padapter, const u8 *buf, u32 len, u8 tx)
|
|
||||||
{
|
|
||||||
int is_p2p_frame = (-1);
|
|
||||||
unsigned char *frame_body;
|
|
||||||
u8 category, action, OUI_Subtype, dialogToken=0;
|
|
||||||
u8 *p2p_ie = NULL;
|
|
||||||
uint p2p_ielen = 0;
|
|
||||||
struct rtw_wdev_priv *pwdev_priv = wdev_to_priv(padapter->rtw_wdev);
|
|
||||||
|
|
||||||
frame_body = (unsigned char *)(buf + sizeof(struct rtw_ieee80211_hdr_3addr));
|
|
||||||
category = frame_body[0];
|
|
||||||
/* just for check */
|
|
||||||
if (category == RTW_WLAN_CATEGORY_PUBLIC)
|
|
||||||
{
|
|
||||||
action = frame_body[1];
|
|
||||||
if (action == ACT_PUBLIC_VENDOR
|
|
||||||
&& _rtw_memcmp(frame_body+2, P2P_OUI, 4) == true
|
|
||||||
)
|
|
||||||
{
|
|
||||||
OUI_Subtype = frame_body[6];
|
|
||||||
dialogToken = frame_body[7];
|
|
||||||
is_p2p_frame = OUI_Subtype;
|
|
||||||
#ifdef CONFIG_DEBUG_CFG80211
|
|
||||||
DBG_88E("ACTION_CATEGORY_PUBLIC: ACT_PUBLIC_VENDOR, OUI=0x%x, OUI_Subtype=%d, dialogToken=%d\n",
|
|
||||||
cpu_to_be32( *( ( u32* ) ( frame_body + 2 ) ) ), OUI_Subtype, dialogToken);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
p2p_ie = rtw_get_p2p_ie(
|
|
||||||
(u8 *)buf+sizeof(struct rtw_ieee80211_hdr_3addr)+_PUBLIC_ACTION_IE_OFFSET_,
|
|
||||||
len-sizeof(struct rtw_ieee80211_hdr_3addr)-_PUBLIC_ACTION_IE_OFFSET_,
|
|
||||||
NULL, &p2p_ielen);
|
|
||||||
|
|
||||||
switch ( OUI_Subtype )/* OUI Subtype */
|
|
||||||
{
|
|
||||||
u8 *cont;
|
|
||||||
uint cont_len;
|
|
||||||
case P2P_GO_NEGO_REQ:
|
|
||||||
DBG_88E("RTW_%s:P2P_GO_NEGO_REQ, dialogToken=%d\n", (tx==true)?"Tx":"Rx", dialogToken);
|
|
||||||
|
|
||||||
if (tx)
|
|
||||||
{
|
|
||||||
#ifdef CONFIG_DRV_ISSUE_PROV_REQ /* IOT FOR S2 */
|
|
||||||
if (pwdev_priv->provdisc_req_issued == false)
|
|
||||||
rtw_cfg80211_issue_p2p_provision_request(padapter, buf, len);
|
|
||||||
#endif /* CONFIG_DRV_ISSUE_PROV_REQ */
|
|
||||||
}
|
|
||||||
|
|
||||||
break;
|
|
||||||
case P2P_GO_NEGO_RESP:
|
|
||||||
cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_STATUS, NULL, &cont_len);
|
|
||||||
DBG_88E("RTW_%s:P2P_GO_NEGO_RESP, dialogToken=%d, status:%d\n", (tx==true)?"Tx":"Rx", dialogToken, cont?*cont:-1);
|
|
||||||
|
|
||||||
if (!tx)
|
|
||||||
pwdev_priv->provdisc_req_issued = false;
|
|
||||||
break;
|
|
||||||
case P2P_GO_NEGO_CONF:
|
|
||||||
cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_STATUS, NULL, &cont_len);
|
|
||||||
DBG_88E("RTW_%s:P2P_GO_NEGO_CONF, dialogToken=%d, status:%d\n", (tx==true)?"Tx":"Rx", dialogToken, cont?*cont:-1);
|
|
||||||
break;
|
|
||||||
case P2P_INVIT_REQ:
|
|
||||||
{
|
|
||||||
struct rtw_wdev_invit_info* invit_info = &pwdev_priv->invit_info;
|
|
||||||
int flags = -1;
|
|
||||||
int op_ch = 0;
|
|
||||||
|
|
||||||
if ((cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_INVITATION_FLAGS, NULL, &cont_len)))
|
|
||||||
flags = *cont;
|
|
||||||
if ((cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_OPERATING_CH, NULL, &cont_len)))
|
|
||||||
op_ch = *(cont+4);
|
|
||||||
|
|
||||||
if (invit_info->token != dialogToken)
|
|
||||||
rtw_wdev_invit_info_init(invit_info);
|
|
||||||
|
|
||||||
invit_info->token = dialogToken;
|
|
||||||
invit_info->flags = (flags==-1) ? 0x0 : flags;
|
|
||||||
invit_info->req_op_ch= op_ch;
|
|
||||||
|
|
||||||
DBG_88E("RTW_%s:P2P_INVIT_REQ, dialogToken=%d, flags:0x%02x, op_ch:%d\n", (tx==true)?"Tx":"Rx", dialogToken, flags, op_ch);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_INVIT_RESP:
|
|
||||||
{
|
|
||||||
struct rtw_wdev_invit_info* invit_info = &pwdev_priv->invit_info;
|
|
||||||
int status = -1;
|
|
||||||
int op_ch = 0;
|
|
||||||
|
|
||||||
if ((cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_STATUS, NULL, &cont_len)))
|
|
||||||
status = *cont;
|
|
||||||
if ((cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_OPERATING_CH, NULL, &cont_len)))
|
|
||||||
op_ch = *(cont+4);
|
|
||||||
|
|
||||||
if (invit_info->token != dialogToken) {
|
|
||||||
rtw_wdev_invit_info_init(invit_info);
|
|
||||||
} else {
|
|
||||||
invit_info->token = 0;
|
|
||||||
invit_info->status = (status==-1) ? 0xff : status;
|
|
||||||
invit_info->rsp_op_ch= op_ch;
|
|
||||||
}
|
|
||||||
|
|
||||||
DBG_88E("RTW_%s:P2P_INVIT_RESP, dialogToken=%d, status:%d, op_ch:%d\n", (tx==true)?"Tx":"Rx", dialogToken, status, op_ch);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case P2P_DEVDISC_REQ:
|
|
||||||
DBG_88E("RTW_%s:P2P_DEVDISC_REQ, dialogToken=%d\n", (tx==true)?"Tx":"Rx", dialogToken);
|
|
||||||
break;
|
|
||||||
case P2P_DEVDISC_RESP:
|
|
||||||
cont = rtw_get_p2p_attr_content(p2p_ie, p2p_ielen, P2P_ATTR_STATUS, NULL, &cont_len);
|
|
||||||
DBG_88E("RTW_%s:P2P_DEVDISC_RESP, dialogToken=%d, status:%d\n", (tx==true)?"Tx":"Rx", dialogToken, cont?*cont:-1);
|
|
||||||
break;
|
|
||||||
case P2P_PROVISION_DISC_REQ:
|
|
||||||
{
|
|
||||||
size_t frame_body_len = len - sizeof(struct rtw_ieee80211_hdr_3addr);
|
|
||||||
u8 *p2p_ie;
|
|
||||||
uint p2p_ielen = 0;
|
|
||||||
uint contentlen = 0;
|
|
||||||
|
|
||||||
DBG_88E("RTW_%s:P2P_PROVISION_DISC_REQ, dialogToken=%d\n", (tx==true)?"Tx":"Rx", dialogToken);
|
|
||||||
|
|
||||||
/* if (tx) */
|
|
||||||
{
|
|
||||||
pwdev_priv->provdisc_req_issued = false;
|
|
||||||
|
|
||||||
if ( (p2p_ie=rtw_get_p2p_ie( frame_body + _PUBLIC_ACTION_IE_OFFSET_, frame_body_len - _PUBLIC_ACTION_IE_OFFSET_, NULL, &p2p_ielen)))
|
|
||||||
{
|
|
||||||
|
|
||||||
if (rtw_get_p2p_attr_content( p2p_ie, p2p_ielen, P2P_ATTR_GROUP_ID, NULL, &contentlen))
|
|
||||||
{
|
|
||||||
pwdev_priv->provdisc_req_issued = false;/* case: p2p_client join p2p GO */
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
#ifdef CONFIG_DEBUG_CFG80211
|
|
||||||
DBG_88E("provdisc_req_issued is true\n");
|
|
||||||
#endif /* CONFIG_DEBUG_CFG80211 */
|
|
||||||
pwdev_priv->provdisc_req_issued = true;/* case: p2p_devices connection before Nego req. */
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case P2P_PROVISION_DISC_RESP:
|
|
||||||
DBG_88E("RTW_%s:P2P_PROVISION_DISC_RESP, dialogToken=%d\n", (tx==true)?"Tx":"Rx", dialogToken);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
DBG_88E("RTW_%s:OUI_Subtype=%d, dialogToken=%d\n", (tx==true)?"Tx":"Rx", OUI_Subtype, dialogToken);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
else if (category == RTW_WLAN_CATEGORY_P2P)
|
|
||||||
{
|
|
||||||
OUI_Subtype = frame_body[5];
|
|
||||||
dialogToken = frame_body[6];
|
|
||||||
|
|
||||||
#ifdef CONFIG_DEBUG_CFG80211
|
|
||||||
DBG_88E("ACTION_CATEGORY_P2P: OUI=0x%x, OUI_Subtype=%d, dialogToken=%d\n",
|
|
||||||
cpu_to_be32( *( ( u32* ) ( frame_body + 1 ) ) ), OUI_Subtype, dialogToken);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
is_p2p_frame = OUI_Subtype;
|
|
||||||
|
|
||||||
switch (OUI_Subtype)
|
|
||||||
{
|
|
||||||
case P2P_NOTICE_OF_ABSENCE:
|
|
||||||
DBG_88E("RTW_%s:P2P_NOTICE_OF_ABSENCE, dialogToken=%d\n", (tx==true)?"TX":"RX", dialogToken);
|
|
||||||
break;
|
|
||||||
case P2P_PRESENCE_REQUEST:
|
|
||||||
DBG_88E("RTW_%s:P2P_PRESENCE_REQUEST, dialogToken=%d\n", (tx==true)?"TX":"RX", dialogToken);
|
|
||||||
break;
|
|
||||||
case P2P_PRESENCE_RESPONSE:
|
|
||||||
DBG_88E("RTW_%s:P2P_PRESENCE_RESPONSE, dialogToken=%d\n", (tx==true)?"TX":"RX", dialogToken);
|
|
||||||
break;
|
|
||||||
case P2P_GO_DISC_REQUEST:
|
|
||||||
DBG_88E("RTW_%s:P2P_GO_DISC_REQUEST, dialogToken=%d\n", (tx==true)?"TX":"RX", dialogToken);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
DBG_88E("RTW_%s:OUI_Subtype=%d, dialogToken=%d\n", (tx==true)?"TX":"RX", OUI_Subtype, dialogToken);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
DBG_88E("RTW_%s:action frame category=%d\n", (tx==true)?"TX":"RX", category);
|
|
||||||
/* is_p2p_frame = (-1); */
|
|
||||||
}
|
|
||||||
|
|
||||||
return is_p2p_frame;
|
|
||||||
}
|
|
||||||
|
|
||||||
void rtw_init_cfg80211_wifidirect_info( _adapter* padapter)
|
|
||||||
{
|
|
||||||
struct cfg80211_wifidirect_info *pcfg80211_wdinfo = &padapter->cfg80211_wdinfo;
|
|
||||||
|
|
||||||
_rtw_memset(pcfg80211_wdinfo, 0x00, sizeof(struct cfg80211_wifidirect_info) );
|
|
||||||
|
|
||||||
_init_timer( &pcfg80211_wdinfo->remain_on_ch_timer, padapter->pnetdev, ro_ch_timer_process, padapter );
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
void p2p_protocol_wk_hdl(_adapter *padapter, int intCmdType)
|
void p2p_protocol_wk_hdl(_adapter *padapter, int intCmdType)
|
||||||
{
|
{
|
||||||
struct wifidirect_info *pwdinfo= &(padapter->wdinfo);
|
struct wifidirect_info *pwdinfo= &(padapter->wdinfo);
|
||||||
|
|
||||||
_func_enter_;
|
_func_enter_;
|
||||||
|
|
||||||
switch (intCmdType)
|
switch (intCmdType) {
|
||||||
{
|
|
||||||
case P2P_FIND_PHASE_WK:
|
case P2P_FIND_PHASE_WK:
|
||||||
find_phase_handler( padapter );
|
find_phase_handler( padapter );
|
||||||
break;
|
break;
|
||||||
|
@ -3573,14 +3205,6 @@ _func_enter_;
|
||||||
case P2P_PRE_TX_NEGOREQ_PROCESS_WK:
|
case P2P_PRE_TX_NEGOREQ_PROCESS_WK:
|
||||||
pre_tx_negoreq_handler( padapter );
|
pre_tx_negoreq_handler( padapter );
|
||||||
break;
|
break;
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
case P2P_RO_CH_WK:
|
|
||||||
{
|
|
||||||
ro_ch_handler( padapter );
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
#endif /* CONFIG_IOCTL_CFG80211 */
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_func_exit_;
|
_func_exit_;
|
||||||
|
|
|
@ -137,9 +137,6 @@ static bool rtw_pwr_unassociated_idle(_adapter *adapter)
|
||||||
struct mlme_priv *pmlmepriv = &(adapter->mlmepriv);
|
struct mlme_priv *pmlmepriv = &(adapter->mlmepriv);
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
struct wifidirect_info *pwdinfo = &(adapter->wdinfo);
|
struct wifidirect_info *pwdinfo = &(adapter->wdinfo);
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
struct cfg80211_wifidirect_info *pcfg80211_wdinfo = &adapter->cfg80211_wdinfo;
|
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
|
@ -153,9 +150,7 @@ static bool rtw_pwr_unassociated_idle(_adapter *adapter)
|
||||||
|| check_fwstate(pmlmepriv, WIFI_UNDER_LINKING|WIFI_UNDER_WPS)
|
|| check_fwstate(pmlmepriv, WIFI_UNDER_LINKING|WIFI_UNDER_WPS)
|
||||||
|| check_fwstate(pmlmepriv, WIFI_AP_STATE)
|
|| check_fwstate(pmlmepriv, WIFI_AP_STATE)
|
||||||
|| check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE|WIFI_ADHOC_STATE)
|
|| check_fwstate(pmlmepriv, WIFI_ADHOC_MASTER_STATE|WIFI_ADHOC_STATE)
|
||||||
#if defined(CONFIG_P2P) && defined(CONFIG_IOCTL_CFG80211) && defined(CONFIG_P2P_IPS)
|
#if defined(CONFIG_P2P)
|
||||||
|| pcfg80211_wdinfo->is_ro_ch
|
|
||||||
#elif defined(CONFIG_P2P)
|
|
||||||
|| !rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE)
|
|| !rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE)
|
||||||
#endif
|
#endif
|
||||||
) {
|
) {
|
||||||
|
@ -167,18 +162,13 @@ static bool rtw_pwr_unassociated_idle(_adapter *adapter)
|
||||||
struct mlme_priv *b_pmlmepriv = &(buddy->mlmepriv);
|
struct mlme_priv *b_pmlmepriv = &(buddy->mlmepriv);
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
struct wifidirect_info *b_pwdinfo = &(buddy->wdinfo);
|
struct wifidirect_info *b_pwdinfo = &(buddy->wdinfo);
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
struct cfg80211_wifidirect_info *b_pcfg80211_wdinfo = &buddy->cfg80211_wdinfo;
|
|
||||||
#endif
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (check_fwstate(b_pmlmepriv, WIFI_ASOC_STATE|WIFI_SITE_MONITOR)
|
if (check_fwstate(b_pmlmepriv, WIFI_ASOC_STATE|WIFI_SITE_MONITOR)
|
||||||
|| check_fwstate(b_pmlmepriv, WIFI_UNDER_LINKING|WIFI_UNDER_WPS)
|
|| check_fwstate(b_pmlmepriv, WIFI_UNDER_LINKING|WIFI_UNDER_WPS)
|
||||||
|| check_fwstate(b_pmlmepriv, WIFI_AP_STATE)
|
|| check_fwstate(b_pmlmepriv, WIFI_AP_STATE)
|
||||||
|| check_fwstate(b_pmlmepriv, WIFI_ADHOC_MASTER_STATE|WIFI_ADHOC_STATE)
|
|| check_fwstate(b_pmlmepriv, WIFI_ADHOC_MASTER_STATE|WIFI_ADHOC_STATE)
|
||||||
#if defined(CONFIG_P2P) && defined(CONFIG_IOCTL_CFG80211) && defined(CONFIG_P2P_IPS)
|
#if defined(CONFIG_P2P)
|
||||||
|| b_pcfg80211_wdinfo->is_ro_ch
|
|
||||||
#elif defined(CONFIG_P2P)
|
|
||||||
|| !rtw_p2p_chk_state(b_pwdinfo, P2P_STATE_NONE)
|
|| !rtw_p2p_chk_state(b_pwdinfo, P2P_STATE_NONE)
|
||||||
#endif
|
#endif
|
||||||
) {
|
) {
|
||||||
|
@ -426,11 +416,6 @@ u8 PS_RDY_CHECK(_adapter * padapter)
|
||||||
DBG_88E("Group handshake still in progress !!!\n");
|
DBG_88E("Group handshake still in progress !!!\n");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (!rtw_cfg80211_pwr_mgmt(padapter))
|
|
||||||
return false;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -32,16 +32,10 @@
|
||||||
|
|
||||||
#define CONFIG_RTL8188E
|
#define CONFIG_RTL8188E
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#define CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER
|
|
||||||
#define CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Internal General Config
|
* Internal General Config
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#define CONFIG_EMBEDDED_FWIMG
|
#define CONFIG_EMBEDDED_FWIMG
|
||||||
|
|
||||||
#define CONFIG_80211N_HT
|
#define CONFIG_80211N_HT
|
||||||
|
|
|
@ -76,10 +76,6 @@ typedef struct _ADAPTER _adapter, ADAPTER,*PADAPTER;
|
||||||
#include <rtw_mp.h>
|
#include <rtw_mp.h>
|
||||||
|
|
||||||
#include <rtw_br_ext.h>
|
#include <rtw_br_ext.h>
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#include "ioctl_cfg80211.h"
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
#define SPEC_DEV_ID_NONE BIT(0)
|
#define SPEC_DEV_ID_NONE BIT(0)
|
||||||
#define SPEC_DEV_ID_DISABLE_HT BIT(1)
|
#define SPEC_DEV_ID_DISABLE_HT BIT(1)
|
||||||
#define SPEC_DEV_ID_ENABLE_PS BIT(2)
|
#define SPEC_DEV_ID_ENABLE_PS BIT(2)
|
||||||
|
@ -336,12 +332,6 @@ struct _ADAPTER{
|
||||||
struct hostapd_priv *phostapdpriv;
|
struct hostapd_priv *phostapdpriv;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#ifdef CONFIG_P2P
|
|
||||||
struct cfg80211_wifidirect_info cfg80211_wdinfo;
|
|
||||||
#endif //CONFIG_P2P
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
struct wifidirect_info wdinfo;
|
struct wifidirect_info wdinfo;
|
||||||
#endif //CONFIG_P2P
|
#endif //CONFIG_P2P
|
||||||
|
@ -388,10 +378,6 @@ struct _ADAPTER{
|
||||||
struct iw_statistics iwstats;
|
struct iw_statistics iwstats;
|
||||||
struct proc_dir_entry *dir_dev;// for proc directory
|
struct proc_dir_entry *dir_dev;// for proc directory
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
struct wireless_dev *rtw_wdev;
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
int net_closed;
|
int net_closed;
|
||||||
u8 bFWReady;
|
u8 bFWReady;
|
||||||
u8 bBTFWReady;
|
u8 bBTFWReady;
|
||||||
|
|
|
@ -20,11 +20,6 @@
|
||||||
#ifndef __IOCTL_CFG80211_H__
|
#ifndef __IOCTL_CFG80211_H__
|
||||||
#define __IOCTL_CFG80211_H__
|
#define __IOCTL_CFG80211_H__
|
||||||
|
|
||||||
|
|
||||||
#if defined(RTW_USE_CFG80211_STA_EVENT)
|
|
||||||
#undef CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER
|
|
||||||
#endif
|
|
||||||
|
|
||||||
struct rtw_wdev_invit_info {
|
struct rtw_wdev_invit_info {
|
||||||
u8 token;
|
u8 token;
|
||||||
u8 flags;
|
u8 flags;
|
||||||
|
|
|
@ -63,11 +63,6 @@
|
||||||
#include <linux/ip.h>
|
#include <linux/ip.h>
|
||||||
#include <linux/kthread.h>
|
#include <linux/kthread.h>
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#include <net/ieee80211_radiotap.h>
|
|
||||||
#include <net/cfg80211.h>
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
#include <linux/usb.h>
|
#include <linux/usb.h>
|
||||||
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,21))
|
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,21))
|
||||||
#include <linux/usb_ch9.h>
|
#include <linux/usb_ch9.h>
|
||||||
|
|
|
@ -234,18 +234,6 @@ struct scan_limit_info{
|
||||||
u8 operation_ch[2]; // Store the operation channel of invitation request frame
|
u8 operation_ch[2]; // Store the operation channel of invitation request frame
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
struct cfg80211_wifidirect_info{
|
|
||||||
_timer remain_on_ch_timer;
|
|
||||||
u8 restore_channel;
|
|
||||||
struct ieee80211_channel remain_on_ch_channel;
|
|
||||||
enum nl80211_channel_type remain_on_ch_type;
|
|
||||||
u64 remain_on_ch_cookie;
|
|
||||||
struct net_device *remain_on_ch_dev;
|
|
||||||
bool is_ro_ch;
|
|
||||||
};
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
struct wifidirect_info{
|
struct wifidirect_info{
|
||||||
_adapter* padapter;
|
_adapter* padapter;
|
||||||
_timer find_phase_timer;
|
_timer find_phase_timer;
|
||||||
|
@ -392,11 +380,6 @@ struct mlme_priv {
|
||||||
_timer scan_to_timer; // driver itself handles scan_timeout status.
|
_timer scan_to_timer; // driver itself handles scan_timeout status.
|
||||||
u32 scan_start_time; // used to evaluate the time spent in scanning
|
u32 scan_start_time; // used to evaluate the time spent in scanning
|
||||||
|
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
_timer set_scan_deny_timer;
|
|
||||||
ATOMIC_T set_scan_deny; //0: allowed, 1: deny
|
|
||||||
#endif
|
|
||||||
|
|
||||||
struct qos_priv qospriv;
|
struct qos_priv qospriv;
|
||||||
|
|
||||||
#ifdef CONFIG_80211N_HT
|
#ifdef CONFIG_80211N_HT
|
||||||
|
@ -464,12 +447,11 @@ struct mlme_priv {
|
||||||
u8 *wps_beacon_ie;
|
u8 *wps_beacon_ie;
|
||||||
//u8 *wps_probe_req_ie;
|
//u8 *wps_probe_req_ie;
|
||||||
u8 *wps_probe_resp_ie;
|
u8 *wps_probe_resp_ie;
|
||||||
u8 *wps_assoc_resp_ie; // for CONFIG_IOCTL_CFG80211, this IE could include p2p ie / wfd ie
|
u8 *wps_assoc_resp_ie;
|
||||||
|
|
||||||
u32 wps_beacon_ie_len;
|
u32 wps_beacon_ie_len;
|
||||||
//u32 wps_probe_req_ie_len;
|
|
||||||
u32 wps_probe_resp_ie_len;
|
u32 wps_probe_resp_ie_len;
|
||||||
u32 wps_assoc_resp_ie_len; // for CONFIG_IOCTL_CFG80211, this IE len could include p2p ie / wfd ie
|
u32 wps_assoc_resp_ie_len;
|
||||||
|
|
||||||
u8 *p2p_beacon_ie;
|
u8 *p2p_beacon_ie;
|
||||||
u8 *p2p_probe_req_ie;
|
u8 *p2p_probe_req_ie;
|
||||||
|
@ -482,41 +464,12 @@ struct mlme_priv {
|
||||||
u32 p2p_probe_resp_ie_len;
|
u32 p2p_probe_resp_ie_len;
|
||||||
u32 p2p_go_probe_resp_ie_len; //for GO
|
u32 p2p_go_probe_resp_ie_len; //for GO
|
||||||
u32 p2p_assoc_req_ie_len;
|
u32 p2p_assoc_req_ie_len;
|
||||||
/*
|
|
||||||
#if defined(CONFIG_P2P) && defined(CONFIG_IOCTL_CFG80211)
|
|
||||||
//u8 *wps_p2p_beacon_ie;
|
|
||||||
u8 *p2p_beacon_ie;
|
|
||||||
u8 *wps_p2p_probe_resp_ie;
|
|
||||||
u8 *wps_p2p_assoc_resp_ie;
|
|
||||||
//u32 wps_p2p_beacon_ie_len;
|
|
||||||
u32 p2p_beacon_ie_len;
|
|
||||||
u32 wps_p2p_probe_resp_ie_len;
|
|
||||||
u32 wps_p2p_assoc_resp_ie_len;
|
|
||||||
#endif
|
|
||||||
*/
|
|
||||||
|
|
||||||
_lock bcn_update_lock;
|
_lock bcn_update_lock;
|
||||||
u8 update_bcn;
|
u8 update_bcn;
|
||||||
|
|
||||||
|
|
||||||
#endif //#if defined (CONFIG_AP_MODE)
|
#endif //#if defined (CONFIG_AP_MODE)
|
||||||
|
|
||||||
#if defined(CONFIG_WFD) && defined(CONFIG_IOCTL_CFG80211)
|
|
||||||
|
|
||||||
u8 *wfd_beacon_ie;
|
|
||||||
u8 *wfd_probe_req_ie;
|
|
||||||
u8 *wfd_probe_resp_ie;
|
|
||||||
u8 *wfd_go_probe_resp_ie; //for GO
|
|
||||||
u8 *wfd_assoc_req_ie;
|
|
||||||
|
|
||||||
u32 wfd_beacon_ie_len;
|
|
||||||
u32 wfd_probe_req_ie_len;
|
|
||||||
u32 wfd_probe_resp_ie_len;
|
|
||||||
u32 wfd_go_probe_resp_ie_len; //for GO
|
|
||||||
u32 wfd_assoc_req_ie_len;
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_FTP_PROTECT
|
#ifdef CONFIG_FTP_PROTECT
|
||||||
u8 ftp_lock_flag;
|
u8 ftp_lock_flag;
|
||||||
#endif //CONFIG_FTP_PROTECT
|
#endif //CONFIG_FTP_PROTECT
|
||||||
|
@ -682,17 +635,10 @@ extern void _rtw_join_timeout_handler(_adapter *adapter);
|
||||||
extern void rtw_scan_timeout_handler(_adapter *adapter);
|
extern void rtw_scan_timeout_handler(_adapter *adapter);
|
||||||
|
|
||||||
extern void rtw_dynamic_check_timer_handlder(_adapter *adapter);
|
extern void rtw_dynamic_check_timer_handlder(_adapter *adapter);
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
bool rtw_is_scan_deny(_adapter *adapter);
|
|
||||||
void rtw_clear_scan_deny(_adapter *adapter);
|
|
||||||
void rtw_set_scan_deny_timer_hdl(_adapter *adapter);
|
|
||||||
void rtw_set_scan_deny(_adapter *adapter, u32 ms);
|
|
||||||
#else
|
|
||||||
#define rtw_is_scan_deny(adapter) false
|
#define rtw_is_scan_deny(adapter) false
|
||||||
#define rtw_clear_scan_deny(adapter) do {} while (0)
|
#define rtw_clear_scan_deny(adapter) do {} while (0)
|
||||||
#define rtw_set_scan_deny_timer_hdl(adapter) do {} while (0)
|
#define rtw_set_scan_deny_timer_hdl(adapter) do {} while (0)
|
||||||
#define rtw_set_scan_deny(adapter, ms) do {} while (0)
|
#define rtw_set_scan_deny(adapter, ms) do {} while (0)
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
extern int _rtw_init_mlme_priv(_adapter *padapter);
|
extern int _rtw_init_mlme_priv(_adapter *padapter);
|
||||||
|
|
|
@ -59,12 +59,6 @@ void process_p2p_ps_ie(PADAPTER padapter, u8 *IEs, u32 IELength);
|
||||||
void p2p_ps_wk_hdl(_adapter *padapter, u8 p2p_ps_state);
|
void p2p_ps_wk_hdl(_adapter *padapter, u8 p2p_ps_state);
|
||||||
u8 p2p_ps_wk_cmd(_adapter*padapter, u8 p2p_ps_state, u8 enqueue);
|
u8 p2p_ps_wk_cmd(_adapter*padapter, u8 p2p_ps_state, u8 enqueue);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
void rtw_init_cfg80211_wifidirect_info( _adapter* padapter);
|
|
||||||
int rtw_p2p_check_frames(_adapter *padapter, const u8 *buf, u32 len, u8 tx);
|
|
||||||
void rtw_append_wfd_ie(_adapter *padapter, u8 *buf, u32 *len);
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
void reset_global_wifidirect_info( _adapter* padapter );
|
void reset_global_wifidirect_info( _adapter* padapter );
|
||||||
int rtw_init_wifi_display_info(_adapter* padapter);
|
int rtw_init_wifi_display_info(_adapter* padapter);
|
||||||
void rtw_init_wifidirect_timers(_adapter* padapter);
|
void rtw_init_wifidirect_timers(_adapter* padapter);
|
||||||
|
|
|
@ -220,11 +220,6 @@ struct sta_info {
|
||||||
|
|
||||||
#endif // CONFIG_AP_MODE
|
#endif // CONFIG_AP_MODE
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
u8 *passoc_req;
|
|
||||||
u32 assoc_req_len;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
//for DM
|
//for DM
|
||||||
RSSI_STA rssi_stat;
|
RSSI_STA rssi_stat;
|
||||||
|
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -148,15 +148,11 @@ static void indicate_wx_custom_event(_adapter *padapter, char *msg)
|
||||||
wrqu.data.length = strlen(msg);
|
wrqu.data.length = strlen(msg);
|
||||||
|
|
||||||
DBG_88E("%s %s\n", __func__, buff);
|
DBG_88E("%s %s\n", __func__, buff);
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, IWEVCUSTOM, &wrqu, buff);
|
wireless_send_event(padapter->pnetdev, IWEVCUSTOM, &wrqu, buff);
|
||||||
#endif
|
|
||||||
|
|
||||||
rtw_mfree(buff, IW_CUSTOM_MAX+1);
|
rtw_mfree(buff, IW_CUSTOM_MAX+1);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void request_wps_pbc_event(_adapter *padapter)
|
static void request_wps_pbc_event(_adapter *padapter)
|
||||||
{
|
{
|
||||||
u8 *buff, *p;
|
u8 *buff, *p;
|
||||||
|
@ -181,9 +177,7 @@ static void request_wps_pbc_event(_adapter *padapter)
|
||||||
|
|
||||||
DBG_88E("%s\n", __func__);
|
DBG_88E("%s\n", __func__);
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, IWEVCUSTOM, &wrqu, buff);
|
wireless_send_event(padapter->pnetdev, IWEVCUSTOM, &wrqu, buff);
|
||||||
#endif
|
|
||||||
|
|
||||||
if (buff)
|
if (buff)
|
||||||
{
|
{
|
||||||
|
@ -200,10 +194,7 @@ void indicate_wx_scan_complete_event(_adapter *padapter)
|
||||||
|
|
||||||
_rtw_memset(&wrqu, 0, sizeof(union iwreq_data));
|
_rtw_memset(&wrqu, 0, sizeof(union iwreq_data));
|
||||||
|
|
||||||
//DBG_88E("+rtw_indicate_wx_scan_complete_event\n");
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, SIOCGIWSCAN, &wrqu, NULL);
|
wireless_send_event(padapter->pnetdev, SIOCGIWSCAN, &wrqu, NULL);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -219,9 +210,7 @@ void rtw_indicate_wx_assoc_event(_adapter *padapter)
|
||||||
_rtw_memcpy(wrqu.ap_addr.sa_data, pmlmepriv->cur_network.network.MacAddress, ETH_ALEN);
|
_rtw_memcpy(wrqu.ap_addr.sa_data, pmlmepriv->cur_network.network.MacAddress, ETH_ALEN);
|
||||||
|
|
||||||
DBG_88E_LEVEL(_drv_always_, "assoc success\n");
|
DBG_88E_LEVEL(_drv_always_, "assoc success\n");
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, SIOCGIWAP, &wrqu, NULL);
|
wireless_send_event(padapter->pnetdev, SIOCGIWAP, &wrqu, NULL);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void rtw_indicate_wx_disassoc_event(_adapter *padapter)
|
void rtw_indicate_wx_disassoc_event(_adapter *padapter)
|
||||||
|
@ -233,10 +222,8 @@ void rtw_indicate_wx_disassoc_event(_adapter *padapter)
|
||||||
wrqu.ap_addr.sa_family = ARPHRD_ETHER;
|
wrqu.ap_addr.sa_family = ARPHRD_ETHER;
|
||||||
_rtw_memset(wrqu.ap_addr.sa_data, 0, ETH_ALEN);
|
_rtw_memset(wrqu.ap_addr.sa_data, 0, ETH_ALEN);
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
DBG_88E_LEVEL(_drv_always_, "indicate disassoc\n");
|
DBG_88E_LEVEL(_drv_always_, "indicate disassoc\n");
|
||||||
wireless_send_event(padapter->pnetdev, SIOCGIWAP, &wrqu, NULL);
|
wireless_send_event(padapter->pnetdev, SIOCGIWAP, &wrqu, NULL);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -53,15 +53,6 @@ if (adapter->registrypriv.mp_mode == 1)
|
||||||
_set_timer(&adapter->mlmepriv.dynamic_chk_timer, 2000);
|
_set_timer(&adapter->mlmepriv.dynamic_chk_timer, 2000);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
void _rtw_set_scan_deny_timer_hdl(void *FunctionContext)
|
|
||||||
{
|
|
||||||
_adapter *adapter = (_adapter *)FunctionContext;
|
|
||||||
rtw_set_scan_deny_timer_hdl(adapter);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
void rtw_init_mlme_timer(_adapter *padapter)
|
void rtw_init_mlme_timer(_adapter *padapter)
|
||||||
{
|
{
|
||||||
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
|
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
|
||||||
|
@ -72,10 +63,6 @@ void rtw_init_mlme_timer(_adapter *padapter)
|
||||||
|
|
||||||
_init_timer(&(pmlmepriv->dynamic_chk_timer), padapter->pnetdev, _dynamic_check_timer_handlder, padapter);
|
_init_timer(&(pmlmepriv->dynamic_chk_timer), padapter->pnetdev, _dynamic_check_timer_handlder, padapter);
|
||||||
|
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
_init_timer(&(pmlmepriv->set_scan_deny_timer), padapter->pnetdev, _rtw_set_scan_deny_timer_hdl, padapter);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#if defined(CONFIG_CHECK_BT_HANG) && defined(CONFIG_BT_COEXIST)
|
#if defined(CONFIG_CHECK_BT_HANG) && defined(CONFIG_BT_COEXIST)
|
||||||
if (padapter->HalFunc.hal_init_checkbthang_workqueue)
|
if (padapter->HalFunc.hal_init_checkbthang_workqueue)
|
||||||
padapter->HalFunc.hal_init_checkbthang_workqueue(padapter);
|
padapter->HalFunc.hal_init_checkbthang_workqueue(padapter);
|
||||||
|
@ -87,10 +74,6 @@ void rtw_os_indicate_connect(_adapter *adapter)
|
||||||
|
|
||||||
_func_enter_;
|
_func_enter_;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_cfg80211_indicate_connect(adapter);
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
rtw_indicate_wx_assoc_event(adapter);
|
rtw_indicate_wx_assoc_event(adapter);
|
||||||
netif_carrier_on(adapter->pnetdev);
|
netif_carrier_on(adapter->pnetdev);
|
||||||
|
|
||||||
|
@ -105,9 +88,6 @@ _func_exit_;
|
||||||
extern void indicate_wx_scan_complete_event(_adapter *padapter);
|
extern void indicate_wx_scan_complete_event(_adapter *padapter);
|
||||||
void rtw_os_indicate_scan_done( _adapter *padapter, bool aborted)
|
void rtw_os_indicate_scan_done( _adapter *padapter, bool aborted)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_cfg80211_indicate_scan_done(wdev_to_priv(padapter->rtw_wdev), aborted);
|
|
||||||
#endif
|
|
||||||
indicate_wx_scan_complete_event(padapter);
|
indicate_wx_scan_complete_event(padapter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -174,10 +154,6 @@ _func_enter_;
|
||||||
|
|
||||||
netif_carrier_off(adapter->pnetdev); // Do it first for tx broadcast pkt after disconnection issue!
|
netif_carrier_off(adapter->pnetdev); // Do it first for tx broadcast pkt after disconnection issue!
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_cfg80211_indicate_disconnect(adapter);
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
rtw_indicate_wx_disassoc_event(adapter);
|
rtw_indicate_wx_disassoc_event(adapter);
|
||||||
|
|
||||||
rtw_reset_securitypriv( adapter );
|
rtw_reset_securitypriv( adapter );
|
||||||
|
@ -224,13 +200,10 @@ _func_enter_;
|
||||||
|
|
||||||
wrqu.data.length = (wrqu.data.length<IW_CUSTOM_MAX) ? wrqu.data.length:IW_CUSTOM_MAX;
|
wrqu.data.length = (wrqu.data.length<IW_CUSTOM_MAX) ? wrqu.data.length:IW_CUSTOM_MAX;
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(adapter->pnetdev,IWEVCUSTOM,&wrqu,buff);
|
wireless_send_event(adapter->pnetdev,IWEVCUSTOM,&wrqu,buff);
|
||||||
#endif
|
|
||||||
|
|
||||||
if (buff)
|
if (buff)
|
||||||
rtw_mfree(buff, IW_CUSTOM_MAX);
|
rtw_mfree(buff, IW_CUSTOM_MAX);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_func_exit_;
|
_func_exit_;
|
||||||
|
@ -293,9 +266,7 @@ void rtw_indicate_sta_assoc_event(_adapter *padapter, struct sta_info *psta)
|
||||||
|
|
||||||
DBG_88E("+rtw_indicate_sta_assoc_event\n");
|
DBG_88E("+rtw_indicate_sta_assoc_event\n");
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, IWEVREGISTERED, &wrqu, NULL);
|
wireless_send_event(padapter->pnetdev, IWEVREGISTERED, &wrqu, NULL);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void rtw_indicate_sta_disassoc_event(_adapter *padapter, struct sta_info *psta)
|
void rtw_indicate_sta_disassoc_event(_adapter *padapter, struct sta_info *psta)
|
||||||
|
@ -319,9 +290,7 @@ void rtw_indicate_sta_disassoc_event(_adapter *padapter, struct sta_info *psta)
|
||||||
|
|
||||||
DBG_88E("+rtw_indicate_sta_disassoc_event\n");
|
DBG_88E("+rtw_indicate_sta_disassoc_event\n");
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event(padapter->pnetdev, IWEVEXPIRED, &wrqu, NULL);
|
wireless_send_event(padapter->pnetdev, IWEVEXPIRED, &wrqu, NULL);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1116,9 +1116,6 @@ _func_enter_;
|
||||||
rtw_init_wifidirect_timers(padapter);
|
rtw_init_wifidirect_timers(padapter);
|
||||||
init_wifidirect_info(padapter, P2P_ROLE_DISABLE);
|
init_wifidirect_info(padapter, P2P_ROLE_DISABLE);
|
||||||
reset_global_wifidirect_info(padapter);
|
reset_global_wifidirect_info(padapter);
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_init_cfg80211_wifidirect_info(padapter);
|
|
||||||
#endif
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
if (rtw_init_wifi_display_info(padapter) == _FAIL)
|
if (rtw_init_wifi_display_info(padapter) == _FAIL)
|
||||||
RT_TRACE(_module_os_intfs_c_,_drv_err_,("\n Can't init init_wifi_display_info\n"));
|
RT_TRACE(_module_os_intfs_c_,_drv_err_,("\n Can't init init_wifi_display_info\n"));
|
||||||
|
@ -1202,17 +1199,6 @@ void rtw_cancel_all_timer(_adapter *padapter)
|
||||||
|
|
||||||
_cancel_timer_ex(&padapter->pwrctrlpriv.pwr_state_check_timer);
|
_cancel_timer_ex(&padapter->pwrctrlpriv.pwr_state_check_timer);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
#ifdef CONFIG_P2P
|
|
||||||
_cancel_timer_ex(&padapter->cfg80211_wdinfo.remain_on_ch_timer);
|
|
||||||
#endif //CONFIG_P2P
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
#ifdef CONFIG_SET_SCAN_DENY_TIMER
|
|
||||||
_cancel_timer_ex(&padapter->mlmepriv.set_scan_deny_timer);
|
|
||||||
RT_TRACE(_module_os_intfs_c_,_drv_info_,("rtw_cancel_all_timer:cancel set_scan_deny_timer!\n"));
|
|
||||||
#endif
|
|
||||||
|
|
||||||
_cancel_timer_ex(&padapter->recvpriv.signal_stat_timer);
|
_cancel_timer_ex(&padapter->recvpriv.signal_stat_timer);
|
||||||
#if defined(CONFIG_CHECK_BT_HANG) && defined(CONFIG_BT_COEXIST)
|
#if defined(CONFIG_CHECK_BT_HANG) && defined(CONFIG_BT_COEXIST)
|
||||||
if (padapter->HalFunc.hal_cancel_checkbthang_workqueue)
|
if (padapter->HalFunc.hal_cancel_checkbthang_workqueue)
|
||||||
|
@ -1384,9 +1370,6 @@ int _netdev_open(struct net_device *pnetdev)
|
||||||
padapter->intf_start(padapter);
|
padapter->intf_start(padapter);
|
||||||
rtw_proc_init_one(pnetdev);
|
rtw_proc_init_one(pnetdev);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_cfg80211_init_wiphy(padapter);
|
|
||||||
#endif
|
|
||||||
rtw_led_control(padapter, LED_CTL_NO_LINK);
|
rtw_led_control(padapter, LED_CTL_NO_LINK);
|
||||||
|
|
||||||
padapter->bup = true;
|
padapter->bup = true;
|
||||||
|
@ -1583,19 +1566,9 @@ static int netdev_close(struct net_device *pnetdev)
|
||||||
nat25_db_cleanup(padapter);
|
nat25_db_cleanup(padapter);
|
||||||
|
|
||||||
#ifdef CONFIG_P2P
|
#ifdef CONFIG_P2P
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (wdev_to_priv(padapter->rtw_wdev)->p2p_enabled == true)
|
|
||||||
wdev_to_priv(padapter->rtw_wdev)->p2p_enabled = false;
|
|
||||||
#endif
|
|
||||||
rtw_p2p_enable(padapter, P2P_ROLE_DISABLE);
|
rtw_p2p_enable(padapter, P2P_ROLE_DISABLE);
|
||||||
#endif //CONFIG_P2P
|
#endif //CONFIG_P2P
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_scan_abort(padapter);
|
|
||||||
wdev_to_priv(padapter->rtw_wdev)->bandroid_scan = false;
|
|
||||||
padapter->rtw_wdev->iftype = NL80211_IFTYPE_MONITOR; //set this at the end
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
RT_TRACE(_module_os_intfs_c_,_drv_info_,("-88eu_drv - drv_close\n"));
|
RT_TRACE(_module_os_intfs_c_,_drv_info_,("-88eu_drv - drv_close\n"));
|
||||||
DBG_88E("-88eu_drv - drv_close, bup=%d\n", padapter->bup);
|
DBG_88E("-88eu_drv - drv_close, bup=%d\n", padapter->bup);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -98,9 +98,6 @@ int rtw_os_recvbuf_resource_free(_adapter *padapter, struct recv_buf *precvbuf)
|
||||||
|
|
||||||
void rtw_handle_tkip_mic_err(_adapter *padapter,u8 bgroup)
|
void rtw_handle_tkip_mic_err(_adapter *padapter,u8 bgroup)
|
||||||
{
|
{
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
enum nl80211_key_type key_type;
|
|
||||||
#endif
|
|
||||||
union iwreq_data wrqu;
|
union iwreq_data wrqu;
|
||||||
struct iw_michaelmicfailure ev;
|
struct iw_michaelmicfailure ev;
|
||||||
struct mlme_priv* pmlmepriv = &padapter->mlmepriv;
|
struct mlme_priv* pmlmepriv = &padapter->mlmepriv;
|
||||||
|
@ -127,29 +124,11 @@ void rtw_handle_tkip_mic_err(_adapter *padapter,u8 bgroup)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if ( bgroup )
|
|
||||||
{
|
|
||||||
key_type |= NL80211_KEYTYPE_GROUP;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
key_type |= NL80211_KEYTYPE_PAIRWISE;
|
|
||||||
}
|
|
||||||
|
|
||||||
cfg80211_michael_mic_failure(padapter->pnetdev, (u8 *)&pmlmepriv->assoc_bssid[ 0 ], key_type, -1,
|
|
||||||
NULL, GFP_ATOMIC);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
_rtw_memset( &ev, 0x00, sizeof( ev ) );
|
_rtw_memset( &ev, 0x00, sizeof( ev ) );
|
||||||
if ( bgroup )
|
if ( bgroup )
|
||||||
{
|
|
||||||
ev.flags |= IW_MICFAILURE_GROUP;
|
ev.flags |= IW_MICFAILURE_GROUP;
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
|
||||||
ev.flags |= IW_MICFAILURE_PAIRWISE;
|
ev.flags |= IW_MICFAILURE_PAIRWISE;
|
||||||
}
|
|
||||||
|
|
||||||
ev.src_addr.sa_family = ARPHRD_ETHER;
|
ev.src_addr.sa_family = ARPHRD_ETHER;
|
||||||
_rtw_memcpy( ev.src_addr.sa_data, &pmlmepriv->assoc_bssid[ 0 ], ETH_ALEN );
|
_rtw_memcpy( ev.src_addr.sa_data, &pmlmepriv->assoc_bssid[ 0 ], ETH_ALEN );
|
||||||
|
@ -157,9 +136,7 @@ void rtw_handle_tkip_mic_err(_adapter *padapter,u8 bgroup)
|
||||||
_rtw_memset( &wrqu, 0x00, sizeof( wrqu ) );
|
_rtw_memset( &wrqu, 0x00, sizeof( wrqu ) );
|
||||||
wrqu.data.length = sizeof( ev );
|
wrqu.data.length = sizeof( ev );
|
||||||
|
|
||||||
#ifndef CONFIG_IOCTL_CFG80211
|
|
||||||
wireless_send_event( padapter->pnetdev, IWEVMICHAELMICFAILURE, &wrqu, (char*) &ev );
|
wireless_send_event( padapter->pnetdev, IWEVMICHAELMICFAILURE, &wrqu, (char*) &ev );
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void rtw_hostapd_mlme_rx(_adapter *padapter, union recv_frame *precv_frame)
|
void rtw_hostapd_mlme_rx(_adapter *padapter, union recv_frame *precv_frame)
|
||||||
|
|
|
@ -298,10 +298,6 @@ static int rtw_android_set_block(struct net_device *net, char *command, int tota
|
||||||
_adapter *adapter = (_adapter *)rtw_netdev_priv(net);
|
_adapter *adapter = (_adapter *)rtw_netdev_priv(net);
|
||||||
char *block_value = command + strlen(android_wifi_cmd_str[ANDROID_WIFI_CMD_BLOCK]) + 1;
|
char *block_value = command + strlen(android_wifi_cmd_str[ANDROID_WIFI_CMD_BLOCK]) + 1;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
wdev_to_priv(adapter->rtw_wdev)->block = (*block_value=='0')?false:true;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -461,15 +457,6 @@ int rtw_android_priv_cmd(struct net_device *net, struct ifreq *ifr, int cmd)
|
||||||
//bytes_written = wl_cfg80211_set_p2p_ps(net, command + skip, priv_cmd.total_len - skip);
|
//bytes_written = wl_cfg80211_set_p2p_ps(net, command + skip, priv_cmd.total_len - skip);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
case ANDROID_WIFI_CMD_SET_AP_WPS_P2P_IE:
|
|
||||||
{
|
|
||||||
int skip = strlen(android_wifi_cmd_str[ANDROID_WIFI_CMD_SET_AP_WPS_P2P_IE]) + 3;
|
|
||||||
bytes_written = rtw_cfg80211_set_mgnt_wpsp2pie(net, command + skip, priv_cmd.total_len - skip, *(command + skip - 2) - '0');
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
#endif //CONFIG_IOCTL_CFG80211
|
|
||||||
|
|
||||||
#ifdef CONFIG_WFD
|
#ifdef CONFIG_WFD
|
||||||
case ANDROID_WIFI_CMD_WFD_ENABLE:
|
case ANDROID_WIFI_CMD_WFD_ENABLE:
|
||||||
{
|
{
|
||||||
|
|
|
@ -1039,13 +1039,6 @@ static _adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj,
|
||||||
SET_NETDEV_DEV(pnetdev, dvobj_to_dev(dvobj));
|
SET_NETDEV_DEV(pnetdev, dvobj_to_dev(dvobj));
|
||||||
padapter = rtw_netdev_priv(pnetdev);
|
padapter = rtw_netdev_priv(pnetdev);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
if (rtw_wdev_alloc(padapter, dvobj_to_dev(dvobj)) != 0) {
|
|
||||||
goto handle_dualmac;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
//step 2. hook HalFunc, allocate HalData
|
//step 2. hook HalFunc, allocate HalData
|
||||||
hal_set_hal_ops(padapter);
|
hal_set_hal_ops(padapter);
|
||||||
|
|
||||||
|
@ -1147,12 +1140,6 @@ free_hal_data:
|
||||||
if (status != _SUCCESS && padapter->HalData)
|
if (status != _SUCCESS && padapter->HalData)
|
||||||
kfree(padapter->HalData);
|
kfree(padapter->HalData);
|
||||||
free_wdev:
|
free_wdev:
|
||||||
if (status != _SUCCESS) {
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_wdev_unregister(padapter->rtw_wdev);
|
|
||||||
rtw_wdev_free(padapter->rtw_wdev);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
handle_dualmac:
|
handle_dualmac:
|
||||||
if (status != _SUCCESS)
|
if (status != _SUCCESS)
|
||||||
rtw_handle_dualmac(padapter, 0);
|
rtw_handle_dualmac(padapter, 0);
|
||||||
|
@ -1200,11 +1187,6 @@ static void rtw_usb_if1_deinit(_adapter *if1)
|
||||||
|
|
||||||
rtw_handle_dualmac(if1, 0);
|
rtw_handle_dualmac(if1, 0);
|
||||||
|
|
||||||
#ifdef CONFIG_IOCTL_CFG80211
|
|
||||||
rtw_wdev_unregister(if1->rtw_wdev);
|
|
||||||
rtw_wdev_free(if1->rtw_wdev);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_BT_COEXIST
|
#ifdef CONFIG_BT_COEXIST
|
||||||
if (1 == if1->pwrctrlpriv.autopm_cnt){
|
if (1 == if1->pwrctrlpriv.autopm_cnt){
|
||||||
#if (LINUX_VERSION_CODE>=KERNEL_VERSION(2,6,33))
|
#if (LINUX_VERSION_CODE>=KERNEL_VERSION(2,6,33))
|
||||||
|
|
Loading…
Reference in a new issue