mac80211: sync with trunk (as of r25965)
authorFelix Fietkau <nbd@openwrt.org>
Wed, 9 Mar 2011 03:42:02 +0000 (03:42 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Wed, 9 Mar 2011 03:42:02 +0000 (03:42 +0000)
SVN-Revision: 25966

33 files changed:
package/mac80211/Makefile
package/mac80211/patches/001-disable_b44.patch
package/mac80211/patches/002-disable_rfkill.patch
package/mac80211/patches/005-disable_ssb_build.patch
package/mac80211/patches/007-remove_misc_drivers.patch
package/mac80211/patches/010-no_pcmcia.patch
package/mac80211/patches/011-no_sdio.patch
package/mac80211/patches/013-disable_b43_nphy.patch
package/mac80211/patches/015-remove-rt2x00-options.patch
package/mac80211/patches/017-remove_ath9k_rc.patch
package/mac80211/patches/019-remove_ath5k_pci_option.patch
package/mac80211/patches/030-backport_93c86_eeprom.patch
package/mac80211/patches/050-fix_missing_include.patch [new file with mode: 0644]
package/mac80211/patches/060-fix_zd1211_defines.patch [new file with mode: 0644]
package/mac80211/patches/110-disable_usb_compat.patch
package/mac80211/patches/120-pr_fmt_warnings.patch
package/mac80211/patches/300-ath9k_gpio_settings.patch
package/mac80211/patches/407-ath9k-override-mac-address-from-platform-data.patch
package/mac80211/patches/409-ath9k_platform_settings.patch
package/mac80211/patches/510-ath9k_led_cleanup.patch
package/mac80211/patches/520-ath9k_intr_mitigation_tweak.patch
package/mac80211/patches/530-mac80211_drv_tim_override.patch
package/mac80211/patches/531-ath9k_fix_ap_ps_buffering.patch
package/mac80211/patches/532-ath9k_remove_pending_frames_workaround.patch
package/mac80211/patches/540-mac80211_add_rx_rate.patch
package/mac80211/patches/550-ath9k_fix_interrupts.patch [deleted file]
package/mac80211/patches/550-ath9k_no_vif_promisc_handling.patch [new file with mode: 0644]
package/mac80211/patches/560-mac80211_minstrel_ht_sampling_fix.patch [new file with mode: 0644]
package/mac80211/patches/700-mwl8k-missing-pci-id-for-WNR854T.patch
package/mac80211/patches/710-p54_rssi_crash_fix.patch [new file with mode: 0644]
package/mac80211/patches/720-mac80211-print-restart-warning.patch [new file with mode: 0644]
package/mac80211/patches/721-mac80211-fix-scan-race.patch [new file with mode: 0644]
package/mac80211/patches/800-b43-gpio-mask-module-option.patch

index b07ccdeee2bc00c0ebe78cc49edd86c9b5539360..5e49c810b3fe650e8333b93b58e8264b3b827111 100644 (file)
@@ -10,10 +10,10 @@ include $(INCLUDE_DIR)/kernel.mk
 
 PKG_NAME:=mac80211
 
-PKG_VERSION:=2011-02-07
+PKG_VERSION:=2011-02-25
 PKG_RELEASE:=1
 PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources
-PKG_MD5SUM:=a194610426c81ed5ad71ee83330c9669
+PKG_MD5SUM:=c0242cc152a157902ff60fe05d1773b2
 
 PKG_SOURCE:=compat-wireless-$(PKG_VERSION).tar.bz2
 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION)
@@ -64,6 +64,8 @@ define KernelPackage/mac80211
   $(call KernelPackage/mac80211/Default)
   TITLE:=Linux 802.11 Wireless Networking Stack
   DEPENDS+= +kmod-crypto-core +kmod-crypto-arc4 +kmod-crypto-aes +kmod-cfg80211
+  KCONFIG:=\
+       CONFIG_AVERAGE=y
   FILES:= $(PKG_BUILD_DIR)/net/mac80211/mac80211.ko
   AUTOLOAD:=$(call AutoLoad,21,mac80211)
   MENU:=1
@@ -880,8 +882,7 @@ BUILDFLAGS:= \
        $(if $(CONFIG_PACKAGE_kmod-rt2x00-pci),-DCONFIG_RT2X00_LIB_PCI) \
        $(if $(CONFIG_PACKAGE_kmod-rt2x00-usb),-DCONFIG_RT2X00_LIB_USB) \
        $(if $(CONFIG_PACKAGE_kmod-rt2x00-soc),-DCONFIG_RT2X00_LIB_SOC) \
-       $(if $(CONFIG_TARGET_atheros),-DCONFIG_ATH5K_AHB,-DCONFIG_ATH5K_PCI) \
-       -DCONFIG_P54_SPI_DEFAULT_EEPROM
+       $(if $(CONFIG_TARGET_atheros),-DCONFIG_ATH5K_AHB,-DCONFIG_ATH5K_PCI)
 
 MAKE_OPTS:= \
        CROSS_COMPILE="$(KERNEL_CROSS)" \
@@ -919,7 +920,7 @@ MAKE_OPTS:= \
        CONFIG_P54_PCI=$(if $(CONFIG_PACKAGE_kmod-p54-pci),m) \
        CONFIG_P54_USB=$(if $(CONFIG_PACKAGE_kmod-p54-usb),m) \
        CONFIG_P54_SPI=$(if $(CONFIG_PACKAGE_kmod-p54-spi),m) \
-       CONFIG_P54_SPI_DEFAULT_EEPROM=y \
+       CONFIG_P54_SPI_DEFAULT_EEPROM=n \
        CONFIG_RT2X00=$(if $(CONFIG_PACKAGE_kmod-rt2x00-lib),m) \
        CONFIG_RT2X00_LIB=$(if $(CONFIG_PACKAGE_kmod-rt2x00-lib),m) \
        CONFIG_RT2X00_LIB_PCI=$(if $(CONFIG_PACKAGE_kmod-rt2x00-pci),m) \
@@ -941,6 +942,7 @@ MAKE_OPTS:= \
        CONFIG_RTL8180=$(if $(CONFIG_PACKAGE_kmod-rtl8180),m) \
        CONFIG_RTL8187=$(if $(CONFIG_PACKAGE_kmod-rtl8187),m) \
        CONFIG_RTL8192CE= \
+       CONFIG_RTLWIFI= \
        CONFIG_MAC80211_HWSIM=$(if $(CONFIG_PACKAGE_kmod-mac80211-hwsim),m) \
        CONFIG_PCMCIA= \
        CONFIG_LIBIPW=$(if $(CONFIG_PACKAGE_kmod-net-libipw),m) \
@@ -958,6 +960,7 @@ MAKE_OPTS:= \
        CONFIG_LIB80211_CRYPT_CCMP= \
        CONFIG_LIB80211_CRYPT_TKIP= \
        CONFIG_COMPAT_IWLWIFI= \
+       CONFIG_IWLWIFI_LEGACY= \
        CONFIG_IWLAGN= \
        CONFIG_MWL8K=$(if $(CONFIG_PACKAGE_kmod-mwl8k),m) \
        CONFIG_ATMEL= \
index 017c8f98a1aaecac34953b3f4d4dc91761845a88..50000c012a8e80e036efe2155257ea124f91597a 100644 (file)
@@ -1,6 +1,6 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -311,8 +311,8 @@ endif #CONFIG_SSB
+@@ -316,8 +316,8 @@ endif #CONFIG_SSB
  
  CONFIG_P54_PCI=m
  
index c0e47f61a3e25792a94fec7c57c1c4c7aa471c73..2f1eac709ea254384722a918c1336a06a7393048 100644 (file)
@@ -9,7 +9,7 @@
  
  ifeq ($(CONFIG_MAC80211),y)
  $(error "ERROR: you have MAC80211 compiled into the kernel, CONFIG_MAC80211=y, as such you cannot replace its mac80211 driver. You need this set to CONFIG_MAC80211=m. If you are using Fedora upgrade your kernel as later version should this set as modular. For further information on Fedora see https://bugzilla.redhat.com/show_bug.cgi?id=470143. If you are using your own kernel recompile it and make mac80211 modular")
-@@ -613,10 +613,10 @@ endif #CONFIG_COMPAT_KERNEL_27
+@@ -623,10 +623,10 @@ endif #CONFIG_COMPAT_KERNEL_27
  # We need the backported rfkill module on kernel < 2.6.31.
  # In more recent kernel versions use the in kernel rfkill module.
  ifdef CONFIG_COMPAT_KERNEL_31
index e2744d9206a4b9f5406833854f336b79f8baa30f..fdfaf507eb6d34772531efb278f6806479cc4fbd 100644 (file)
@@ -19,7 +19,7 @@
  else
  include $(KLIB_BUILD)/.config
  endif
-@@ -295,19 +294,18 @@ CONFIG_IPW2200_QOS=y
+@@ -300,19 +299,18 @@ CONFIG_IPW2200_QOS=y
  # % echo 1 > /sys/bus/pci/drivers/ipw2200/*/rtap_iface
  endif #CONFIG_WIRELESS_EXT
  
@@ -51,7 +51,7 @@
  
  CONFIG_P54_PCI=m
  
-@@ -505,7 +503,6 @@ endif #CONFIG_SPI_MASTER end of SPI driv
+@@ -514,7 +512,6 @@ endif #CONFIG_SPI_MASTER end of SPI driv
  
  ifdef CONFIG_MMC
  
index bf7ecbd01167742a943dcde755fe8a5422ce6377..e4504e1352a406bc51b07983a97fe6825cae968d 100644 (file)
@@ -1,6 +1,6 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -202,7 +202,7 @@ $(warning "WARNING: CONFIG_CFG80211_WEXT
+@@ -204,7 +204,7 @@ $(warning "WARNING: CONFIG_CFG80211_WEXT
  endif #CONFIG_WIRELESS_EXT
  
  ifneq ($(CONFIG_STAGING),)
@@ -9,7 +9,7 @@
  endif
  
  # mac80211 test driver
-@@ -336,13 +336,13 @@ endif #CONFIG_CRC_ITU_T
+@@ -342,13 +342,13 @@ endif #CONFIG_CRC_ITU_T
  CONFIG_MWL8K=m
  
  # Ethernet drivers go here
@@ -28,7 +28,7 @@
  endif #CONFIG_COMPAT_KERNEL_27
  
  ifdef CONFIG_WIRELESS_EXT
-@@ -396,21 +396,21 @@ CONFIG_ZD1211RW=m
+@@ -403,21 +403,21 @@ endif #CONFIG_COMPAT_KERNEL_29
  # Note: this depends on CONFIG_USB_NET_RNDIS_HOST and CONFIG_USB_NET_CDCETHER
  # it also requires new RNDIS_HOST and CDC_ETHER modules which we add
  ifdef CONFIG_COMPAT_KERNEL_29
index c7457c856b40e1b6166af7b23470ba9538ac20d8..7a2181f60962b2138e2b3c995b21572a5871427d 100644 (file)
@@ -9,7 +9,7 @@
  else
  include $(KLIB_BUILD)/.config
  endif
-@@ -229,7 +229,7 @@ CONFIG_B43=m
+@@ -234,7 +234,7 @@ CONFIG_B43=m
  CONFIG_B43_HWRNG=y
  CONFIG_B43_PCI_AUTOSELECT=y
  ifdef CONFIG_PCMCIA
index 3bb20306118e7ee4d9aaf52862bb21e46ccc4aa1..65b0e7fa89475841f5e101ddfe4acf9b3db33e74 100644 (file)
@@ -1,6 +1,6 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -486,7 +486,7 @@ endif #CONFIG_SPI_MASTER end of SPI driv
+@@ -495,7 +495,7 @@ endif #CONFIG_SPI_MASTER end of SPI driv
  
  ifdef CONFIG_MMC
  
index b5c47593feac4b662d1b314d72ee5dc6b2fd462e..a973b7ae2f08610bc6d206fedc240f247e3e881a 100644 (file)
@@ -1,6 +1,6 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -235,7 +235,7 @@ ifdef CONFIG_MAC80211_LEDS
+@@ -240,7 +240,7 @@ ifdef CONFIG_MAC80211_LEDS
  CONFIG_B43_LEDS=y
  endif #CONFIG_MAC80211_LEDS
  CONFIG_B43_PHY_LP=y
index 768c61cfc912fc326a76769428d9389f41cf2b8f..a03504f33967f7fb7b98fc15c4047b3ddbc2b40d 100644 (file)
@@ -1,6 +1,6 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -299,7 +299,7 @@ CONFIG_RTL8180=m
+@@ -304,7 +304,7 @@ CONFIG_RTL8180=m
  
  CONFIG_ADM8211=m
  
@@ -9,7 +9,7 @@
  CONFIG_RT2400PCI=m
  CONFIG_RT2500PCI=m
  ifdef CONFIG_CRC_CCITT
-@@ -437,7 +437,7 @@ CONFIG_RT2800USB=m
+@@ -444,7 +444,7 @@ CONFIG_RT2800USB=m
  # CONFIG_RT2800USB_RT35XX=y
  CONFIG_RT2800USB_UNKNOWN=y
  endif #CONFIG_CRC_CCITT
index 7b7304aab9ae4bedfa6751d3e9987310174acdd7..4f46ee2bc11681291ace06f1e44aa60da788339e 100644 (file)
@@ -1,11 +1,11 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -212,7 +212,7 @@ CONFIG_ATH9K_COMMON=m
+@@ -207,7 +207,7 @@ CONFIG_ATH9K_COMMON=m
  # as default once we get minstrel properly tested and blessed by
  # our systems engineering team. CCK rates also need to be used
  # for long range considerations.
 -CONFIG_ATH9K_RATE_CONTROL=y
 +# CONFIG_ATH9K_RATE_CONTROL=y
  
- CONFIG_COMPAT_IWLWIFI=m
+ # PCI Drivers
+ ifdef CONFIG_PCI
index a9bc153b2228e61c849beca2df1992c537d52c6d..192527d37951ad4c060bfde3b8b675fcef3ab627 100644 (file)
@@ -1,11 +1,11 @@
 --- a/config.mk
 +++ b/config.mk
-@@ -195,7 +195,7 @@ CONFIG_MAC80211_HWSIM=m
+@@ -212,7 +212,7 @@ CONFIG_ATH9K_COMMON=m
+ # PCI Drivers
  ifdef CONFIG_PCI
  
- CONFIG_ATH5K=m
 -CONFIG_ATH5K_PCI=y
 +# CONFIG_ATH5K_PCI=y
- # CONFIG_ATH5K_DEBUG=y
- # CONFIG_ATH5K_AHB=y
- CONFIG_ATH9K_HW=m
+ CONFIG_ATH9K=m
+ CONFIG_IWLAGN=m
index 178f38b3e592c343c25c8b5d94257e7564e1c727..0415e5f1fcdc7837ea93ef6214777e096aab1443 100644 (file)
@@ -1,11 +1,11 @@
 --- a/include/linux/compat-2.6.36.h
 +++ b/include/linux/compat-2.6.36.h
-@@ -101,6 +101,8 @@ int no_printk(const char *s, ...) { retu
+@@ -102,6 +102,8 @@ int no_printk(const char *s, ...) { retu
  #define alloc_workqueue(name, flags, max_active) __create_workqueue(name, flags, max_active, 0)
  #endif
  
 +#define PCI_EEPROM_WIDTH_93C86   8
 +
- #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36)) */
+ #define EXTPROC       0200000
+ #define TIOCPKT_IOCTL         64
  
- #endif /* LINUX_26_36_COMPAT_H */
diff --git a/package/mac80211/patches/050-fix_missing_include.patch b/package/mac80211/patches/050-fix_missing_include.patch
new file mode 100644 (file)
index 0000000..458ff4d
--- /dev/null
@@ -0,0 +1,10 @@
+--- a/compat/compat-2.6.39.c
++++ b/compat/compat-2.6.39.c
+@@ -10,6 +10,7 @@
+ #include <linux/compat.h>
+ #include <linux/tty.h>
++#include <linux/sched.h>
+ /*
+  *            Termios Helper Methods
diff --git a/package/mac80211/patches/060-fix_zd1211_defines.patch b/package/mac80211/patches/060-fix_zd1211_defines.patch
new file mode 100644 (file)
index 0000000..3b3e2d8
--- /dev/null
@@ -0,0 +1,14 @@
+--- a/drivers/net/wireless/zd1211rw/zd_chip.h
++++ b/drivers/net/wireless/zd1211rw/zd_chip.h
+@@ -60,6 +60,11 @@ enum {
+ #define E2P_DATA(offset) ((zd_addr_t)(E2P_START + E2P_DATA_OFFSET + (offset)))
+ #define FWRAW_DATA(offset) ((zd_addr_t)(FW_START + (offset)))
++#undef CR0
++#undef CR1
++#undef CR2
++#undef CR3
++
+ /* 8-bit hardware registers */
+ #define CR0   CTL_REG(0x0000)
+ #define CR1   CTL_REG(0x0004)
index cbfa42cba32b0da1da7564dc562e0a76f4ab162e..44ff8ac106b126cc8cc4dcefaf3b2c7740ec6293 100644 (file)
@@ -33,7 +33,7 @@
  #endif
 --- a/config.mk
 +++ b/config.mk
-@@ -424,7 +424,7 @@ endif #CONFIG_COMPAT_KERNEL_29
+@@ -431,7 +431,7 @@ endif #CONFIG_COMPAT_KERNEL_29
  # This activates a threading fix for usb urb.
  # this is mainline commit: b3e670443b7fb8a2d29831b62b44a039c283e351
  # This fix will be included in some stable releases.
index e080af7099a698edec63a604000a11db98971e31..595c6b7de1d85aa44970137e5f24965fba549271 100644 (file)
@@ -8,8 +8,8 @@
  #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
  
  #include <linux/kernel.h>
---- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
-+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
+--- a/drivers/net/wireless/iwlegacy/iwl3945-base.c
++++ b/drivers/net/wireless/iwlegacy/iwl3945-base.c
 @@ -27,6 +27,7 @@
   *
   *****************************************************************************/
  #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
  
  #include <linux/kernel.h>
+--- a/drivers/net/wireless/iwlegacy/iwl4965-base.c
++++ b/drivers/net/wireless/iwlegacy/iwl4965-base.c
+@@ -27,6 +27,7 @@
+  *
+  *****************************************************************************/
++#undef pr_fmt
+ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+ #include <linux/kernel.h>
index 7235ddeb57349f9600a7eaa0748438090dc5e732..e38b572e5a6861fc82107c7b821e481919f2526c 100644 (file)
@@ -26,7 +26,7 @@
        struct ar5416IniArray iniCommon;
 --- a/drivers/net/wireless/ath/ath9k/hw.c
 +++ b/drivers/net/wireless/ath/ath9k/hw.c
-@@ -1213,6 +1213,20 @@ static bool ath9k_hw_channel_change(stru
+@@ -1212,6 +1212,20 @@ static bool ath9k_hw_channel_change(stru
        return true;
  }
  
@@ -47,7 +47,7 @@
  bool ath9k_hw_check_alive(struct ath_hw *ah)
  {
        int count = 50;
-@@ -1501,6 +1515,8 @@ int ath9k_hw_reset(struct ath_hw *ah, st
+@@ -1500,6 +1514,8 @@ int ath9k_hw_reset(struct ath_hw *ah, st
        if (AR_SREV_9300_20_OR_LATER(ah))
                ar9003_hw_bb_watchdog_config(ah);
  
index 44b457707a0534c1366fe0647bb6d48e8fc32cb2..c92245641fbc35e1ebaf151e2ad0647345592cdf 100644 (file)
@@ -18,7 +18,7 @@
  
  #include "ath9k.h"
  
-@@ -526,6 +527,7 @@ static void ath9k_init_misc(struct ath_s
+@@ -522,6 +523,7 @@ static void ath9k_init_misc(struct ath_s
  static int ath9k_init_softc(u16 devid, struct ath_softc *sc, u16 subsysid,
                            const struct ath_bus_ops *bus_ops)
  {
@@ -26,7 +26,7 @@
        struct ath_hw *ah = NULL;
        struct ath_common *common;
        int ret = 0, i;
-@@ -540,7 +542,7 @@ static int ath9k_init_softc(u16 devid, s
+@@ -536,7 +538,7 @@ static int ath9k_init_softc(u16 devid, s
        ah->hw_version.subsysid = subsysid;
        sc->sc_ah = ah;
  
@@ -35,7 +35,7 @@
                ah->ah_flags |= AH_USE_EEPROM;
  
        common = ath9k_hw_common(ah);
-@@ -576,6 +578,9 @@ static int ath9k_init_softc(u16 devid, s
+@@ -572,6 +574,9 @@ static int ath9k_init_softc(u16 devid, s
        if (ret)
                goto err_hw;
  
index 38a1b3fe9507295f28b9f2acccedc246e134ddec..23a5887a1d99b2a6f437e3f5950985d3ea57c69f 100644 (file)
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/ath/ath9k/init.c
 +++ b/drivers/net/wireless/ath/ath9k/init.c
-@@ -542,8 +542,14 @@ static int ath9k_init_softc(u16 devid, s
+@@ -538,8 +538,14 @@ static int ath9k_init_softc(u16 devid, s
        ah->hw_version.subsysid = subsysid;
        sc->sc_ah = ah;
  
index ded236cd9f29f4e31d0b2af5d3560b19346d5ae7..352bee15fd48853e495ecb0d8fda43b08f6b807c 100644 (file)
  /*    Rfkill     */
 --- a/drivers/net/wireless/ath/ath9k/main.c
 +++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -1204,9 +1204,6 @@ static void ath9k_stop(struct ieee80211_
+@@ -1216,9 +1216,6 @@ static void ath9k_stop(struct ieee80211_
  
        mutex_lock(&sc->mutex);
  
        cancel_work_sync(&sc->paprd_work);
 --- a/drivers/net/wireless/ath/ath9k/init.c
 +++ b/drivers/net/wireless/ath/ath9k/init.c
-@@ -145,6 +145,21 @@ static struct ieee80211_rate ath9k_legac
+@@ -141,6 +141,21 @@ static struct ieee80211_rate ath9k_legac
        RATE(540, 0x0c, 0),
  };
  
  static void ath9k_deinit_softc(struct ath_softc *sc);
  
  /*
-@@ -746,6 +761,13 @@ int ath9k_init_device(u16 devid, struct 
+@@ -742,6 +757,13 @@ int ath9k_init_device(u16 devid, struct 
  
        ath9k_init_txpower_limits(sc);
  
index 285aa2aab8464bf9becfb71959762ca667adf919..301af3c22b889c97428f83d72e3675ffe0b0a1bf 100644 (file)
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/ath/ath9k/hw.c
 +++ b/drivers/net/wireless/ath/ath9k/hw.c
-@@ -1467,8 +1467,8 @@ int ath9k_hw_reset(struct ath_hw *ah, st
+@@ -1466,8 +1466,8 @@ int ath9k_hw_reset(struct ath_hw *ah, st
        REG_WRITE(ah, AR_OBS, 8);
  
        if (ah->config.rx_intr_mitigation) {
index e64d3aa8304ea6dc76d6456a2b0806b9d21bb8da..198f658a618f8fc96d929f689fe771cfcfb94330 100644 (file)
@@ -1,6 +1,6 @@
 --- a/include/net/mac80211.h
 +++ b/include/net/mac80211.h
-@@ -2198,6 +2198,20 @@ static inline int ieee80211_sta_ps_trans
+@@ -2209,6 +2209,18 @@ static inline int ieee80211_sta_ps_trans
  #define IEEE80211_TX_STATUS_HEADROOM  13
  
  /**
 + * them back to mac80211 for retransmission, the station needs to be told
 + * to wake up using the TIM bitmap in the beacon.
 + *
-+ * This function sets the station's TIM bit - it will be cleared automatically
-+ * either when the station wakes up (and mac80211 has flushed out its
-+ * buffered frames), or if all remaining buffered frames in mac80211 have
-+ * timed out.
++ * This function sets the station's TIM bit - it will be cleared when the
++ * station wakes up.
 + */
 +void ieee80211_sta_set_tim(struct ieee80211_sta *sta);
 +
   * Call this function for all transmitted frames after they have been
 --- a/net/mac80211/sta_info.c
 +++ b/net/mac80211/sta_info.c
-@@ -991,3 +991,11 @@ void ieee80211_sta_block_awake(struct ie
+@@ -608,7 +608,8 @@ static bool sta_info_cleanup_expire_buff
+ #endif
+               dev_kfree_skb(skb);
+-              if (skb_queue_empty(&sta->ps_tx_buf))
++              if (skb_queue_empty(&sta->ps_tx_buf) &&
++                  !test_sta_flags(sta, WLAN_STA_PS_DRIVER_BUF))
+                       sta_info_clear_tim_bit(sta);
+       }
+@@ -899,6 +900,7 @@ void ieee80211_sta_ps_deliver_wakeup(str
+       struct ieee80211_local *local = sdata->local;
+       int sent, buffered;
++      clear_sta_flags(sta, WLAN_STA_PS_DRIVER_BUF);
+       if (!(local->hw.flags & IEEE80211_HW_AP_LINK_PS))
+               drv_sta_notify(local, sdata, STA_NOTIFY_AWAKE, &sta->sta);
+@@ -991,3 +993,12 @@ void ieee80211_sta_block_awake(struct ie
                ieee80211_queue_work(hw, &sta->drv_unblock_wk);
  }
  EXPORT_SYMBOL(ieee80211_sta_block_awake);
 +{
 +      struct sta_info *sta = container_of(pubsta, struct sta_info, sta);
 +
++      set_sta_flags(sta, WLAN_STA_PS_DRIVER_BUF);
 +      sta_info_set_tim_bit(sta);
 +}
 +EXPORT_SYMBOL(ieee80211_sta_set_tim);
+--- a/net/mac80211/sta_info.h
++++ b/net/mac80211/sta_info.h
+@@ -43,6 +43,8 @@
+  *    be in the queues
+  * @WLAN_STA_PSPOLL: Station sent PS-poll while driver was keeping
+  *    station in power-save mode, reply when the driver unblocks.
++ * @WLAN_STA_PS_DRIVER_BUF: Station has frames pending in driver internal
++ *    buffers. Automatically cleared on station wake-up.
+  */
+ enum ieee80211_sta_info_flags {
+       WLAN_STA_AUTH           = 1<<0,
+@@ -58,6 +60,7 @@ enum ieee80211_sta_info_flags {
+       WLAN_STA_BLOCK_BA       = 1<<11,
+       WLAN_STA_PS_DRIVER      = 1<<12,
+       WLAN_STA_PSPOLL         = 1<<13,
++      WLAN_STA_PS_DRIVER_BUF  = 1<<14,
+ };
+ #define STA_TID_NUM 16
index b22bc868ddd0088e50c0b0b4d632fed369c2c932..ff58c26d7ad58a8aaf91c465075cb1432d8bfd43 100644 (file)
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/ath/ath9k/ath9k.h
 +++ b/drivers/net/wireless/ath/ath9k/ath9k.h
-@@ -205,6 +205,7 @@ struct ath_atx_ac {
+@@ -203,6 +203,7 @@ struct ath_atx_ac {
        int sched;
        struct list_head list;
        struct list_head tid_q;
@@ -8,7 +8,7 @@
  };
  
  struct ath_frame_info {
-@@ -262,6 +263,8 @@ struct ath_node {
+@@ -260,6 +261,8 @@ struct ath_node {
        struct ath_atx_ac ac[WME_NUM_AC];
        u16 maxampdu;
        u8 mpdudensity;
@@ -17,7 +17,7 @@
  };
  
  #define AGGR_CLEANUP         BIT(1)
-@@ -343,6 +346,9 @@ int ath_tx_aggr_start(struct ath_softc *
+@@ -341,6 +344,9 @@ int ath_tx_aggr_start(struct ath_softc *
  void ath_tx_aggr_stop(struct ath_softc *sc, struct ieee80211_sta *sta, u16 tid);
  void ath_tx_aggr_resume(struct ath_softc *sc, struct ieee80211_sta *sta, u16 tid);
  
@@ -57,7 +57,7 @@
  static int ath9k_conf_tx(struct ieee80211_hw *hw, u16 queue,
                         const struct ieee80211_tx_queue_params *params)
  {
-@@ -2130,6 +2151,7 @@ struct ieee80211_ops ath9k_ops = {
+@@ -2191,6 +2212,7 @@ struct ieee80211_ops ath9k_ops = {
        .configure_filter   = ath9k_configure_filter,
        .sta_add            = ath9k_sta_add,
        .sta_remove         = ath9k_sta_remove,
  void ath_tx_aggr_resume(struct ath_softc *sc, struct ieee80211_sta *sta, u16 tid)
  {
        struct ath_atx_tid *txtid;
-@@ -1492,7 +1569,6 @@ static int setup_tx_flags(struct sk_buff
+@@ -1493,7 +1570,6 @@ static int setup_tx_flags(struct sk_buff
        struct ieee80211_tx_info *tx_info = IEEE80211_SKB_CB(skb);
        int flags = 0;
  
        flags |= ATH9K_TXDESC_INTREQ;
  
        if (tx_info->flags & IEEE80211_TX_CTL_NO_ACK)
-@@ -1755,6 +1831,9 @@ static void ath_tx_start_dma(struct ath_
+@@ -1756,6 +1832,9 @@ static void ath_tx_start_dma(struct ath_
                if (txctl->paprd)
                        bf->bf_state.bfs_paprd_timestamp = jiffies;
  
index e368bce64ba2f26558f2884de62975236244cea0..f7341e2a1092ee4aa66ce47cd55836d886b6594d 100644 (file)
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/ath/ath9k/xmit.c
 +++ b/drivers/net/wireless/ath/ath9k/xmit.c
-@@ -2223,33 +2223,6 @@ static void ath_tx_complete_poll_work(st
+@@ -2226,33 +2226,6 @@ static void ath_tx_complete_poll_work(st
                                } else {
                                        txq->axq_tx_inprogress = true;
                                }
index b15bd95769fc80ee907d1921649e68ab68e32253..d365f352451f50f3ebd095d1083f076e05aa9c30 100644 (file)
                NLA_PUT_U32(msg, NL80211_STA_INFO_RX_PACKETS,
 --- a/net/mac80211/sta_info.h
 +++ b/net/mac80211/sta_info.h
-@@ -209,6 +209,8 @@ enum plink_state {
+@@ -212,6 +212,8 @@ enum plink_state {
   * @rate_ctrl_priv: rate control private per-STA pointer
   * @last_tx_rate: rate used for last transmit, to report to userspace as
   *    "the" transmit rate
   * @lock: used for locking all fields that require locking, see comments
   *    in the header file.
   * @flaglock: spinlock for flags accesses
-@@ -311,6 +313,8 @@ struct sta_info {
+@@ -314,6 +316,8 @@ struct sta_info {
        unsigned long tx_bytes;
        unsigned long tx_fragments;
        struct ieee80211_tx_rate last_tx_rate;
        /*
 --- a/net/mac80211/rx.c
 +++ b/net/mac80211/rx.c
-@@ -1166,14 +1166,23 @@ ieee80211_rx_h_sta_process(struct ieee80
+@@ -1156,14 +1156,23 @@ ieee80211_rx_h_sta_process(struct ieee80
        if (rx->sdata->vif.type == NL80211_IFTYPE_ADHOC) {
                u8 *bssid = ieee80211_get_bssid(hdr, rx->skb->len,
                                                NL80211_IFTYPE_ADHOC);
diff --git a/package/mac80211/patches/550-ath9k_fix_interrupts.patch b/package/mac80211/patches/550-ath9k_fix_interrupts.patch
deleted file mode 100644 (file)
index 52e28c8..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
---- a/drivers/net/wireless/ath/ath9k/mac.c
-+++ b/drivers/net/wireless/ath/ath9k/mac.c
-@@ -891,7 +891,7 @@ void ath9k_hw_set_interrupts(struct ath_
-       struct ath_common *common = ath9k_hw_common(ah);
-       if (!(ints & ATH9K_INT_GLOBAL))
--              ath9k_hw_enable_interrupts(ah);
-+              ath9k_hw_disable_interrupts(ah);
-       ath_dbg(common, ATH_DBG_INTERRUPT, "0x%x => 0x%x\n", omask, ints);
-@@ -969,7 +969,8 @@ void ath9k_hw_set_interrupts(struct ath_
-                       REG_CLR_BIT(ah, AR_IMR_S5, AR_IMR_S5_TIM_TIMER);
-       }
--      ath9k_hw_enable_interrupts(ah);
-+      if (ints & ATH9K_INT_GLOBAL)
-+              ath9k_hw_enable_interrupts(ah);
-       return;
- }
diff --git a/package/mac80211/patches/550-ath9k_no_vif_promisc_handling.patch b/package/mac80211/patches/550-ath9k_no_vif_promisc_handling.patch
new file mode 100644 (file)
index 0000000..c3a9663
--- /dev/null
@@ -0,0 +1,13 @@
+--- a/drivers/net/wireless/ath/ath9k/recv.c
++++ b/drivers/net/wireless/ath/ath9k/recv.c
+@@ -413,9 +413,7 @@ u32 ath_calcrxfilter(struct ath_softc *s
+        * mode interface or when in monitor mode. AP mode does not need this
+        * since it receives all in-BSS frames anyway.
+        */
+-      if (((sc->sc_ah->opmode != NL80211_IFTYPE_AP) &&
+-           (sc->rx.rxfilter & FIF_PROMISC_IN_BSS)) ||
+-          (sc->sc_ah->is_monitoring))
++      if (sc->sc_ah->is_monitoring)
+               rfilt |= ATH9K_RX_FILTER_PROM;
+       if (sc->rx.rxfilter & FIF_CONTROL)
diff --git a/package/mac80211/patches/560-mac80211_minstrel_ht_sampling_fix.patch b/package/mac80211/patches/560-mac80211_minstrel_ht_sampling_fix.patch
new file mode 100644 (file)
index 0000000..011f87a
--- /dev/null
@@ -0,0 +1,50 @@
+--- a/net/mac80211/rc80211_minstrel_ht.c
++++ b/net/mac80211/rc80211_minstrel_ht.c
+@@ -415,10 +415,8 @@ minstrel_ht_tx_status(void *priv, struct
+               mi->sample_count--;
+       }
+-      if (info->flags & IEEE80211_TX_CTL_RATE_CTRL_PROBE) {
++      if (info->flags & IEEE80211_TX_CTL_RATE_CTRL_PROBE)
+               mi->sample_packets += info->status.ampdu_len;
+-              minstrel_next_sample_idx(mi);
+-      }
+       for (i = 0; !last; i++) {
+               last = (i == IEEE80211_TX_MAX_RATES - 1) ||
+@@ -553,13 +551,14 @@ minstrel_get_sample_rate(struct minstrel
+       sample_idx = sample_table[mg->column][mg->index];
+       mr = &mg->rates[sample_idx];
+       sample_idx += mi->sample_group * MCS_GROUP_RATES;
++      minstrel_next_sample_idx(mi);
+       /*
+        * When not using MRR, do not sample if the probability is already
+        * higher than 95% to avoid wasting airtime
+        */
+       if (!mp->has_mrr && (mr->probability > MINSTREL_FRAC(95, 100)))
+-              goto next;
++              return -1;
+       /*
+        * Make sure that lower rates get sampled only occasionally,
+@@ -568,17 +567,13 @@ minstrel_get_sample_rate(struct minstrel
+       if (minstrel_get_duration(sample_idx) >
+           minstrel_get_duration(mi->max_tp_rate)) {
+               if (mr->sample_skipped < 20)
+-                      goto next;
++                      return -1;
+               if (mi->sample_slow++ > 2)
+-                      goto next;
++                      return -1;
+       }
+       return sample_idx;
+-
+-next:
+-      minstrel_next_sample_idx(mi);
+-      return -1;
+ }
+ static void
index 7d620e41a23a15282b852a755beaad1eba38d11f..c60d51a21f90aef01d6b553004e73908cb7a9f23 100644 (file)
@@ -1,6 +1,6 @@
 --- a/drivers/net/wireless/mwl8k.c
 +++ b/drivers/net/wireless/mwl8k.c
-@@ -4484,6 +4484,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw")
+@@ -4502,6 +4502,7 @@ MODULE_FIRMWARE("mwl8k/fmimage_8366.fw")
  MODULE_FIRMWARE(MWL8K_8366_AP_FW(MWL8K_8366_AP_FW_API));
  
  static DEFINE_PCI_DEVICE_TABLE(mwl8k_pci_id_table) = {
diff --git a/package/mac80211/patches/710-p54_rssi_crash_fix.patch b/package/mac80211/patches/710-p54_rssi_crash_fix.patch
new file mode 100644 (file)
index 0000000..73089cd
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/drivers/net/wireless/p54/eeprom.c
++++ b/drivers/net/wireless/p54/eeprom.c
+@@ -524,10 +524,13 @@ err_data:
+ struct p54_rssi_db_entry *p54_rssi_find(struct p54_common *priv, const u16 freq)
+ {
+-      struct p54_rssi_db_entry *entry = (void *)(priv->rssi_db->data +
+-                                                 priv->rssi_db->offset);
++      struct p54_rssi_db_entry *entry;
+       int i, found = -1;
++      if (!priv->rssi_db)
++              return &p54_rssi_default;
++
++      entry = (void *)(priv->rssi_db->data + priv->rssi_db->offset);
+       for (i = 0; i < priv->rssi_db->entries; i++) {
+               if (!same_band(freq, entry[i].freq))
+                       continue;
diff --git a/package/mac80211/patches/720-mac80211-print-restart-warning.patch b/package/mac80211/patches/720-mac80211-print-restart-warning.patch
new file mode 100644 (file)
index 0000000..7a28598
--- /dev/null
@@ -0,0 +1,14 @@
+Index: compat-wireless-2011-02-25/net/mac80211/main.c
+===================================================================
+--- compat-wireless-2011-02-25.orig/net/mac80211/main.c        2011-03-07 12:58:14.996968980 +0100
++++ compat-wireless-2011-02-25/net/mac80211/main.c     2011-03-07 13:03:26.732273903 +0100
+@@ -384,6 +384,9 @@ void ieee80211_restart_hw(struct ieee802
+       trace_api_restart_hw(local);
++      wiphy_info(hw->wiphy,
++                 "Hardware restart was requested\n");
++
+       /* use this reason, ieee80211_reconfig will unblock it */
+       ieee80211_stop_queues_by_reason(hw,
+               IEEE80211_QUEUE_STOP_REASON_SUSPEND);
diff --git a/package/mac80211/patches/721-mac80211-fix-scan-race.patch b/package/mac80211/patches/721-mac80211-fix-scan-race.patch
new file mode 100644 (file)
index 0000000..efc01b1
--- /dev/null
@@ -0,0 +1,141 @@
+Index: compat-wireless-2011-02-25/net/mac80211/scan.c
+===================================================================
+--- compat-wireless-2011-02-25.orig/net/mac80211/scan.c        2011-03-07 14:43:55.695666042 +0100
++++ compat-wireless-2011-02-25/net/mac80211/scan.c     2011-03-07 14:43:57.594439631 +0100
+@@ -258,10 +258,12 @@ static bool ieee80211_prep_hw_scan(struc
+       return true;
+ }
+-static bool __ieee80211_scan_completed(struct ieee80211_hw *hw, bool aborted,
++static void __ieee80211_scan_completed(struct ieee80211_hw *hw, bool aborted,
+                                      bool was_hw_scan)
+ {
+       struct ieee80211_local *local = hw_to_local(hw);
++      bool on_oper_chan;
++      bool enable_beacons = false;
+       lockdep_assert_held(&local->mtx);
+@@ -275,12 +277,12 @@ static bool __ieee80211_scan_completed(s
+               aborted = true;
+       if (WARN_ON(!local->scan_req))
+-              return false;
++              return;
+       if (was_hw_scan && !aborted && ieee80211_prep_hw_scan(local)) {
+               int rc = drv_hw_scan(local, local->scan_sdata, local->hw_scan_req);
+               if (rc == 0)
+-                      return false;
++                      return;
+       }
+       kfree(local->hw_scan_req);
+@@ -294,26 +296,13 @@ static bool __ieee80211_scan_completed(s
+       local->scanning = 0;
+       local->scan_channel = NULL;
+-      return true;
+-}
+-
+-static void __ieee80211_scan_completed_finish(struct ieee80211_hw *hw,
+-                                            bool was_hw_scan)
+-{
+-      struct ieee80211_local *local = hw_to_local(hw);
+-      bool on_oper_chan;
+-      bool enable_beacons = false;
+-
+-      mutex_lock(&local->mtx);
+       on_oper_chan = ieee80211_cfg_on_oper_channel(local);
+       WARN_ON(local->scanning & (SCAN_SW_SCANNING | SCAN_HW_SCANNING));
+-      if (was_hw_scan || !on_oper_chan) {
+-              if (WARN_ON(local->scan_channel))
+-                      local->scan_channel = NULL;
++      if (was_hw_scan || !on_oper_chan)
+               ieee80211_hw_config(local, IEEE80211_CONF_CHANGE_CHANNEL);
+-      } else
++      else
+               /* Set power back to normal operating levels. */
+               ieee80211_hw_config(local, 0);
+@@ -331,7 +320,6 @@ static void __ieee80211_scan_completed_f
+       }
+       ieee80211_recalc_idle(local);
+-      mutex_unlock(&local->mtx);
+       ieee80211_mlme_notify_scan_completed(local);
+       ieee80211_ibss_notify_scan_completed(local);
+@@ -686,12 +674,14 @@ void ieee80211_scan_work(struct work_str
+ {
+       struct ieee80211_local *local =
+               container_of(work, struct ieee80211_local, scan_work.work);
+-      struct ieee80211_sub_if_data *sdata = local->scan_sdata;
++      struct ieee80211_sub_if_data *sdata;
+       unsigned long next_delay = 0;
+-      bool aborted, hw_scan, finish;
++      bool aborted, hw_scan;
+       mutex_lock(&local->mtx);
++      sdata = local->scan_sdata;
++
+       if (test_and_clear_bit(SCAN_COMPLETED, &local->scanning)) {
+               aborted = test_and_clear_bit(SCAN_ABORTED, &local->scanning);
+               goto out_complete;
+@@ -755,17 +745,11 @@ void ieee80211_scan_work(struct work_str
+       } while (next_delay == 0);
+       ieee80211_queue_delayed_work(&local->hw, &local->scan_work, next_delay);
+-      mutex_unlock(&local->mtx);
+-      return;
++      goto out;
+ out_complete:
+       hw_scan = test_bit(SCAN_HW_SCANNING, &local->scanning);
+-      finish = __ieee80211_scan_completed(&local->hw, aborted, hw_scan);
+-      mutex_unlock(&local->mtx);
+-      if (finish)
+-              __ieee80211_scan_completed_finish(&local->hw, hw_scan);
+-      return;
+-
++      __ieee80211_scan_completed(&local->hw, aborted, hw_scan);
+ out:
+       mutex_unlock(&local->mtx);
+ }
+@@ -835,7 +819,6 @@ int ieee80211_request_internal_scan(stru
+ void ieee80211_scan_cancel(struct ieee80211_local *local)
+ {
+       bool abortscan;
+-      bool finish = false;
+       /*
+        * We are only canceling software scan, or deferred scan that was not
+@@ -855,14 +838,17 @@ void ieee80211_scan_cancel(struct ieee80
+       mutex_lock(&local->mtx);
+       abortscan = local->scan_req && !test_bit(SCAN_HW_SCANNING, &local->scanning);
+-      if (abortscan)
+-              finish = __ieee80211_scan_completed(&local->hw, true, false);
+-      mutex_unlock(&local->mtx);
+-
+       if (abortscan) {
+-              /* The scan is canceled, but stop work from being pending */
+-              cancel_delayed_work_sync(&local->scan_work);
++              /*
++               * The scan is canceled, but stop work from being pending.
++               *
++               * If the work is currently running, it must be blocked on
++               * the mutex, but we'll set scan_sdata = NULL and it'll
++               * simply exit once it acquires the mutex.
++               */
++              cancel_delayed_work(&local->scan_work);
++              /* and clean up */
++              __ieee80211_scan_completed(&local->hw, true, false);
+       }
+-      if (finish)
+-              __ieee80211_scan_completed_finish(&local->hw, false);
++      mutex_unlock(&local->mtx);
+ }
index eebda2ad6c6213ac01462cb156aaab0b5e9e6a6f..b88678bc0e88af61d3b481550c18a08a578229f3 100644 (file)
@@ -35,7 +35,7 @@
        if (dev->dev->bus->chip_id == 0x4301) {
                mask |= 0x0060;
                set |= 0x0060;
-@@ -5102,10 +5107,10 @@ static void b43_print_driverinfo(void)
+@@ -5100,10 +5105,10 @@ static void b43_print_driverinfo(void)
        feat_sdio = "S";
  #endif
        printk(KERN_INFO "Broadcom 43xx driver loaded "