diff --git a/Makefile b/Makefile index ee4c420..fc92d8d 100755 --- a/Makefile +++ b/Makefile @@ -33,42 +33,6 @@ CONFIG_GPIO_WAKEUP = n CONFIG_ODM_ADAPTIVITY = n CONFIG_MMC_PM_KEEP_POWER = n -CONFIG_PLATFORM_I386_PC = y -CONFIG_PLATFORM_ANDROID_X86 = n -CONFIG_PLATFORM_JB_X86 = n -CONFIG_PLATFORM_ARM_S3C2K4 = n -CONFIG_PLATFORM_ARM_PXA2XX = n -CONFIG_PLATFORM_ARM_S3C6K4 = n -CONFIG_PLATFORM_MIPS_RMI = n -CONFIG_PLATFORM_RTD2880B = n -CONFIG_PLATFORM_MIPS_AR9132 = n -CONFIG_PLATFORM_RTK_DMP = n -CONFIG_PLATFORM_MIPS_PLM = n -CONFIG_PLATFORM_MSTAR389 = n -CONFIG_PLATFORM_MT53XX = n -CONFIG_PLATFORM_ARM_MX51_241H = n -CONFIG_PLATFORM_ACTIONS_ATJ227X = n -CONFIG_PLATFORM_TEGRA3_CARDHU = n -CONFIG_PLATFORM_TEGRA4_DALMORE = n -CONFIG_PLATFORM_ARM_TCC8900 = n -CONFIG_PLATFORM_ARM_TCC8920 = n -CONFIG_PLATFORM_ARM_TCC8920_JB42 = n -CONFIG_PLATFORM_ARM_RK2818 = n -CONFIG_PLATFORM_ARM_URBETTER = n -CONFIG_PLATFORM_ARM_TI_PANDA = n -CONFIG_PLATFORM_MIPS_JZ4760 = n -CONFIG_PLATFORM_DMP_PHILIPS = n -CONFIG_PLATFORM_TI_DM365 = n -CONFIG_PLATFORM_MSTAR_TITANIA12 = n -CONFIG_PLATFORM_MSTAR = n -CONFIG_PLATFORM_SZEBOOK = n -CONFIG_PLATFORM_ARM_SUNxI = n -CONFIG_PLATFORM_ARM_SUN6I = n -CONFIG_PLATFORM_ARM_SUN7I = n -CONFIG_PLATFORM_ACTIONS_ATM702X = n -CONFIG_PLATFORM_MN10300 = n -CONFIG_PLATFORM_ACTIONS_ATV5201 = n - CONFIG_DRVEXT_MODULE = n export TopDIR ?= $(shell pwd) @@ -195,8 +159,6 @@ ifeq ($(CONFIG_EFUSE_CONFIG_FILE), y) EXTRA_CFLAGS += -DCONFIG_RF_GAIN_OFFSET endif -ifeq ($(CONFIG_PLATFORM_I386_PC), y) -EXTRA_CFLAGS += -DCONFIG_IOCTL_CFG80211 -DRTW_USE_CFG80211_STA_EVENT SUBARCH := $(shell uname -m | sed -e s/i.86/i386/ | sed -e s/ppc/powerpc/ | sed -e s/armv.l/arm/) ARCH ?= $(SUBARCH) CROSS_COMPILE ?= @@ -204,237 +166,6 @@ 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_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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_LITTLE_ENDIAN -DCONFIG_PLATFORM_MSTAR -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_MSTAR), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -DCONFIG_PLATFORM_MSTAR -ARCH:=arm -CROSS_COMPILE:= /usr/src/bin/arm-none-linux-gnueabi- -KVER:= 3.1.10 -KSRC:= /usr/src/Mstar_kernel/3.1.10/ -endif - -ifeq ($(CONFIG_PLATFORM_ANDROID_X86), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -SUBARCH := $(shell uname -m | sed -e s/i.86/i386/) -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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_BIG_ENDIAN -DCONFIG_PLATFORM_RTD2880B -ARCH:= -CROSS_COMPILE:= -KVER:= -KSRC:= -endif - -ifeq ($(CONFIG_PLATFORM_MIPS_RMI), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -ARCH:=mips -CROSS_COMPILE:=mipsisa32r2-uclibc- -KVER:= -KSRC:= /root/work/kernel_realtek -endif - -ifeq ($(CONFIG_PLATFORM_MIPS_PLM), y) -EXTRA_CFLAGS += -DCONFIG_BIG_ENDIAN -ARCH:=mips -CROSS_COMPILE:=mipsisa32r2-uclibc- -KVER:= -KSRC:= /root/work/kernel_realtek -endif - -ifeq ($(CONFIG_PLATFORM_MSTAR389), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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) -EXTRA_CFLAGS += -DCONFIG_BIG_ENDIAN -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 += -DCONFIG_LITTLE_ENDIAN -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 += -DCONFIG_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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_ARM_TCC8900), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -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_LITTLE_ENDIAN -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN #-DCONFIG_MINIMAL_MEMORY_USAGE -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN #-DCONFIG_MINIMAL_MEMORY_USAGE -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) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -DCONFIG_MINIMAL_MEMORY_USAGE -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) -EXTRA_CFLAGS += -DCONFIG_BIG_ENDIAN -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_LITTLE_ENDIAN -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_ACTIONS_ATV5201), y) -EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN -DCONFIG_PLATFORM_ACTIONS_ATV5201 -ARCH := mips -CROSS_COMPILE := mipsel-linux-gnu- -KVER := $(KERNEL_VER) -KSRC:= $(CFGDIR)/../../kernel/linux-$(KERNEL_VER) -endif ifneq ($(USER_MODULE_NAME),) MODULE_NAME := $(USER_MODULE_NAME) diff --git a/include/ioctl_cfg80211.h b/include/ioctl_cfg80211.h index cf1d8e5..7ffad94 100755 --- a/include/ioctl_cfg80211.h +++ b/include/ioctl_cfg80211.h @@ -20,11 +20,6 @@ #ifndef __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 { u8 state; /* 0: req, 1:rep */ u8 peer_mac[ETH_ALEN]; diff --git a/os_dep/ioctl_cfg80211.c b/os_dep/ioctl_cfg80211.c index f423929..2945104 100755 --- a/os_dep/ioctl_cfg80211.c +++ b/os_dep/ioctl_cfg80211.c @@ -3151,7 +3151,6 @@ void rtw_cfg80211_indicate_sta_assoc(struct adapter *padapter, u8 *pmgmt_frame, DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); -#if defined(RTW_USE_CFG80211_STA_EVENT) || defined(COMPAT_KERNEL_RELEASE) { struct station_info sinfo; u8 ie_offset; @@ -3161,39 +3160,10 @@ void rtw_cfg80211_indicate_sta_assoc(struct adapter *padapter, u8 *pmgmt_frame, ie_offset = _REASOCREQ_IE_OFFSET_; sinfo.filled = 0; -/* if (LINUX_VERSION_CODE < KERNEL_VERSION(3, 20, 0)) */ -/* sinfo.filled = STATION_INFO_ASSOC_REQ_IES; */ -/* endif */ sinfo.assoc_req_ies = pmgmt_frame + WLAN_HDR_A3_LEN + ie_offset; sinfo.assoc_req_ies_len = frame_len - WLAN_HDR_A3_LEN - ie_offset; cfg80211_new_sta(ndev, GetAddr2Ptr(pmgmt_frame), &sinfo, GFP_ATOMIC); } -#else /* defined(RTW_USE_CFG80211_STA_EVENT) */ - channel = pmlmeext->cur_channel; - if (channel <= RTW_CH_MAX_2G_CHANNEL) - freq = rtw_ieee80211_channel_to_frequency(channel, IEEE80211_BAND_2GHZ); - else - freq = rtw_ieee80211_channel_to_frequency(channel, IEEE80211_BAND_5GHZ); - - #ifdef COMPAT_KERNEL_RELEASE - rtw_cfg80211_rx_mgmt(padapter, freq, 0, pmgmt_frame, frame_len, GFP_ATOMIC); - #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) - rtw_cfg80211_rx_mgmt(padapter, freq, 0, pmgmt_frame, frame_len, GFP_ATOMIC); - #else /* COMPAT_KERNEL_RELEASE */ - { - /* to avoid WARN_ON(wdev->iftype != NL80211_IFTYPE_STATION) when calling cfg80211_send_rx_assoc() */ - #ifndef CONFIG_PLATFORM_MSTAR - pwdev->iftype = NL80211_IFTYPE_STATION; - #endif /* CONFIG_PLATFORM_MSTAR */ - DBG_8192C("iftype=%d before call cfg80211_send_rx_assoc()\n", pwdev->iftype); - rtw_cfg80211_send_rx_assoc(padapter, NULL, pmgmt_frame, frame_len); - DBG_8192C("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(struct adapter *padapter, unsigned char *da, unsigned short reason) @@ -3211,46 +3181,7 @@ void rtw_cfg80211_indicate_sta_disassoc(struct adapter *padapter, unsigned char DBG_871X(FUNC_ADPT_FMT"\n", FUNC_ADPT_ARG(padapter)); -#if defined(RTW_USE_CFG80211_STA_EVENT) || defined(COMPAT_KERNEL_RELEASE) cfg80211_del_sta(ndev, da, GFP_ATOMIC); -#else /* defined(RTW_USE_CFG80211_STA_EVENT) */ - channel = pmlmeext->cur_channel; - if (channel <= RTW_CH_MAX_2G_CHANNEL) - freq = rtw_ieee80211_channel_to_frequency(channel, IEEE80211_BAND_2GHZ); - else - freq = rtw_ieee80211_channel_to_frequency(channel, IEEE80211_BAND_5GHZ); - - pmgmt_frame = mgmt_buf; - pwlanhdr = (struct rtw_ieee80211_hdr *)pmgmt_frame; - - fctrl = &(pwlanhdr->frame_ctl); - *(fctrl) = 0; - - /* memcpy(pwlanhdr->addr1, da, ETH_ALEN); */ - /* memcpy(pwlanhdr->addr2, myid(&(padapter->eeprompriv)), ETH_ALEN); */ - memcpy(pwlanhdr->addr1, myid(&(padapter->eeprompriv)), ETH_ALEN); - memcpy(pwlanhdr->addr2, da, ETH_ALEN); - memcpy(pwlanhdr->addr3, get_my_bssid(&(pmlmeinfo->network)), ETH_ALEN); - - SetSeqNum(pwlanhdr, pmlmeext->mgnt_seq); - pmlmeext->mgnt_seq++; - SetFrameSubType(pmgmt_frame, WIFI_DEAUTH); - - pmgmt_frame += sizeof(struct rtw_ieee80211_hdr_3addr); - frame_len = sizeof(struct rtw_ieee80211_hdr_3addr); - - reason = cpu_to_le16(reason); - pmgmt_frame = rtw_set_fixed_ie(pmgmt_frame, _RSON_CODE_ , (unsigned char *)&reason, &frame_len); - - #ifdef COMPAT_KERNEL_RELEASE - rtw_cfg80211_rx_mgmt(padapter, freq, 0, mgmt_buf, frame_len, GFP_ATOMIC); - #elif (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)) && !defined(CONFIG_CFG80211_FORCE_COMPATIBLE_2_6_37_UNDER) - rtw_cfg80211_rx_mgmt(padapter, freq, 0, mgmt_buf, frame_len, GFP_ATOMIC); - #else /* COMPAT_KERNEL_RELEASE */ - cfg80211_send_disassoc(padapter->pnetdev, mgmt_buf, frame_len); - /* cfg80211_rx_action(padapter->pnetdev, freq, mgmt_buf, frame_len, GFP_ATOMIC); */ - #endif /* COMPAT_KERNEL_RELEASE */ -#endif /* defined(RTW_USE_CFG80211_STA_EVENT) */ } static int rtw_cfg80211_monitor_if_open(struct net_device *ndev)