rtl8188eu: Remove dead code for other PLATFORM_XX variables

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2013-07-10 21:20:38 -05:00
parent a3ca3380b5
commit bb27b28f6e
18 changed files with 4 additions and 652 deletions

227
Makefile
View file

@ -34,8 +34,6 @@ CONFIG_EXT_CLK = n
CONFIG_FTP_PROTECT = n
CONFIG_WOWLAN = n
CONFIG_PLATFORM_I386_PC = y
CONFIG_DRVEXT_MODULE = n
export TopDIR ?= $(shell pwd)
@ -181,237 +179,12 @@ endif
SUBARCH := $(shell uname -m | sed -e s/i.86/i386/ | sed -e s/ppc/powerpc/ | sed -e s/armv6l/arm/)
ifeq ($(CONFIG_PLATFORM_I386_PC), y)
ARCH ?= $(SUBARCH)
CROSS_COMPILE ?=
KVER := $(shell uname -r)
KSRC := /lib/modules/$(KVER)/build
MODDESTDIR := /lib/modules/$(KVER)/kernel/drivers/net/wireless/
INSTALL_PREFIX :=
endif
ifeq ($(CONFIG_PLATFORM_ACTIONS_ATM702X), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_ANDROID -DCONFIG_PLATFORM_ACTIONS_ATM702X
#ARCH := arm
ARCH := $(R_ARCH)
#CROSS_COMPILE := arm-none-linux-gnueabi-
CROSS_COMPILE := $(R_CROSS_COMPILE)
KVER:= 3.4.0
#KSRC := ../../../../build/out/kernel
KSRC := $(KERNEL_BUILD_PATH)
MODULE_NAME :=wlan
endif
ifeq ($(CONFIG_PLATFORM_TI_AM3517), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_ANDROID -DCONFIG_PLATFORM_SHUTTLE
CROSS_COMPILE := arm-eabi-
KSRC := $(shell pwd)/../../../Android/kernel
ARCH := arm
endif
ifeq ($(CONFIG_PLATFORM_MSTAR_TITANIA12), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_MSTAR_TITANIA12
ARCH:=mips
CROSS_COMPILE:= /usr/src/Mstar_kernel/mips-4.3/bin/mips-linux-gnu-
KVER:= 2.6.28.9
KSRC:= /usr/src/Mstar_kernel/2.6.28.9/
endif
ifeq ($(CONFIG_PLATFORM_ANDROID_X86), y)
ARCH := $(SUBARCH)
CROSS_COMPILE := /media/DATA-2/android-x86/ics-x86_20120130/prebuilt/linux-x86/toolchain/i686-unknown-linux-gnu-4.2.1/bin/i686-unknown-linux-gnu-
KSRC := /media/DATA-2/android-x86/ics-x86_20120130/out/target/product/generic_x86/obj/kernel
MODULE_NAME :=wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_PXA2XX), y)
ARCH := arm
CROSS_COMPILE := arm-none-linux-gnueabi-
KVER := 2.6.34.1
KSRC ?= /usr/src/linux-2.6.34.1
endif
ifeq ($(CONFIG_PLATFORM_ARM_S3C2K4), y)
ARCH := arm
CROSS_COMPILE := arm-linux-
KVER := 2.6.24.7_$(ARCH)
KSRC := /usr/src/kernels/linux-$(KVER)
endif
ifeq ($(CONFIG_PLATFORM_ARM_S3C6K4), y)
ARCH := arm
CROSS_COMPILE := arm-none-linux-gnueabi-
KVER := 2.6.34.1
KSRC ?= /usr/src/linux-2.6.34.1
endif
ifeq ($(CONFIG_PLATFORM_RTD2880B), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_RTD2880B
ARCH:=
CROSS_COMPILE:=
KVER:=
KSRC:=
endif
ifeq ($(CONFIG_PLATFORM_MIPS_RMI), y)
ARCH:=mips
CROSS_COMPILE:=mipsisa32r2-uclibc-
KVER:=
KSRC:= /root/work/kernel_realtek
endif
ifeq ($(CONFIG_PLATFORM_MIPS_PLM), y)
ARCH:=mips
CROSS_COMPILE:=mipsisa32r2-uclibc-
KVER:=
KSRC:= /root/work/kernel_realtek
endif
ifeq ($(CONFIG_PLATFORM_MSTAR389), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_MSTAR389
ARCH:=mips
CROSS_COMPILE:= mips-linux-gnu-
KVER:= 2.6.28.10
KSRC:= /home/mstar/mstar_linux/2.6.28.9/
endif
ifeq ($(CONFIG_PLATFORM_MIPS_AR9132), y)
ARCH := mips
CROSS_COMPILE := mips-openwrt-linux-
KSRC := /home/alex/test_openwrt/tmp/linux-2.6.30.9
endif
ifeq ($(CONFIG_PLATFORM_DMP_PHILIPS), y)
EXTRA_CFLAGS += -DRTK_DMP_PLATFORM
ARCH := mips
#CROSS_COMPILE:=/usr/local/msdk-4.3.6-mips-EL-2.6.12.6-0.9.30.3/bin/mipsel-linux-
CROSS_COMPILE:=/usr/local/toolchain_mipsel/bin/mipsel-linux-
KSRC ?=/usr/local/Jupiter/linux-2.6.12
endif
ifeq ($(CONFIG_PLATFORM_RTK_DMP), y)
EXTRA_CFLAGS += -DRTK_DMP_PLATFORM
ARCH:=mips
CROSS_COMPILE:=mipsel-linux-
KVER:=
KSRC ?= /usr/src/DMP_Kernel/jupiter/linux-2.6.12
endif
ifeq ($(CONFIG_PLATFORM_MT53XX), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_MT53XX
ARCH:= arm
CROSS_COMPILE:= arm11_mtk_le-
KVER:= 2.6.27
KSRC?= /proj/mtk00802/BD_Compare/BDP/Dev/BDP_V301/BDP_Linux/linux-2.6.27
endif
ifeq ($(CONFIG_PLATFORM_ARM_MX51_241H), y)
EXTRA_CFLAGS += -DCONFIG_WISTRON_PLATFORM
ARCH := arm
CROSS_COMPILE := /opt/freescale/usr/local/gcc-4.1.2-glibc-2.5-nptl-3/arm-none-linux-gnueabi/bin/arm-none-linux-gnueabi-
KVER := 2.6.31
KSRC ?= /lib/modules/2.6.31-770-g0e46b52/source
endif
ifeq ($(CONFIG_PLATFORM_ACTIONS_ATJ227X), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_ACTIONS_ATJ227X
ARCH := mips
CROSS_COMPILE := /home/cnsd4/project/actions/tools-2.6.27/bin/mipsel-linux-gnu-
KVER := 2.6.27
KSRC := /home/cnsd4/project/actions/linux-2.6.27.28
endif
ifeq ($(CONFIG_PLATFORM_TI_DM365), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_TI_DM365
ARCH := arm
CROSS_COMPILE := /home/cnsd4/Appro/mv_pro_5.0/montavista/pro/devkit/arm/v5t_le/bin/arm_v5t_le-
KVER := 2.6.18
KSRC := /home/cnsd4/Appro/mv_pro_5.0/montavista/pro/devkit/lsp/ti-davinci/linux-dm365
endif
ifeq ($(CONFIG_PLATFORM_TEGRA3_CARDHU), y)
ARCH := arm
CROSS_COMPILE := /home/android_sdk/nvidia/tegra-16r3-partner-android-4.1_20120723/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
KSRC := /home/android_sdk/nvidia/tegra-16r3-partner-android-4.1_20120723/out/target/product/cardhu/obj/KERNEL
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_TEGRA4_DALMORE), y)
ARCH := arm
CROSS_COMPILE := /home/android_sdk/nvidia/tegra-17r9-partner-android-4.2-dalmore_20130131/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-
KSRC := /home/android_sdk/nvidia/tegra-17r9-partner-android-4.2-dalmore_20130131/out/target/product/dalmore/obj/KERNEL
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_TCC8900), y)
ARCH := arm
CROSS_COMPILE := /home/android_sdk/Telechips/SDK_2304_20110613/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
KSRC := /home/android_sdk/Telechips/SDK_2304_20110613/kernel
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_TCC8920), y)
ARCH := arm
CROSS_COMPILE := /home/android_sdk/Telechips/v12.06_r1-tcc-android-4.0.4/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
KSRC := /home/android_sdk/Telechips/v12.06_r1-tcc-android-4.0.4/kernel
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_RK2818), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_ANDROID -DCONFIG_PLATFORM_ROCKCHIPS -DCONFIG_MINIMAL_MEMORY_USAGE
ARCH := arm
CROSS_COMPILE := /usr/src/release_fae_version/toolchain/arm-eabi-4.4.0/bin/arm-eabi-
KSRC := /usr/src/release_fae_version/kernel25_A7_281x
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_URBETTER), y)
ARCH := arm
CROSS_COMPILE := /media/DATA-1/urbetter/arm-2009q3/bin/arm-none-linux-gnueabi-
KSRC := /media/DATA-1/urbetter/ics-urbetter/kernel
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_ARM_TI_PANDA), y)
ARCH := arm
#CROSS_COMPILE := /media/DATA-1/aosp/ics-aosp_20111227/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
#KSRC := /media/DATA-1/aosp/android-omap-panda-3.0_20120104
CROSS_COMPILE := /media/DATA-1/android-4.0/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/arm-eabi-
KSRC := /media/DATA-1/android-4.0/panda_kernel/omap
MODULE_NAME := wlan
endif
ifeq ($(CONFIG_PLATFORM_MIPS_JZ4760), y)
ARCH ?= mips
CROSS_COMPILE ?= /mnt/sdb5/Ingenic/Umido/mips-4.3/bin/mips-linux-gnu-
KSRC ?= /mnt/sdb5/Ingenic/Umido/kernel
endif
ifeq ($(CONFIG_PLATFORM_SZEBOOK), y)
ARCH:=arm
CROSS_COMPILE:=/opt/crosstool2/bin/armeb-unknown-linux-gnueabi-
KVER:= 2.6.31.6
KSRC:= ../code/linux-2.6.31.6-2020/
endif
#Add setting for MN10300
ifeq ($(CONFIG_PLATFORM_MN10300), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_MN10300
ARCH := mn10300
CROSS_COMPILE := mn10300-linux-
KVER := 2.6.32.2
KSRC := /home/winuser/work/Plat_sLD2T_V3010/usr/src/linux-2.6.32.2
INSTALL_PREFIX :=
endif
ifeq ($(CONFIG_PLATFORM_ARM_SUNxI), y)
EXTRA_CFLAGS += -DCONFIG_PLATFORM_ARM_SUNxI
ARCH := arm
CROSS_COMPILE := arm-none-linux-gnueabi-
KVER := 3.0.8
#KSRC:= ../lichee/linux-3.0/
endif
ifneq ($(USER_MODULE_NAME),)
MODULE_NAME := $(USER_MODULE_NAME)

View file

@ -9012,11 +9012,9 @@ void start_clnt_auth(_adapter* padapter)
/* Because of AP's not receiving deauth before */
/* AP may: 1)not response auth or 2)deauth us after link is complete */
/* issue deauth before issuing auth to deal with the situation */
#ifndef CONFIG_PLATFORM_RTK_DMP
/* Commented by Albert 2012/07/21 */
/* For the Win8 P2P connection, it will be hard to have a successful connection if this Wi-Fi doesn't connect to it. */
issue_deauth(padapter, (&(pmlmeinfo->network))->MacAddress, WLAN_REASON_DEAUTH_LEAVING);
#endif
DBG_88E_LEVEL(_drv_info_, "start auth\n");
issue_auth(padapter, NULL, 0);

View file

@ -808,14 +808,6 @@ _func_enter_;
else
#endif
{
#if defined(CONFIG_PLATFORM_SPRD) && defined(CONFIG_RTL8188E)
#ifdef CONFIG_IPS
if (false == ips_leave(Adapter))
{
DBG_88E("======> ips_leave fail.............\n");
}
#endif
#endif /* CONFIG_PLATFORM_SPRD && CONFIG_RTL8188E */
}
}
}

View file

@ -1970,21 +1970,6 @@ _func_enter_;
}
#endif /* CONFIG_TDLS */
#ifdef RTK_DMP_PLATFORM
if ( 0 )
{
DBG_88E("++\n");
{
int i;
for (i=0; i<64;i=i+8)
DBG_88E("%02X:%02X:%02X:%02X:%02X:%02X:%02X:%02X:", *(ptr+i),
*(ptr+i+1), *(ptr+i+2) ,*(ptr+i+3) ,*(ptr+i+4),*(ptr+i+5), *(ptr+i+6), *(ptr+i+7));
}
DBG_88E("--\n");
}
#endif /* RTK_DMP_PLATFORM */
/* add version chk */
if (ver!=0){
RT_TRACE(_module_rtl871x_recv_c_,_drv_err_,("validate_recv_data_frame fail! (ver!=0)\n"));

View file

@ -2271,26 +2271,10 @@ static struct xmit_frame *dequeue_one_xmitframe(struct xmit_priv *pxmitpriv, str
xmitframe_plist = get_next(xmitframe_plist);
/*#ifdef RTK_DMP_PLATFORM
#ifdef CONFIG_USB_TX_AGGREGATION
if ((ptxservq->qcnt>0) && (ptxservq->qcnt<=2))
{
pxmitframe = NULL;
tasklet_schedule(&pxmitpriv->xmit_tasklet);
break;
}
#endif
#endif*/
rtw_list_delete(&pxmitframe->list);
ptxservq->qcnt--;
/* rtw_list_insert_tail(&pxmitframe->list, &phwxmit->pending); */
/* ptxservq->qcnt--; */
break;
pxmitframe = NULL;

View file

@ -780,7 +780,6 @@ ODM_DMWatchdog(
odm_RSSIMonitorCheck(pDM_Odm);
#if (DM_ODM_SUPPORT_TYPE == ODM_CE)
/* ifdef CONFIG_PLATFORM_SPRD */
/* For CE Platform(SPRD or Tablet) */
/* 8723A or 8189ES platform */
/* NeilChen--2012--08--24-- */
@ -799,7 +798,6 @@ ODM_DMWatchdog(
odm_DIGbyRSSI_LPS(pDM_Odm);
}
else
/* endif */
#endif
{
odm_DIG(pDM_Odm);

View file

@ -101,14 +101,6 @@ static void dm_CheckPbcGPIO(_adapter *padapter)
/* After trigger PBC, the variable will be set to false */
DBG_88E("CheckPbcGPIO - PBC is pressed\n");
#ifdef RTK_DMP_PLATFORM
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12))
kobject_uevent(&padapter->pnetdev->dev.kobj, KOBJ_NET_PBC);
#else
kobject_hotplug(&padapter->pnetdev->class_dev.kobj, KOBJ_NET_PBC);
#endif
#else
if ( padapter->pid[0] == 0 )
{ /* 0 is the default value and it means the application monitors the HW PBC doesn't privde its pid to driver. */
return;
@ -116,7 +108,6 @@ static void dm_CheckPbcGPIO(_adapter *padapter)
#ifdef PLATFORM_LINUX
rtw_signal_process(padapter->pid[0], SIGUSR1);
#endif
#endif
}
}

View file

@ -39,21 +39,9 @@
#define PLATFORM_LINUX
//#define CONFIG_IOCTL_CFG80211
#if defined( CONFIG_PLATFORM_ARM_SUNxI) || defined(CONFIG_PLATFORM_ACTIONS_ATM702X)
#ifndef CONFIG_IOCTL_CFG80211
#define CONFIG_IOCTL_CFG80211
#endif
#endif
#ifdef CONFIG_IOCTL_CFG80211
//#define RTW_USE_CFG80211_STA_EVENT /* Opne this for Android 4.1's wpa_supplicant */
#define CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER
//#define CONFIG_DEBUG_CFG80211
//#define CONFIG_DRV_ISSUE_PROV_REQ // IOT FOR S2
#define CONFIG_SET_SCAN_DENY_TIMER
#endif
/*
@ -217,20 +205,6 @@
#endif
#define CONFIG_PREALLOC_RECV_SKB
//#define CONFIG_REDUCE_USB_TX_INT // Trade-off: Improve performance, but may cause TX URBs blocked by USB Host/Bus driver on few platforms.
//#define CONFIG_EASY_REPLACEMENT
/*
* CONFIG_USE_USB_BUFFER_ALLOC_XX uses Linux USB Buffer alloc API and is for Linux platform only now!
*/
//#define CONFIG_USE_USB_BUFFER_ALLOC_TX // Trade-off: For TX path, improve stability on some platforms, but may cause performance degrade on other platforms.
//#define CONFIG_USE_USB_BUFFER_ALLOC_RX // For RX path
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#ifndef CONFIG_USE_USB_BUFFER_ALLOC_TX
#define CONFIG_USE_USB_BUFFER_ALLOC_TX
#endif
#endif
/*
* USB VENDOR REQ BUFFER ALLOCATION METHOD
@ -242,9 +216,6 @@
#define CONFIG_USB_VENDOR_REQ_MUTEX
#define CONFIG_VENDOR_REQ_RETRY
//#define CONFIG_USB_SUPPORT_ASYNC_VDN_REQ
/*
* HAL Related Config
*/
@ -280,41 +251,6 @@
/*
* Platform Related Config
*/
#ifdef CONFIG_PLATFORM_MN10300
#define CONFIG_SPECIAL_SETTING_FOR_FUNAI_TV
#define CONFIG_USE_USB_BUFFER_ALLOC_RX
#if defined (CONFIG_SW_ANTENNA_DIVERSITY)
#undef CONFIG_SW_ANTENNA_DIVERSITY
#define CONFIG_HW_ANTENNA_DIVERSITY
#endif
#if defined (CONFIG_POWER_SAVING)
#undef CONFIG_POWER_SAVING
#endif
#endif//CONFIG_PLATFORM_MN10300
#ifdef CONFIG_PLATFORM_TI_DM365
#define CONFIG_USE_USB_BUFFER_ALLOC_RX
#endif
#if defined(CONFIG_PLATFORM_ACTIONS_ATM702X)
#ifdef CONFIG_USB_TX_AGGREGATION
#undef CONFIG_USB_TX_AGGREGATION
#endif
#ifndef CONFIG_USE_USB_BUFFER_ALLOC_TX
#define CONFIG_USE_USB_BUFFER_ALLOC_TX
#endif
#ifndef CONFIG_USE_USB_BUFFER_ALLOC_RX
#define CONFIG_USE_USB_BUFFER_ALLOC_RX
#endif
#endif
/*
* Outsource Related Config
*/

View file

@ -21,28 +21,6 @@
#define __DRV_CONF_H__
#include "autoconf.h"
//Older Android kernel doesn't has CONFIG_ANDROID defined,
//add this to force CONFIG_ANDROID defined
#ifdef CONFIG_PLATFORM_ANDROID
#define CONFIG_ANDROID
#endif
#ifdef CONFIG_ANDROID
//Some Android build will restart the UI while non-printable ascii is passed
//between java and c/c++ layer (JNI). We force CONFIG_VALIDATE_SSID
//for Android here. If you are sure there is no risk on your system about this,
//mask this macro define to support non-printable ascii ssid.
//#define CONFIG_VALIDATE_SSID
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#ifdef CONFIG_VALIDATE_SSID
#undef CONFIG_VALIDATE_SSID
#endif
#endif
//Android expect dbm as the rx signal strength unit
#define CONFIG_SIGNAL_DISPLAY_DBM
#endif
#if defined(CONFIG_HAS_EARLYSUSPEND) && defined (CONFIG_RESUME_IN_WORKQUEUE)
#warning "You have CONFIG_HAS_EARLYSUSPEND enabled in your system, we disable CONFIG_RESUME_IN_WORKQUEUE automatically"
#undef CONFIG_RESUME_IN_WORKQUEUE

View file

@ -533,12 +533,6 @@ struct mlme_priv {
#endif
#ifdef RTK_DMP_PLATFORM
// DMP kobject_hotplug function signal need in passive level
_workitem Linkup_workitem;
_workitem Linkdown_workitem;
#endif
#ifdef CONFIG_INTEL_WIDI
int widi_state;
int listen_state;

View file

@ -42,11 +42,7 @@
#elif defined (CONFIG_USB_HCI)
#ifdef CONFIG_USB_TX_AGGREGATION
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#define MAX_XMITBUF_SZ (12288) //12k 1536*8
#else
#define MAX_XMITBUF_SZ (20480) // 20k
#endif
#else
#define MAX_XMITBUF_SZ (2048)
#endif

View file

@ -2470,22 +2470,6 @@ static int cfg80211_rtw_connect(struct wiphy *wiphy, struct net_device *ndev,
goto exit;
}
#ifdef CONFIG_PLATFORM_MSTAR_TITANIA12
printk("MStar Android!\n");
if ((wdev_to_priv(padapter->rtw_wdev))->bandroid_scan == false)
{
#ifdef CONFIG_P2P
struct wifidirect_info *pwdinfo= &(padapter->wdinfo);
if (rtw_p2p_chk_state(pwdinfo, P2P_STATE_NONE))
#endif //CONFIG_P2P
{
ret = -EBUSY;
printk("Android hasn't attached yet!\n");
goto exit;
}
}
#endif
if (_FAIL == rtw_pwr_wakeup(padapter)) {
ret= -EPERM;
goto exit;
@ -2974,18 +2958,14 @@ void rtw_cfg80211_indicate_sta_assoc(_adapter *padapter, u8 *pmgmt_frame, uint f
#else //COMPAT_KERNEL_RELEASE
{
//to avoid WARN_ON(wdev->iftype != NL80211_IFTYPE_STATION) when calling cfg80211_send_rx_assoc()
#ifndef CONFIG_PLATFORM_MSTAR_TITANIA12
pwdev->iftype = NL80211_IFTYPE_STATION;
#endif //CONFIG_PLATFORM_MSTAR_TITANIA12
DBG_88E("iftype=%d before call cfg80211_send_rx_assoc()\n", pwdev->iftype);
rtw_cfg80211_send_rx_assoc(ndev, NULL, pmgmt_frame, frame_len);
DBG_88E("iftype=%d after call cfg80211_send_rx_assoc()\n", pwdev->iftype);
pwdev->iftype = NL80211_IFTYPE_AP;
//cfg80211_rx_action(padapter->pnetdev, freq, pmgmt_frame, frame_len, GFP_ATOMIC);
}
#endif //COMPAT_KERNEL_RELEASE
#endif /* defined(RTW_USE_CFG80211_STA_EVENT) */
}
void rtw_cfg80211_indicate_sta_disassoc(_adapter *padapter, unsigned char *da, unsigned short reason)

View file

@ -687,13 +687,7 @@ static char *translate_scan(_adapter *padapter,
iwe.u.qual.qual = (u8)sq; // signal quality
#ifdef CONFIG_PLATFORM_ROCKCHIPS
iwe.u.qual.noise = -100; // noise level suggest by zhf@rockchips
#else
iwe.u.qual.noise = 0; // noise level
#endif //CONFIG_PLATFORM_ROCKCHIPS
//DBG_88E("iqual=%d, ilevel=%d, inoise=%d, iupdated=%d\n", iwe.u.qual.qual, iwe.u.qual.level , iwe.u.qual.noise, iwe.u.qual.updated);
start = iwe_stream_add_event(info, start, stop, &iwe, IW_EV_QUAL_LEN);
}
@ -718,13 +712,8 @@ static int wpa_set_auth_algs(struct net_device *dev, u32 value)
DBG_88E("wpa_set_auth_algs, AUTH_ALG_SHARED_KEY [value:0x%x]\n",value);
padapter->securitypriv.ndisencryptstatus = Ndis802_11Encryption1Enabled;
#ifdef CONFIG_PLATFORM_MT53XX
padapter->securitypriv.ndisauthtype = Ndis802_11AuthModeAutoSwitch;
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Auto;
#else
padapter->securitypriv.ndisauthtype = Ndis802_11AuthModeShared;
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Shared;
#endif
}
else if (value & AUTH_ALG_OPEN_SYSTEM)
{
@ -732,13 +721,8 @@ static int wpa_set_auth_algs(struct net_device *dev, u32 value)
//padapter->securitypriv.ndisencryptstatus = Ndis802_11EncryptionDisabled;
if (padapter->securitypriv.ndisauthtype < Ndis802_11AuthModeWPAPSK)
{
#ifdef CONFIG_PLATFORM_MT53XX
padapter->securitypriv.ndisauthtype = Ndis802_11AuthModeAutoSwitch;
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Auto;
#else
padapter->securitypriv.ndisauthtype = Ndis802_11AuthModeOpen;
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Open;
#endif
}
}
@ -1513,26 +1497,9 @@ static int rtw_wx_get_sens(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra)
{
#ifdef CONFIG_PLATFORM_ROCKCHIPS
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
struct mlme_priv *pmlmepriv = &(padapter->mlmepriv);
/*
* 20110311 Commented by Jeff
* For rockchip platform's wpa_driver_wext_get_rssi
*/
if (check_fwstate(pmlmepriv, _FW_LINKED) == true) {
//wrqu->sens.value=-padapter->recvpriv.signal_strength;
wrqu->sens.value=-padapter->recvpriv.rssi;
//DBG_88E("%s: %d\n", __func__, wrqu->sens.value);
wrqu->sens.fixed = 0; /* no auto select */
} else
#endif
{
wrqu->sens.value = 0;
wrqu->sens.fixed = 0; /* no auto select */
wrqu->sens.disabled = 1;
}
wrqu->sens.value = 0;
wrqu->sens.fixed = 0; /* no auto select */
wrqu->sens.disabled = 1;
return 0;
}
@ -2745,13 +2712,7 @@ static int rtw_wx_set_enc(struct net_device *dev,
{
DBG_88E("rtw_wx_set_enc():IW_ENCODE_OPEN\n");
padapter->securitypriv.ndisencryptstatus = Ndis802_11Encryption1Enabled;//Ndis802_11EncryptionDisabled;
#ifdef CONFIG_PLATFORM_MT53XX
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Auto;
#else
padapter->securitypriv.dot11AuthAlgrthm= dot11AuthAlgrthm_Open;
#endif
padapter->securitypriv.dot11PrivacyAlgrthm=_NO_PRIVACY_;
padapter->securitypriv.dot118021XGrpPrivacy=_NO_PRIVACY_;
authmode = Ndis802_11AuthModeOpen;
@ -2761,13 +2722,7 @@ static int rtw_wx_set_enc(struct net_device *dev,
{
DBG_88E("rtw_wx_set_enc():IW_ENCODE_RESTRICTED\n");
padapter->securitypriv.ndisencryptstatus = Ndis802_11Encryption1Enabled;
#ifdef CONFIG_PLATFORM_MT53XX
padapter->securitypriv.dot11AuthAlgrthm = dot11AuthAlgrthm_Auto;
#else
padapter->securitypriv.dot11AuthAlgrthm= dot11AuthAlgrthm_Shared;
#endif
padapter->securitypriv.dot11PrivacyAlgrthm=_WEP40_;
padapter->securitypriv.dot118021XGrpPrivacy=_WEP40_;
authmode = Ndis802_11AuthModeShared;
@ -3409,14 +3364,6 @@ static int rtw_wx_set_mtk_wps_probe_ie(struct net_device *dev,
struct iw_request_info *a,
union iwreq_data *wrqu, char *b)
{
#ifdef CONFIG_PLATFORM_MT53XX
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
struct mlme_priv *pmlmepriv = &padapter->mlmepriv;
RT_TRACE(_module_rtl871x_ioctl_os_c, _drv_notice_,
("WLAN IOCTL: cmd_code=%x, fwstate=0x%x\n",
a->cmd, get_fwstate(pmlmepriv)));
#endif
return 0;
}
@ -3424,14 +3371,6 @@ static int rtw_wx_get_sensitivity(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *buf)
{
#ifdef CONFIG_PLATFORM_MT53XX
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
// Modified by Albert 20110914
// This is in dbm format for MTK platform.
wrqu->qual.level = padapter->recvpriv.rssi;
DBG_88E(" level = %u\n", wrqu->qual.level);
#endif
return 0;
}
@ -3439,19 +3378,9 @@ static int rtw_wx_set_mtk_wps_ie(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra)
{
#ifdef CONFIG_PLATFORM_MT53XX
_adapter *padapter = (_adapter *)rtw_netdev_priv(dev);
return rtw_set_wpa_ie(padapter, wrqu->data.pointer, wrqu->data.length);
#else
return 0;
#endif
}
/*
typedef int (*iw_handler)(struct net_device *dev, struct iw_request_info *info,
union iwreq_data *wrqu, char *extra);
*/
/*
* For all data larger than 16 octets, we need to use a
* pointer to memory allocated in user space.
@ -12379,7 +12308,6 @@ static const struct iw_priv_args rtw_private_args[] = {
SIOCIWFIRSTPRIV + 0x6,
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "wps_start"
},
//for PLATFORM_MT53XX
{
SIOCIWFIRSTPRIV + 0x7,
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "get_sensitivity"
@ -12393,7 +12321,6 @@ static const struct iw_priv_args rtw_private_args[] = {
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "wps_assoc_req_ie"
},
//for RTK_DMP_PLATFORM
{
SIOCIWFIRSTPRIV + 0xA,
IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "channel_plan"
@ -12509,12 +12436,10 @@ static iw_handler rtw_private_handler[] =
rtw_set_pid, //0x05
rtw_wps_start, //0x06
// for PLATFORM_MT53XX
rtw_wx_get_sensitivity, //0x07
rtw_wx_set_mtk_wps_probe_ie, //0x08
rtw_wx_set_mtk_wps_ie, //0x09
// for RTK_DMP_PLATFORM
// Set Channel depend on the country code
rtw_wx_set_channel_plan, //0x0A
@ -12594,14 +12519,8 @@ static struct iw_statistics *rtw_get_wireless_stats(struct net_device *dev)
}
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,14))
piwstats->qual.updated = IW_QUAL_ALL_UPDATED ;//|IW_QUAL_DBM;
#else
#ifdef RTK_DMP_PLATFORM
//IW_QUAL_DBM= 0x8, if driver use this flag, wireless extension will show value of dbm.
//remove this flag for show percentage 0~100
piwstats->qual.updated = 0x07;
#else
piwstats->qual.updated = 0x0f;
#endif
#endif
#ifdef CONFIG_SIGNAL_DISPLAY_DBM

View file

@ -26,57 +26,6 @@
#include <drv_types.h>
#include <mlme_osdep.h>
#ifdef RTK_DMP_PLATFORM
void Linkup_workitem_callback(struct work_struct *work)
{
struct mlme_priv *pmlmepriv = container_of(work, struct mlme_priv, Linkup_workitem);
_adapter *padapter = container_of(pmlmepriv, _adapter, mlmepriv);
_func_enter_;
RT_TRACE(_module_mlme_osdep_c_,_drv_info_,("+ Linkup_workitem_callback\n"));
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12))
kobject_uevent(&padapter->pnetdev->dev.kobj, KOBJ_LINKUP);
#else
kobject_hotplug(&padapter->pnetdev->class_dev.kobj, KOBJ_LINKUP);
#endif
_func_exit_;
}
void Linkdown_workitem_callback(struct work_struct *work)
{
struct mlme_priv *pmlmepriv = container_of(work, struct mlme_priv, Linkdown_workitem);
_adapter *padapter = container_of(pmlmepriv, _adapter, mlmepriv);
_func_enter_;
RT_TRACE(_module_mlme_osdep_c_,_drv_info_,("+ Linkdown_workitem_callback\n"));
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12))
kobject_uevent(&padapter->pnetdev->dev.kobj, KOBJ_LINKDOWN);
#else
kobject_hotplug(&padapter->pnetdev->class_dev.kobj, KOBJ_LINKDOWN);
#endif
_func_exit_;
}
#endif
/*
void sitesurvey_ctrl_handler(void *FunctionContext)
{
_adapter *adapter = (_adapter *)FunctionContext;
_sitesurvey_ctrl_handler(adapter);
_set_timer(&adapter->mlmepriv.sitesurveyctrl.sitesurvey_ctrl_timer, 3000);
}
*/
void rtw_join_timeout_handler (void *FunctionContext)
{
_adapter *adapter = (_adapter *)FunctionContext;
@ -127,10 +76,6 @@ void rtw_init_mlme_timer(_adapter *padapter)
_init_timer(&(pmlmepriv->set_scan_deny_timer), padapter->pnetdev, _rtw_set_scan_deny_timer_hdl, padapter);
#endif
#ifdef RTK_DMP_PLATFORM
_init_workitem(&(pmlmepriv->Linkup_workitem), Linkup_workitem_callback, padapter);
_init_workitem(&(pmlmepriv->Linkdown_workitem), Linkdown_workitem_callback, padapter);
#endif
#if defined(CONFIG_CHECK_BT_HANG) && defined(CONFIG_BT_COEXIST)
if (padapter->HalFunc.hal_init_checkbthang_workqueue)
padapter->HalFunc.hal_init_checkbthang_workqueue(padapter);
@ -152,9 +97,6 @@ _func_enter_;
if (adapter->pid[2] !=0)
rtw_signal_process(adapter->pid[2], SIGALRM);
#ifdef RTK_DMP_PLATFORM
_set_workitem(&adapter->mlmepriv.Linkup_workitem);
#endif
_func_exit_;
@ -238,9 +180,6 @@ _func_enter_;
rtw_indicate_wx_disassoc_event(adapter);
#ifdef RTK_DMP_PLATFORM
_set_workitem(&adapter->mlmepriv.Linkdown_workitem);
#endif
rtw_reset_securitypriv( adapter );
_func_exit_;

View file

@ -1828,9 +1828,7 @@ int _netdev_open(struct net_device *pnetdev)
if (padapter->intf_start)
padapter->intf_start(padapter);
#ifndef RTK_DMP_PLATFORM
rtw_proc_init_one(pnetdev);
#endif
#ifdef CONFIG_IOCTL_CFG80211
rtw_cfg80211_init_wiphy(padapter);

View file

@ -27,11 +27,6 @@
#include <recv_osdep.h>
#include <linux/vmalloc.h>
#include <rtw_ioctl_set.h>
#ifdef RTK_DMP_PLATFORM
#if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,12))
#include <linux/pageremap.h>
#endif
#endif
/*
* Translate the OS dependent @param error_code to OS independent RTW_STATUS_CODE
@ -93,13 +88,7 @@ u8* _rtw_malloc(u32 sz)
{
u8 *pbuf=NULL;
#ifdef RTK_DMP_PLATFORM
if (sz > 0x4000)
pbuf = (u8 *)dvr_malloc(sz);
else
#endif
pbuf = kmalloc(sz,in_interrupt() ? GFP_ATOMIC : GFP_KERNEL);
pbuf = kmalloc(sz,in_interrupt() ? GFP_ATOMIC : GFP_KERNEL);
return pbuf;
}
@ -114,11 +103,6 @@ u8* _rtw_zmalloc(u32 sz)
void _rtw_mfree(u8 *pbuf, u32 sz)
{
#ifdef RTK_DMP_PLATFORM
if (sz > 0x4000)
dvr_free(pbuf);
else
#endif
kfree(pbuf);
}
@ -799,13 +783,6 @@ error:
}
#ifdef CONFIG_PLATFORM_SPRD
#ifdef do_div
#undef do_div
#endif
#include <asm-generic/div64.h>
#endif
u64 rtw_modular64(u64 x, u64 y)
{
return do_div(x, y);

View file

@ -385,17 +385,9 @@ int rtw_android_priv_cmd(struct net_device *net, struct ifreq *ifr, int cmd)
break;
case ANDROID_WIFI_CMD_SCAN_ACTIVE:
//rtw_set_scan_mode((_adapter *)rtw_netdev_priv(net), SCAN_ACTIVE);
#ifdef CONFIG_PLATFORM_MSTAR_TITANIA12
#ifdef CONFIG_IOCTL_CFG80211
(wdev_to_priv(net->ieee80211_ptr))->bandroid_scan = true;
#endif //CONFIG_IOCTL_CFG80211
#endif //CONFIG_PLATFORM_MSTAR_TITANIA12
break;
case ANDROID_WIFI_CMD_SCAN_PASSIVE:
//rtw_set_scan_mode((_adapter *)rtw_netdev_priv(net), SCAN_PASSIVE);
break;
case ANDROID_WIFI_CMD_RSSI:
bytes_written = rtw_android_get_rssi(net, command, priv_cmd.total_len);
break;

View file

@ -34,9 +34,6 @@
#include <usb_osintf.h>
#include <usb_hal.h>
#include <rtw_ioctl.h>
#ifdef CONFIG_PLATFORM_RTK_DMP
#include <asm/io.h>
#endif
#ifdef CONFIG_GLOBAL_UI_PID
int ui_pid[3] = {0, 0, 0};
@ -274,10 +271,6 @@ static struct specific_device_id specific_device_id_tbl[] = {
{.idVendor=0x0b05, .idProduct=0x1791, .flags=SPEC_DEV_ID_DISABLE_HT},
{.idVendor=0x13D3, .idProduct=0x3311, .flags=SPEC_DEV_ID_DISABLE_HT},
{.idVendor=0x13D3, .idProduct=0x3359, .flags=SPEC_DEV_ID_DISABLE_HT},//Russian customer -Azwave (8188CE-VAU g mode)
#ifdef RTK_DMP_PLATFORM
{.idVendor=USB_VENDER_ID_REALTEK, .idProduct=0x8111, .flags=SPEC_DEV_ID_ASSIGN_IFNAME}, // Realtek 5G dongle for WiFi Display
{.idVendor=0x2019, .idProduct=0xAB2D, .flags=SPEC_DEV_ID_ASSIGN_IFNAME}, // PCI-Abocom 5G dongle for WiFi Display
#endif /* RTK_DMP_PLATFORM */
{}
};
@ -727,17 +720,6 @@ static void process_spec_devid(const struct usb_device_id *pdid)
}
#endif
#ifdef RTK_DMP_PLATFORM
// Change the ifname to wlan10 when PC side WFD dongle plugin on DMP platform.
// It is used to distinguish between normal and PC-side wifi dongle/module.
if ((pdid->idVendor==vid) && (pdid->idProduct==pid) && (flags&SPEC_DEV_ID_ASSIGN_IFNAME))
{
extern char* ifname;
strncpy(ifname, "wlan10", 6);
//DBG_88E("%s()-%d: ifname=%s, vid=%04X, pid=%04X\n", __func__, __LINE__, ifname, vid, pid);
}
#endif /* RTK_DMP_PLATFORM */
}
}
@ -1266,17 +1248,6 @@ error_exit:
}
#endif
#ifdef CONFIG_PLATFORM_RTD2880B
extern void rtd2885_wlan_netlink_sendMsg(char *action_string, char *name);
#endif
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#include <mach/sys_config.h>
extern int sw_usb_disable_hcd(__u32 usbc_no);
extern int sw_usb_enable_hcd(__u32 usbc_no);
static int usb_wifi_host = 2;
#endif
/*
* drv_init() - a device potentially for us
*
@ -1428,21 +1399,12 @@ static _adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj,
hostapd_mode_init(padapter);
#endif
#ifdef CONFIG_PLATFORM_RTD2880B
DBG_88E("wlan link up\n");
rtd2885_wlan_netlink_sendMsg("linkup", "8712");
#endif
//step 6. /* Tell the network stack we exist */
if (register_netdev(pnetdev) != 0) {
RT_TRACE(_module_hci_intfs_c_,_drv_err_,("register_netdev() failed\n"));
goto free_hal_data;
}
#ifdef RTK_DMP_PLATFORM
rtw_proc_init_one(pnetdev);
#endif
DBG_88E("bDriverStopped:%d, bSurpriseRemoved:%d, bup:%d, hw_init_completed:%d\n"
, padapter->bDriverStopped
, padapter->bSurpriseRemoved
@ -1534,12 +1496,6 @@ static void rtw_usb_if1_deinit(_adapter *if1)
if (pnetdev)
rtw_free_netdev(pnetdev);
#ifdef CONFIG_PLATFORM_RTD2880B
DBG_88E("wlan link down\n");
rtd2885_wlan_netlink_sendMsg("linkdown", "8712");
#endif
}
static void dump_usb_interface(struct usb_interface *usb_intf)
@ -1790,38 +1746,11 @@ extern int console_suspend_enabled;
static int __init rtw_drv_entry(void)
{
#ifdef CONFIG_PLATFORM_RTK_DMP
u32 tmp;
tmp=readl((volatile unsigned int*)0xb801a608);
tmp &= 0xffffff00;
tmp |= 0x55;
writel(tmp,(volatile unsigned int*)0xb801a608);//write dummy register for 1055
#endif
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#ifndef CONFIG_RTL8723A
int ret = 0;
/* ----------get usb_wifi_usbc_num------------- */
ret = script_parser_fetch("usb_wifi_para", "usb_wifi_usbc_num", (int *)&usb_wifi_host, 64);
if (ret != 0){
DBG_88E("ERR: script_parser_fetch usb_wifi_usbc_num failed\n");
ret = -ENOMEM;
return ret;
}
DBG_88E("sw_usb_enable_hcd: usbc_num = %d\n", usb_wifi_host);
sw_usb_enable_hcd(usb_wifi_host);
#endif //CONFIG_RTL8723A
#endif //CONFIG_PLATFORM_ARM_SUNxI
RT_TRACE(_module_hci_intfs_c_,_drv_err_,("+rtw_drv_entry\n"));
DBG_88E(DRV_NAME " driver version=%s\n", DRIVERVERSION);
DBG_88E("build time: %s %s\n", __DATE__, __TIME__);
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,24))
//console_suspend_enabled=0;
#endif
rtw_suspend_lock_init();
_rtw_mutex_init(&usb_drv->hw_init_mutex);
@ -1852,13 +1781,6 @@ static void __exit rtw_drv_halt(void)
_rtw_mutex_free(&usb_drv->setch_mutex);
_rtw_mutex_free(&usb_drv->setbw_mutex);
#endif
#ifdef CONFIG_PLATFORM_ARM_SUNxI
#ifndef CONFIG_RTL8723A
DBG_88E("sw_usb_disable_hcd: usbc_num = %d\n", usb_wifi_host);
sw_usb_disable_hcd(usb_wifi_host);
#endif //ifndef CONFIG_RTL8723A
#endif //CONFIG_PLATFORM_ARM_SUNxI
DBG_88E("-rtw_drv_halt\n");
}