mirror of
https://github.com/lwfinger/rtl8188eu.git
synced 2025-05-08 14:33:05 +00:00
rtl8188eu: Remove dead code for CONFIG_TDLS
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
parent
0e4009c999
commit
e79535e153
23 changed files with 50 additions and 5135 deletions
|
@ -10563,54 +10563,14 @@ static int rtw_wfd_tdls_enable(struct net_device *dev,
|
|||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
|
||||
printk("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
if (extra[ 0 ] == '0')
|
||||
{
|
||||
padapter->wdinfo.wfd_tdls_enable = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
padapter->wdinfo.wfd_tdls_enable = 1;
|
||||
}
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_weaksec(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
u8 i, j;
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
if (extra[ 0 ] == '0')
|
||||
{
|
||||
padapter->wdinfo.wfd_tdls_weaksec = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
padapter->wdinfo.wfd_tdls_weaksec = 1;
|
||||
}
|
||||
#endif
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
@ -10618,361 +10578,70 @@ static int rtw_tdls_enable(struct net_device *dev,
|
|||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
_irqL irqL;
|
||||
_list *plist, *phead;
|
||||
s32 index;
|
||||
struct sta_info *psta = NULL;
|
||||
struct sta_priv *pstapriv = &padapter->stapriv;
|
||||
u8 tdls_sta[NUM_STA][ETH_ALEN];
|
||||
u8 empty_hwaddr[ETH_ALEN] = { 0x00 };
|
||||
|
||||
printk("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
_rtw_memset(tdls_sta, 0x00, sizeof(tdls_sta));
|
||||
|
||||
if (extra[ 0 ] == '0')
|
||||
{
|
||||
ptdlsinfo->enable = 0;
|
||||
|
||||
if (pstapriv->asoc_sta_count==1)
|
||||
return ret;
|
||||
|
||||
_enter_critical_bh(&pstapriv->sta_hash_lock, &irqL);
|
||||
for (index=0; index< NUM_STA; index++)
|
||||
{
|
||||
phead = &(pstapriv->sta_hash[index]);
|
||||
plist = get_next(phead);
|
||||
|
||||
while ((rtw_end_of_queue_search(phead, plist)) == false)
|
||||
{
|
||||
psta = LIST_CONTAINOR(plist, struct sta_info ,hash_list);
|
||||
|
||||
plist = get_next(plist);
|
||||
|
||||
if (psta->tdls_sta_state != TDLS_STATE_NONE)
|
||||
{
|
||||
_rtw_memcpy(tdls_sta[index], psta->hwaddr, ETH_ALEN);
|
||||
}
|
||||
}
|
||||
}
|
||||
_exit_critical_bh(&pstapriv->sta_hash_lock, &irqL);
|
||||
|
||||
for (index=0; index< NUM_STA; index++) {
|
||||
if (!!memcmp(tdls_sta[index], empty_hwaddr, ETH_ALEN)) {
|
||||
pr_info("issue tear down to %pM\n", tdls_sta[index]);
|
||||
issue_tdls_teardown(padapter, tdls_sta[index]);
|
||||
}
|
||||
}
|
||||
rtw_tdls_cmd(padapter, myid(&(padapter->eeprompriv)), TDLS_RS_RCR);
|
||||
rtw_reset_tdls_info(padapter);
|
||||
} else if (extra[ 0 ] == '1') {
|
||||
ptdlsinfo->enable = 1;
|
||||
}
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_setup(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
u8 i, j;
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
u8 mac_addr[ETH_ALEN];
|
||||
|
||||
#ifdef CONFIG_WFD
|
||||
struct wifidirect_info *pwdinfo= &(padapter->wdinfo);
|
||||
#endif // CONFIG_WFD
|
||||
|
||||
printk("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
#ifdef CONFIG_WFD
|
||||
if (_AES_ != padapter->securitypriv.dot11PrivacyAlgrthm)
|
||||
{
|
||||
// Weak Security situation with AP.
|
||||
if (0 == pwdinfo->wfd_tdls_weaksec)
|
||||
{
|
||||
// Can't send the tdls setup request out!!
|
||||
DBG_88E("[%s] Current link is not AES, SKIP sending the tdls setup request!!\n", __func__);
|
||||
}
|
||||
else
|
||||
{
|
||||
issue_tdls_setup_req(padapter, mac_addr);
|
||||
}
|
||||
}
|
||||
else
|
||||
#endif // CONFIG_WFD
|
||||
{
|
||||
issue_tdls_setup_req(padapter, mac_addr);
|
||||
}
|
||||
#endif
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_teardown(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
u8 i,j;
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct sta_info *ptdls_sta = NULL;
|
||||
u8 mac_addr[ETH_ALEN];
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
ptdls_sta = rtw_get_stainfo(&(padapter->stapriv), mac_addr);
|
||||
|
||||
if (ptdls_sta != NULL)
|
||||
{
|
||||
ptdls_sta->stat_code = _RSON_TDLS_TEAR_UN_RSN_;
|
||||
issue_tdls_teardown(padapter, mac_addr);
|
||||
}
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_discovery(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv);
|
||||
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
issue_tdls_dis_req(padapter, NULL);
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_ch_switch (struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
u8 i, j, mac_addr[ETH_ALEN];
|
||||
struct sta_info *ptdls_sta = NULL;
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
ptdls_sta = rtw_get_stainfo(&padapter->stapriv, mac_addr);
|
||||
if (ptdls_sta == NULL)
|
||||
return ret;
|
||||
ptdlsinfo->ch_sensing=1;
|
||||
|
||||
rtw_tdls_cmd(padapter, ptdls_sta->hwaddr, TDLS_INIT_CH_SEN);
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_pson(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv);
|
||||
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
|
||||
u8 i, j, mac_addr[ETH_ALEN];
|
||||
struct sta_info *ptdls_sta = NULL;
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
ptdls_sta = rtw_get_stainfo(&padapter->stapriv, mac_addr);
|
||||
|
||||
issue_nulldata_to_TDLS_peer_STA(padapter, ptdls_sta, 1);
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_psoff(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct mlme_ext_priv *pmlmeext = &(padapter->mlmeextpriv);
|
||||
struct mlme_ext_info *pmlmeinfo = &(pmlmeext->mlmext_info);
|
||||
u8 i, j, mac_addr[ETH_ALEN];
|
||||
struct sta_info *ptdls_sta = NULL;
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
ptdls_sta = rtw_get_stainfo(&padapter->stapriv, mac_addr);
|
||||
|
||||
issue_nulldata_to_TDLS_peer_STA(padapter, ptdls_sta, 0);
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_setip(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
struct wifi_display_info *pwfd_info = ptdlsinfo->wfd_info;
|
||||
u8 i=0, j=0, k=0, tag=0, ip[3] = { 0xff }, *ptr = extra;
|
||||
|
||||
printk("[%s] %s %d\n", __func__, extra, wrqu->data.length - 1 );
|
||||
|
||||
|
||||
while (i < 4)
|
||||
{
|
||||
for (j=0; j < 4; j++)
|
||||
{
|
||||
if (*(extra + j + tag) == '.' || *(extra + j + tag) == '\0')
|
||||
{
|
||||
if (j == 1)
|
||||
pwfd_info->ip_address[i]=convert_ip_addr('0', '0', *(extra+(j-1)+tag));
|
||||
if (j == 2)
|
||||
pwfd_info->ip_address[i]=convert_ip_addr('0', *(extra+(j-2)+tag), *(extra+(j-1)+tag));
|
||||
if (j == 3)
|
||||
pwfd_info->ip_address[i]=convert_ip_addr(*(extra+(j-3)+tag), *(extra+(j-2)+tag), *(extra+(j-1)+tag));
|
||||
|
||||
tag += j + 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
||||
printk("[%s] Set IP = %u.%u.%u.%u\n", __func__,
|
||||
ptdlsinfo->wfd_info->ip_address[0], ptdlsinfo->wfd_info->ip_address[1],
|
||||
ptdlsinfo->wfd_info->ip_address[2], ptdlsinfo->wfd_info->ip_address[3]
|
||||
);
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_getip(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
struct wifi_display_info *pwfd_info = ptdlsinfo->wfd_info;
|
||||
|
||||
printk("[%s]\n", __func__);
|
||||
|
||||
sprintf(extra, "\n\n%u.%u.%u.%u\n",
|
||||
pwfd_info->peer_ip_address[0], pwfd_info->peer_ip_address[1],
|
||||
pwfd_info->peer_ip_address[2], pwfd_info->peer_ip_address[3]
|
||||
);
|
||||
|
||||
printk("[%s] IP=%u.%u.%u.%u\n", __func__,
|
||||
pwfd_info->peer_ip_address[0], pwfd_info->peer_ip_address[1],
|
||||
pwfd_info->peer_ip_address[2], pwfd_info->peer_ip_address[3]
|
||||
);
|
||||
|
||||
wrqu->data.length = strlen(extra);
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_getport(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
struct wifi_display_info *pwfd_info = ptdlsinfo->wfd_info;
|
||||
|
||||
printk("[%s]\n", __func__);
|
||||
|
||||
sprintf(extra, "\n\n%d\n", pwfd_info->peer_rtsp_ctrlport);
|
||||
printk("[%s] remote port = %d\n", __func__, pwfd_info->peer_rtsp_ctrlport);
|
||||
|
||||
wrqu->data.length = strlen(extra);
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
|
||||
}
|
||||
|
||||
|
@ -10981,31 +10650,7 @@ static int rtw_tdls_dis_result(struct net_device *dev,
|
|||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
struct wifi_display_info *pwfd_info = ptdlsinfo->wfd_info;
|
||||
|
||||
printk("[%s]\n", __func__);
|
||||
|
||||
if (ptdlsinfo->dev_discovered == 1)
|
||||
{
|
||||
sprintf(extra, "\n\nDis=1\n");
|
||||
ptdlsinfo->dev_discovered = 0;
|
||||
}
|
||||
|
||||
wrqu->data.length = strlen(extra);
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
//WFDTDLS, for sigma test
|
||||
|
@ -11013,156 +10658,21 @@ static int rtw_wfd_tdls_status(struct net_device *dev,
|
|||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
struct tdls_info *ptdlsinfo = &padapter->tdlsinfo;
|
||||
struct wifi_display_info *pwfd_info = ptdlsinfo->wfd_info;
|
||||
|
||||
printk("[%s]\n", __func__);
|
||||
|
||||
if (ptdlsinfo->setup_state == TDLS_LINKED_STATE)
|
||||
{
|
||||
sprintf(extra, "\n\nStatus=1\n");
|
||||
}
|
||||
else
|
||||
{
|
||||
sprintf(extra, "\n\nStatus=0\n");
|
||||
}
|
||||
|
||||
wrqu->data.length = strlen(extra);
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls_ch_switch_off(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
u8 i, j, mac_addr[ETH_ALEN];
|
||||
struct sta_info *ptdls_sta = NULL;
|
||||
|
||||
DBG_88E("[%s] %s %d\n", __func__, extra, wrqu->data.length -1 );
|
||||
|
||||
for (i=0, j=0 ; i < ETH_ALEN; i++, j+=3){
|
||||
mac_addr[i]=key_2char2num(*(extra+j), *(extra+j+1));
|
||||
}
|
||||
|
||||
ptdls_sta = rtw_get_stainfo(&padapter->stapriv, mac_addr);
|
||||
|
||||
ptdls_sta->tdls_sta_state |= TDLS_SW_OFF_STATE;
|
||||
/*
|
||||
if ((ptdls_sta->tdls_sta_state & TDLS_AT_OFF_CH_STATE) && (ptdls_sta->tdls_sta_state & TDLS_PEER_AT_OFF_STATE)){
|
||||
pmlmeinfo->tdls_candidate_ch= pmlmeext->cur_channel;
|
||||
issue_tdls_ch_switch_req(padapter, mac_addr);
|
||||
DBG_88E("issue tdls ch switch req back to base channel\n");
|
||||
}
|
||||
*/
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_tdls(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
|
||||
DBG_88E("[%s] extra = %s\n", __func__, extra);
|
||||
// WFD Sigma will use the tdls enable command to let the driver know we want to test the tdls now!
|
||||
if (!memcmp(extra, "wfdenable=", 10))
|
||||
{
|
||||
wrqu->data.length -=10;
|
||||
rtw_wfd_tdls_enable(dev, info, wrqu, &extra[10]);
|
||||
return ret;
|
||||
}
|
||||
else if (!memcmp(extra, "weaksec=", 8))
|
||||
{
|
||||
wrqu->data.length -=8;
|
||||
rtw_tdls_weaksec(dev, info, wrqu, &extra[8]);
|
||||
return ret;
|
||||
}
|
||||
else if (!memcmp(extra, "tdlsenable=", 11))
|
||||
{
|
||||
wrqu->data.length -=11;
|
||||
rtw_tdls_enable(dev, info, wrqu, &extra[11]);
|
||||
return ret;
|
||||
}
|
||||
|
||||
if (padapter->tdlsinfo.enable == 0)
|
||||
{
|
||||
printk("tdls haven't enabled\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (!memcmp(extra, "setup=", 6))
|
||||
{
|
||||
wrqu->data.length -=6;
|
||||
rtw_tdls_setup(dev, info, wrqu, &extra[6]);
|
||||
}
|
||||
else if (!memcmp(extra, "tear=", 5))
|
||||
{
|
||||
wrqu->data.length -= 5;
|
||||
rtw_tdls_teardown(dev, info, wrqu, &extra[5]);
|
||||
}
|
||||
else if (!memcmp(extra, "dis=", 4))
|
||||
{
|
||||
wrqu->data.length -= 4;
|
||||
rtw_tdls_discovery(dev, info, wrqu, &extra[4]);
|
||||
}
|
||||
else if (!memcmp(extra, "sw=", 3))
|
||||
{
|
||||
wrqu->data.length -= 3;
|
||||
rtw_tdls_ch_switch (dev, info, wrqu, &extra[3]);
|
||||
}
|
||||
else if (!memcmp(extra, "swoff=", 6))
|
||||
{
|
||||
wrqu->data.length -= 6;
|
||||
rtw_tdls_ch_switch_off(dev, info, wrqu, &extra[6]);
|
||||
}
|
||||
else if (!memcmp(extra, "pson=", 5))
|
||||
{
|
||||
wrqu->data.length -= 5;
|
||||
rtw_tdls_pson(dev, info, wrqu, &extra[5]);
|
||||
}
|
||||
else if (!memcmp(extra, "psoff=", 6))
|
||||
{
|
||||
wrqu->data.length -= 6;
|
||||
rtw_tdls_psoff(dev, info, wrqu, &extra[6]);
|
||||
}
|
||||
#ifdef CONFIG_WFD
|
||||
else if (!memcmp(extra, "setip=", 6))
|
||||
{
|
||||
wrqu->data.length -= 6;
|
||||
rtw_tdls_setip(dev, info, wrqu, &extra[6]);
|
||||
}
|
||||
else if (!memcmp(extra, "tprobe=", 6))
|
||||
{
|
||||
issue_tunneled_probe_req((_adapter *)rtw_netdev_priv(dev));
|
||||
}
|
||||
#endif //CONFIG_WFD
|
||||
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
@ -11170,8 +10680,6 @@ static int rtw_tdls_get(struct net_device *dev,
|
|||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
#ifdef CONFIG_WFD
|
||||
|
||||
DBG_88E("[%s] extra = %s\n", __func__, (char*) wrqu->data.pointer);
|
||||
|
@ -11195,25 +10703,19 @@ static int rtw_tdls_get(struct net_device *dev,
|
|||
}
|
||||
|
||||
#endif //CONFIG_WFD
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#ifdef CONFIG_INTEL_WIDI
|
||||
static int rtw_widi_set(struct net_device *dev,
|
||||
struct iw_request_info *info,
|
||||
union iwreq_data *wrqu, char *extra)
|
||||
{
|
||||
int ret = 0;
|
||||
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
|
||||
|
||||
process_intel_widi_cmd(padapter, extra);
|
||||
|
||||
return ret;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int rtw_widi_set_probe_request(struct net_device *dev,
|
||||
|
|
|
@ -1203,14 +1203,6 @@ _func_enter_;
|
|||
goto exit;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_TDLS
|
||||
if (rtw_init_tdls_info(padapter) == _FAIL) {
|
||||
DBG_88E("Can't rtw_init_tdls_info\n");
|
||||
ret8=_FAIL;
|
||||
goto exit;
|
||||
}
|
||||
#endif //CONFIG_TDLS
|
||||
|
||||
if (_rtw_init_xmit_priv(&padapter->xmitpriv, padapter) == _FAIL) {
|
||||
DBG_88E("Can't _rtw_init_xmit_priv\n");
|
||||
ret8=_FAIL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue