mirror of
https://github.com/torvalds/linux.git
synced 2026-08-02 05:12:01 +02:00
staging: rtl8723au: Don't run regular scans in the driver, the stack handles that
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
e9bb5ad46d
commit
073c9d47c3
|
|
@ -1,7 +1,6 @@
|
|||
r8723au-y := \
|
||||
core/rtw_cmd.o \
|
||||
core/rtw_efuse.o \
|
||||
core/rtw_ioctl_set.o \
|
||||
core/rtw_ieee80211.o \
|
||||
core/rtw_led.o \
|
||||
core/rtw_mlme.o \
|
||||
|
|
|
|||
|
|
@ -1,78 +0,0 @@
|
|||
/******************************************************************************
|
||||
*
|
||||
* Copyright(c) 2007 - 2012 Realtek Corporation. All rights reserved.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms of version 2 of the GNU General Public License as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||
* more details.
|
||||
*
|
||||
******************************************************************************/
|
||||
#define _RTW_IOCTL_SET_C_
|
||||
|
||||
#include <osdep_service.h>
|
||||
#include <drv_types.h>
|
||||
#include <rtw_ioctl_set.h>
|
||||
#include <hal_intf.h>
|
||||
|
||||
#include <usb_ops.h>
|
||||
#include <linux/ieee80211.h>
|
||||
|
||||
int rtw_set_802_11_bssid23a_list_scan(struct rtw_adapter *padapter,
|
||||
struct cfg80211_ssid *pssid,
|
||||
int ssid_max_num)
|
||||
{
|
||||
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
|
||||
int res = _SUCCESS;
|
||||
|
||||
RT_TRACE(_module_rtl871x_ioctl_set_c_, _drv_err_,
|
||||
("+%s: fw_state =%x\n", __func__, get_fwstate(pmlmepriv)));
|
||||
|
||||
if (!padapter) {
|
||||
res = _FAIL;
|
||||
goto exit;
|
||||
}
|
||||
if (padapter->hw_init_completed == false) {
|
||||
res = _FAIL;
|
||||
RT_TRACE(_module_rtl871x_ioctl_set_c_, _drv_err_,
|
||||
("%s: hw_init_completed == false ===\n", __func__));
|
||||
goto exit;
|
||||
}
|
||||
|
||||
if (check_fwstate(pmlmepriv, _FW_UNDER_SURVEY | _FW_UNDER_LINKING) ||
|
||||
(pmlmepriv->LinkDetectInfo.bBusyTraffic == true)) {
|
||||
/* Scan or linking is in progress, do nothing. */
|
||||
RT_TRACE(_module_rtl871x_ioctl_set_c_, _drv_err_,
|
||||
("%s fail since fw_state = %x\n", __func__,
|
||||
get_fwstate(pmlmepriv)));
|
||||
|
||||
if (check_fwstate(pmlmepriv,
|
||||
(_FW_UNDER_SURVEY|_FW_UNDER_LINKING))) {
|
||||
RT_TRACE(_module_rtl871x_ioctl_set_c_, _drv_err_,
|
||||
("\n###_FW_UNDER_SURVEY|_FW_UNDER_LINKING\n"));
|
||||
} else {
|
||||
RT_TRACE(_module_rtl871x_ioctl_set_c_, _drv_err_,
|
||||
("\n###pmlmepriv->sitesurveyctrl.traffic_"
|
||||
"busy == true\n"));
|
||||
}
|
||||
} else {
|
||||
if (rtw_is_scan_deny(padapter)) {
|
||||
DBG_8723A("%s(%s): scan deny\n",
|
||||
__func__, padapter->pnetdev->name);
|
||||
return _SUCCESS;
|
||||
}
|
||||
|
||||
spin_lock_bh(&pmlmepriv->lock);
|
||||
|
||||
res = rtw_sitesurvey_cmd23a(padapter, pssid, ssid_max_num,
|
||||
NULL, 0);
|
||||
|
||||
spin_unlock_bh(&pmlmepriv->lock);
|
||||
}
|
||||
exit:
|
||||
return res;
|
||||
}
|
||||
|
|
@ -1538,26 +1538,9 @@ void rtw_scan_timeout_handler23a(unsigned long data)
|
|||
rtw_cfg80211_indicate_scan_done(wdev_to_priv(adapter->rtw_wdev), true);
|
||||
}
|
||||
|
||||
static void rtw_auto_scan_handler(struct rtw_adapter *padapter)
|
||||
{
|
||||
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
|
||||
|
||||
/* auto site survey per 60sec */
|
||||
if (pmlmepriv->scan_interval > 0) {
|
||||
pmlmepriv->scan_interval--;
|
||||
if (pmlmepriv->scan_interval == 0) {
|
||||
DBG_8723A("%s\n", __func__);
|
||||
rtw_set_802_11_bssid23a_list_scan(padapter, NULL, 0);
|
||||
/* 30*2 sec = 60sec */
|
||||
pmlmepriv->scan_interval = SCAN_INTERVAL;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void rtw_dynamic_check_timer_handler(unsigned long data)
|
||||
{
|
||||
struct rtw_adapter *adapter = (struct rtw_adapter *)data;
|
||||
struct registry_priv *pregistrypriv = &adapter->registrypriv;
|
||||
|
||||
if (adapter->hw_init_completed == false)
|
||||
goto out;
|
||||
|
|
@ -1571,10 +1554,6 @@ void rtw_dynamic_check_timer_handler(unsigned long data)
|
|||
|
||||
rtw_dynamic_chk_wk_cmd23a(adapter);
|
||||
|
||||
if (pregistrypriv->wifi_spec == 1) {
|
||||
/* auto site survey */
|
||||
rtw_auto_scan_handler(adapter);
|
||||
}
|
||||
out:
|
||||
mod_timer(&adapter->mlmepriv.dynamic_chk_timer,
|
||||
jiffies + msecs_to_jiffies(2000));
|
||||
|
|
|
|||
|
|
@ -17,10 +17,6 @@
|
|||
|
||||
#include <drv_types.h>
|
||||
|
||||
int rtw_set_802_11_bssid23a_list_scan(struct rtw_adapter *padapter,
|
||||
struct cfg80211_ssid *pssid,
|
||||
int ssid_max_num);
|
||||
|
||||
s32 FillH2CCmd(struct rtw_adapter *padapter, u8 ElementID, u32 CmdLen, u8 *pCmdBuffer);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user