ath9k pending patches
cover ath9k pending patches
Pending patches for ath9k, rebased over master. The MAINTAINERS file has also been updated with patch 13.
Sujith
Sujith Manoharan (13):
ath9k: Add WB335 PCI IDs
ath9k: Identify Killer Wireless cards
ath9k: Fix TX99 config option usage
ath9k: Fix wow.c compilation
ath9k: Add a config option for WoW
ath9k: Use CONFIG_ATH9K_WOW
ath9k: Add an initialization routine for WoW
ath9k: Add SERDES initvals for AR9462 2.1
ath9k: Remove unused AR9462 2.0 initvals
ath9k: Remove pcieSerDesWrite
ath9k: Use correct PCIE initvals for AR9485
ath9k: Apply CUS227 specific TX gain values
ath9k: Update MAINTAINERS
MAINTAINERS | 19 +- drivers/net/wireless/ath/ath9k/Kconfig | 10 +- drivers/net/wireless/ath/ath9k/Makefile | 8 +- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 43 +- drivers/net/wireless/ath/ath9k/ar9003_wow.c | 422 +++++++++++++++ drivers/net/wireless/ath/ath9k/ar9340_initvals.h | 102 ++++ .../net/wireless/ath/ath9k/ar9462_2p0_initvals.h | 14 - .../net/wireless/ath/ath9k/ar9462_2p1_initvals.h | 7 + drivers/net/wireless/ath/ath9k/ar9485_initvals.h | 35 +- drivers/net/wireless/ath/ath9k/ath9k.h | 53 +- drivers/net/wireless/ath/ath9k/debug.c | 115 +--- drivers/net/wireless/ath/ath9k/hw.c | 1 - drivers/net/wireless/ath/ath9k/hw.h | 5 +- drivers/net/wireless/ath/ath9k/init.c | 23 +- drivers/net/wireless/ath/ath9k/main.c | 468 +--------------- drivers/net/wireless/ath/ath9k/pci.c | 45 ++ drivers/net/wireless/ath/ath9k/tx99.c | 263 +++++++++ drivers/net/wireless/ath/ath9k/wow.c | 589 +++++++++------------ drivers/net/wireless/ath/ath9k/xmit.c | 4 + 19 files changed, 1224 insertions(+), 1002 deletions(-) create mode 100644 drivers/net/wireless/ath/ath9k/ar9003_wow.c create mode 100644 drivers/net/wireless/ath/ath9k/tx99.c
Signature · 1 line
1.8.4.2
PATCH 1/13 ath9k: Add WB335 PCI IDs
From: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/pci.c | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+)
drivers/net/wireless/ath/ath9k/pci.c +25 -0
@@ -361,6 +361,11 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, {PCI_DEVICE_SUB (PCI_VENDOR_ID_ATHEROS ,0x0036 , +0x11AD ,/* LITEON */ + 0x0682), + .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, + 0x0036, PCI_VENDOR_ID_AZWAVE, 0x213A), .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV },
@@ -371,6 +376,11 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, {PCI_DEVICE_SUB (PCI_VENDOR_ID_ATHEROS ,0x0036 , +PCI_VENDOR_ID_LENOVO , + 0x4026), + .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, + 0x0036, PCI_VENDOR_ID_HP, 0x18E3), .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV },
@@ -381,6 +391,11 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, {PCI_DEVICE_SUB (PCI_VENDOR_ID_ATHEROS ,0x0036 , +PCI_VENDOR_ID_HP , + 0x2005), + .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV }, + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, + 0x0036, PCI_VENDOR_ID_DELL, 0x020E), .driver_data = ATH9K_PCI_AR9565_1ANT | ATH9K_PCI_BT_ANT_DIV },
@@ -458,6 +473,16 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { 0x185F, /* WNC */ 0x3027), .driver_data = ATH9K_PCI_AR9565_2ANT | ATH9K_PCI_BT_ANT_DIV }, + {PCI_DEVICE_SUB (PCI_VENDOR_ID_ATHEROS , +0x0036 , +0x185F ,/* WNC */ + 0xA120), + .driver_data = ATH9K_PCI_AR9565_2ANT | ATH9K_PCI_BT_ANT_DIV }, + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, + 0x0036, + PCI_VENDOR_ID_FOXCONN, + 0xE07F), + .driver_data = ATH9K_PCI_AR9565_2ANT | ATH9K_PCI_BT_ANT_DIV },/* PCI-E AR9565 (WB335) */ { PCI_VDEVICE(ATHEROS, 0x0036),
Signature · 1 line
1.8.4.2
PATCH 2/13 ath9k: Identify Killer Wireless cards
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/ath9k.h | 1 + drivers/net/wireless/ath/ath9k/init.c | 3 +++ drivers/net/wireless/ath/ath9k/pci.c | 20 ++++++++++++++++++++ 3 files changed, 24 insertions(+)
drivers/net/wireless/ath/ath9k/ath9k.h +1 -0
@@ -641,6 +641,7 @@ void ath_ant_comb_scan(struct ath_softc *sc, struct ath_rx_status *rs);#define ATH9K_PCI_D3_L1_WAR 0x0040#define ATH9K_PCI_AR9565_1ANT 0x0080#define ATH9K_PCI_AR9565_2ANT 0x0100 +#define ATH9K_PCI_KILLER 0x0200/* * Default cache line size, in bytes.
drivers/net/wireless/ath/ath9k/init.c +3 -0
@@ -589,6 +589,9 @@ static void ath9k_init_platform(struct ath_softc *sc)if (sc->driver_data &ATH9K_PCI_AR9565_2ANT )ath_info (common,"WB335 2-ANT card detected\n" ); +if (sc->driver_data &ATH9K_PCI_KILLER ) +ath_info (common,"Killer Wireless card detected\n" ); +/* * Some WB335 cards do not support antenna diversity. Since * we use a hardcoded value for AR9565 instead of using the
drivers/net/wireless/ath/ath9k/pci.c +20 -0
@@ -87,6 +87,19 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { { PCI_VDEVICE(ATHEROS, 0x002C) }, /* PCI-E 802.11n bonded out */ { PCI_VDEVICE(ATHEROS, 0x002D) }, /* PCI */ { PCI_VDEVICE(ATHEROS, 0x002E) }, /* PCI-E */ + +/* Killer Wireless (3x3) */ + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, +0x0030 , +0x1A56 , +0x2000 ), + .driver_data = ATH9K_PCI_KILLER }, + { PCI_DEVICE_SUB(PCI_VENDOR_ID_ATHEROS, +0x0030 , +0x1A56 , +0x2001 ), + .driver_data = ATH9K_PCI_KILLER }, + { PCI_VDEVICE(ATHEROS, 0x0030) }, /* PCI-E AR9300 */ /* PCI-E CUS198 */
@@ -267,6 +280,13 @@ static DEFINE_PCI_DEVICE_TABLE(ath_pci_id_table) = { 0x1783), .driver_data = ATH9K_PCI_WOW }, +/* Killer Wireless (2x2) */ + {PCI_DEVICE_SUB (PCI_VENDOR_ID_ATHEROS , +0x0030 , +0x1A56 , + 0x2003), + .driver_data = ATH9K_PCI_KILLER }, + { PCI_VDEVICE(ATHEROS, 0x0034) }, /* PCI-E AR9462 */ { PCI_VDEVICE(ATHEROS, 0x0037) }, /* PCI-E AR1111/AR9485 */
Signature · 1 line
1.8.4.2
PATCH 3/13 ath9k: Fix TX99 config option usage
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
Use CONFIG_ATH9K_TX99 to properly enclose the tx99 code and make sure that it is not compiled as part of the driver when it is not selected. Move the tx99 code to a new file tx99.c and also add ATH9K_DEBUGFS as a dependency in Kconfig.
This reduces the module size on platforms like OpenWrt where ATH9K_DEBUGFS is selected, but TX99 might be disabled.
--- drivers/net/wireless/ath/ath9k/Kconfig | 2 +- drivers/net/wireless/ath/ath9k/Makefile | 4 +- drivers/net/wireless/ath/ath9k/ath9k.h | 20 ++- drivers/net/wireless/ath/ath9k/debug.c | 115 +------------- drivers/net/wireless/ath/ath9k/main.c | 130 +--------------- drivers/net/wireless/ath/ath9k/tx99.c | 263 ++++++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath9k/xmit.c | 4 + 7 files changed, 290 insertions(+), 248 deletions(-) create mode 100644 drivers/net/wireless/ath/ath9k/tx99.c
drivers/net/wireless/ath/ath9k/Kconfig +1 -1
@@ -86,7 +86,7 @@ config ATH9K_DFS_CERTIFIED config ATH9K_TX99 bool "Atheros ath9k TX99 testing support" - depends on CFG80211_CERTIFICATION_ONUS + depends on ATH9K_DEBUGFS && CFG80211_CERTIFICATION_ONUS default n ---help--- Say N. This should only be enabled on systems undergoing
drivers/net/wireless/ath/ath9k/Makefile +2 -2
@@ -13,9 +13,9 @@ ath9k-$(CONFIG_ATH9K_PCI) += pci.o ath9k-$(CONFIG_ATH9K_AHB) += ahb.o ath9k-$(CONFIG_ATH9K_DEBUGFS) += debug.o ath9k-$(CONFIG_ATH9K_DFS_DEBUGFS) += dfs_debug.o -ath9k-$(CONFIG_ATH9K_DFS_CERTIFIED) += \ - dfs.o +ath9k-$(CONFIG_ATH9K_DFS_CERTIFIED) += dfs.o ath9k-$(CONFIG_PM_SLEEP) += wow.o +ath9k-$(CONFIG_ATH9K_TX99) += tx99.o obj-$(CONFIG_ATH9K) += ath9k.o
drivers/net/wireless/ath/ath9k/ath9k.h +18 -2
@@ -947,10 +947,25 @@ struct fft_sample_ht20_40 {u8 data[SPECTRAL_HT20_40_NUM_BINS ]; } __packed; -int ath9k_tx99_init (struct ath_softc *sc); -void ath9k_tx99_deinit (struct ath_softc *sc); +/********/ +/* TX99 */ +/********/ + +#ifdef CONFIG_ATH9K_TX99 +void ath9k_tx99_init_debug (struct ath_softc *sc);int ath9k_tx99_send (struct ath_softc *sc,struct sk_buff *skb,struct ath_tx_control *txctl); +#else +static inline void ath9k_tx99_init_debug (struct ath_softc *sc) +{ +} +static inline int ath9k_tx99_send (struct ath_softc *sc, +struct sk_buff *skb, +struct ath_tx_control *txctl) +{ +return 0 ; +} +#endif /* CONFIG_ATH9K_TX99 */ void ath9k_tasklet (unsigned long data);int ath_cabq_update (struct ath_softc *);
@@ -967,6 +982,7 @@ extern bool is_ath9k_unloaded;u8 ath9k_parse_mpdudensity (u8 mpdudensity);irqreturn_t ath_isr (int irq,void *dev); +int ath_reset (struct ath_softc *sc);int ath9k_init_device (u16 devid,struct ath_softc *sc,const struct ath_bus_ops *bus_ops);void ath9k_deinit_device (struct ath_softc *sc);
drivers/net/wireless/ath/ath9k/debug.c +1 -114
133 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/main.c +1 -129
142 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/tx99.c new file +263 -0
263 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/xmit.c +4 -0
@@ -2749,6 +2749,8 @@ void ath_tx_node_cleanup(struct ath_softc *sc, struct ath_node *an) } } +#ifdef CONFIG_ATH9K_TX99 +int ath9k_tx99_send (struct ath_softc *sc,struct sk_buff *skb,struct ath_tx_control *txctl) {
@@ -2791,3 +2793,5 @@ int ath9k_tx99_send(struct ath_softc *sc, struct sk_buff *skb, return 0; } + +#endif /* CONFIG_ATH9K_TX99 */
Signature · 1 line
1.8.4.2
PATCH 4/13 ath9k: Fix wow.c compilation
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
The HW routines to set various WoW registers are present in wow.c. For some reason, it has been compiled as part of the main ath9k.ko module all this time, when it should really be part of ath9k_hw.ko. This patch renames the file to ar9003_wow.ko and adds it to ath9k_hw.ko.
--- drivers/net/wireless/ath/ath9k/Makefile | 3 +- drivers/net/wireless/ath/ath9k/ar9003_wow.c | 422 ++++++++++++++++++++++++++++ drivers/net/wireless/ath/ath9k/wow.c | 422 ---------------------------- 3 files changed, 424 insertions(+), 423 deletions(-) create mode 100644 drivers/net/wireless/ath/ath9k/ar9003_wow.c delete mode 100644 drivers/net/wireless/ath/ath9k/wow.c
drivers/net/wireless/ath/ath9k/Makefile +2 -1
@@ -14,7 +14,6 @@ ath9k-$(CONFIG_ATH9K_AHB) += ahb.o ath9k-$(CONFIG_ATH9K_DEBUGFS) += debug.o ath9k-$(CONFIG_ATH9K_DFS_DEBUGFS) += dfs_debug.o ath9k-$(CONFIG_ATH9K_DFS_CERTIFIED) += dfs.o -ath9k-$(CONFIG_PM_SLEEP) += wow.o ath9k-$(CONFIG_ATH9K_TX99) += tx99.o obj-$(CONFIG_ATH9K) += ath9k.o
@@ -41,6 +40,8 @@ ath9k_hw-y:= \ ar9003_eeprom.o \ ar9003_paprd.o +ath9k_hw-$(CONFIG_PM_SLEEP) += ar9003_wow.o + ath9k_hw-$(CONFIG_ATH9K_BTCOEX_SUPPORT) += btcoex.o \ ar9003_mci.o obj-$(CONFIG_ATH9K_HW) += ath9k_hw.o
drivers/net/wireless/ath/ath9k/ar9003_wow.c new file +422 -0
422 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/wow.c deleted +0 -422
422 lines not on this page · raw message
Signature · 1 line
1.8.4.2
PATCH 5/13 ath9k: Add a config option for WoW
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/Kconfig | 8 ++++++++ 1 file changed, 8 insertions(+)
drivers/net/wireless/ath/ath9k/Kconfig +8 -0
@@ -104,6 +104,14 @@ config ATH9K_TX99 be evaluated to meet the RF exposure limits set forth in the governmental SAR regulations. +config ATH9K_WOW + bool "Wake on Wireless LAN support (EXPERIMENTAL)" + depends on ATH9K && PM + default n + ---help--- + This option enables Wake on Wireless LAN support for certain cards. + Currently, AR9462 is supported. + config ATH9K_LEGACY_RATE_CONTROL bool "Atheros ath9k rate control" depends on ATH9K
Signature · 1 line
1.8.4.2
PATCH 6/13 ath9k: Use CONFIG_ATH9K_WOW
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
Move the WoW code to wow.c and compile it conditionally based on CONFIG_ATH9K_WOW.
--- drivers/net/wireless/ath/ath9k/Makefile | 3 +- drivers/net/wireless/ath/ath9k/ath9k.h | 28 ++- drivers/net/wireless/ath/ath9k/hw.h | 4 +- drivers/net/wireless/ath/ath9k/init.c | 4 +- drivers/net/wireless/ath/ath9k/main.c | 338 +------------------------------ drivers/net/wireless/ath/ath9k/wow.c | 341 ++++++++++++++++++++++++++++++++ 6 files changed, 381 insertions(+), 337 deletions(-) create mode 100644 drivers/net/wireless/ath/ath9k/wow.c
drivers/net/wireless/ath/ath9k/Makefile +2 -1
@@ -15,6 +15,7 @@ ath9k-$(CONFIG_ATH9K_DEBUGFS) += debug.o ath9k-$(CONFIG_ATH9K_DFS_DEBUGFS) += dfs_debug.o ath9k-$(CONFIG_ATH9K_DFS_CERTIFIED) += dfs.o ath9k-$(CONFIG_ATH9K_TX99) += tx99.o +ath9k-$(CONFIG_ATH9K_WOW) += wow.o obj-$(CONFIG_ATH9K) += ath9k.o
@@ -40,7 +41,7 @@ ath9k_hw-y:= \ ar9003_eeprom.o \ ar9003_paprd.o -ath9k_hw-$(CONFIG_PM_SLEEP) += ar9003_wow.o +ath9k_hw-$(CONFIG_ATH9K_WOW) += ar9003_wow.o ath9k_hw-$(CONFIG_ATH9K_BTCOEX_SUPPORT) += btcoex.o \ ar9003_mci.o
drivers/net/wireless/ath/ath9k/ath9k.h +27 -1
@@ -570,6 +570,30 @@ static inline void ath_fill_led_pin(struct ath_softc *sc) }#endif +/************************/ +/* Wake on Wireless LAN */ +/************************/ + +#ifdef CONFIG_ATH9K_WOW +int ath9k_suspend (struct ieee80211_hw *hw, +struct cfg80211_wowlan *wowlan); +int ath9k_resume (struct ieee80211_hw *hw); +void ath9k_set_wakeup (struct ieee80211_hw *hw,bool enabled); +#else +static inline int ath9k_suspend (struct ieee80211_hw *hw, +struct cfg80211_wowlan *wowlan) +{ +return 0 ; +} +static inline int ath9k_resume (struct ieee80211_hw *hw) +{ +return 0 ; +} +static inline void ath9k_set_wakeup (struct ieee80211_hw *hw,bool enabled) +{ +} +#endif /* CONFIG_ATH9K_WOW */ +/*******************************/ /* Antenna diversity/combining */ /*******************************/
@@ -784,7 +808,7 @@ struct ath_softc {bool tx99_state;s16 tx99_power; -#ifdef CONFIG_PM_SLEEP +#ifdef CONFIG_ATH9K_WOW atomic_t wow_got_bmiss_intr;atomic_t wow_sleep_proc_intr;/* in the middle of WoW sleep ? */ u32 wow_intr_before_sleep;
@@ -983,6 +1007,8 @@ extern bool is_ath9k_unloaded;u8 ath9k_parse_mpdudensity (u8 mpdudensity);irqreturn_t ath_isr (int irq,void *dev);int ath_reset (struct ath_softc *sc); +void ath_cancel_work (struct ath_softc *sc); +void ath_restart_work (struct ath_softc *sc);int ath9k_init_device (u16 devid,struct ath_softc *sc,const struct ath_bus_ops *bus_ops);void ath9k_deinit_device (struct ath_softc *sc);
drivers/net/wireless/ath/ath9k/hw.h +2 -2
@@ -920,7 +920,7 @@ struct ath_hw {/* Enterprise mode cap */ u32 ent_mode; -#ifdef CONFIG_PM_SLEEP +#ifdef CONFIG_ATH9K_WOW u32 wow_event_mask;#endif bool is_clk_25mhz;
@@ -1126,7 +1126,7 @@ ath9k_hw_get_btcoex_scheme(struct ath_hw *ah)#endif /* CONFIG_ATH9K_BTCOEX_SUPPORT */ -#ifdef CONFIG_PM_SLEEP +#ifdef CONFIG_ATH9K_WOW const char *ath9k_hw_wow_event_to_string (u32 wow_event); void ath9k_hw_wow_apply_pattern(struct ath_hw *ah, u8 *user_pattern, u8 *user_mask, int pattern_count,
drivers/net/wireless/ath/ath9k/init.c +2 -2
@@ -870,7 +870,7 @@ static const struct ieee80211_iface_combination if_comb[] = { } }; -#ifdef CONFIG_PM +#ifdef CONFIG_ATH9K_WOW static const struct wiphy_wowlan_support ath9k_wowlan_support = { .flags =WIPHY_WOWLAN_MAGIC_PKT |WIPHY_WOWLAN_DISCONNECT , .n_patterns = MAX_NUM_USER_PATTERN,
@@ -928,7 +928,7 @@ void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw) hw->wiphy->flags |=WIPHY_FLAG_SUPPORTS_5_10_MHZ ; hw->wiphy->flags |=WIPHY_FLAG_HAS_CHANNEL_SWITCH ; -#ifdef CONFIG_PM_SLEEP +#ifdef CONFIG_ATH9K_WOW if ((ah->caps.hw_caps &ATH9K_HW_WOW_DEVICE_CAPABLE ) && (sc->driver_data &ATH9K_PCI_WOW ) &&device_can_wakeup (sc->dev))
drivers/net/wireless/ath/ath9k/main.c +7 -331
373 lines not on this page · raw message
drivers/net/wireless/ath/ath9k/wow.c new file +341 -0
341 lines not on this page · raw message
Signature · 1 line
1.8.4.2
PATCH 7/13 ath9k: Add an initialization routine for WoW
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/ath9k.h | 4 ++++ drivers/net/wireless/ath/ath9k/init.c | 20 +------------------- drivers/net/wireless/ath/ath9k/wow.c | 20 ++++++++++++++++++++ 3 files changed, 25 insertions(+), 19 deletions(-)
drivers/net/wireless/ath/ath9k/ath9k.h +4 -0
@@ -575,11 +575,15 @@ static inline void ath_fill_led_pin(struct ath_softc *sc)/************************/ #ifdef CONFIG_ATH9K_WOW +void ath9k_init_wow (struct ieee80211_hw *hw);int ath9k_suspend (struct ieee80211_hw *hw,struct cfg80211_wowlan *wowlan);int ath9k_resume (struct ieee80211_hw *hw);void ath9k_set_wakeup (struct ieee80211_hw *hw,bool enabled);#else +static inline void ath9k_init_wow (struct ieee80211_hw *hw) +{ +}static inline int ath9k_suspend (struct ieee80211_hw *hw,struct cfg80211_wowlan *wowlan) {
drivers/net/wireless/ath/ath9k/init.c +1 -19
@@ -870,15 +870,6 @@ static const struct ieee80211_iface_combination if_comb[] = { } }; -#ifdef CONFIG_ATH9K_WOW -static const struct wiphy_wowlan_support ath9k_wowlan_support = { - .flags =WIPHY_WOWLAN_MAGIC_PKT |WIPHY_WOWLAN_DISCONNECT , - .n_patterns =MAX_NUM_USER_PATTERN , - .pattern_min_len =1 , - .pattern_max_len =MAX_PATTERN_SIZE , -}; -#endif -void ath9k_set_hw_capab (struct ath_softc *sc,struct ieee80211_hw *hw) {struct ath_hw *ah = sc->sc_ah;
@@ -928,16 +919,6 @@ void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw) hw->wiphy->flags |=WIPHY_FLAG_SUPPORTS_5_10_MHZ ; hw->wiphy->flags |=WIPHY_FLAG_HAS_CHANNEL_SWITCH ; -#ifdef CONFIG_ATH9K_WOW -if ((ah->caps.hw_caps &ATH9K_HW_WOW_DEVICE_CAPABLE ) && - (sc->driver_data &ATH9K_PCI_WOW ) && -device_can_wakeup (sc->dev)) - hw->wiphy->wowlan = &ath9k_wowlan_support; - -atomic_set (&sc->wow_sleep_proc_intr,-1 ); -atomic_set (&sc->wow_got_bmiss_intr,-1 ); -#endif - hw->queues =4 ; hw->max_rates =4 ; hw->channel_change_time =5000 ;
@@ -963,6 +944,7 @@ void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw) hw->wiphy->bands[IEEE80211_BAND_5GHZ ] = &sc->sbands[IEEE80211_BAND_5GHZ ]; +ath9k_init_wow (hw);ath9k_reload_chainmask_settings (sc);SET_IEEE80211_PERM_ADDR (hw, common->macaddr);
drivers/net/wireless/ath/ath9k/wow.c +20 -0
@@ -16,6 +16,13 @@#include "ath9k.h" +static const struct wiphy_wowlan_support ath9k_wowlan_support = { + .flags =WIPHY_WOWLAN_MAGIC_PKT |WIPHY_WOWLAN_DISCONNECT , + .n_patterns =MAX_NUM_USER_PATTERN , + .pattern_min_len =1 , + .pattern_max_len =MAX_PATTERN_SIZE , +}; +static void ath9k_wow_map_triggers (struct ath_softc *sc,struct cfg80211_wowlan *wowlan,u32 *wow_triggers)
@@ -339,3 +346,16 @@ void ath9k_set_wakeup(struct ieee80211_hw *hw, bool enabled)device_set_wakeup_enable (sc->dev, enabled);mutex_unlock (&sc->mutex); } + +void ath9k_init_wow (struct ieee80211_hw *hw) +{ +struct ath_softc *sc = hw->priv; + +if ((sc->sc_ah->caps.hw_caps &ATH9K_HW_WOW_DEVICE_CAPABLE ) && + (sc->driver_data &ATH9K_PCI_WOW ) && +device_can_wakeup (sc->dev)) + hw->wiphy->wowlan = &ath9k_wowlan_support; + +atomic_set (&sc->wow_sleep_proc_intr,-1 ); +atomic_set (&sc->wow_got_bmiss_intr,-1 ); +}
Signature · 1 line
1.8.4.2
PATCH 8/13 ath9k: Add SERDES initvals for AR9462 2.1
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 4 ++++ drivers/net/wireless/ath/ath9k/ar9462_2p1_initvals.h | 7 +++++++ 2 files changed, 11 insertions(+)
drivers/net/wireless/ath/ath9k/ar9003_hw.c +4 -0
@@ -223,6 +223,10 @@ static void ar9003_hw_init_mode_regs(struct ath_hw *ah) ar9462_2p1_modes_fast_clock);INIT_INI_ARRAY (&ah->iniCckfirJapan2484, ar9462_2p1_baseband_core_txfir_coeff_japan_2484); +INIT_INI_ARRAY (&ah->iniPcieSerdes, + ar9462_2p1_pciephy_clkreq_disable_L1); +INIT_INI_ARRAY (&ah->iniPcieSerdesLowPower, + ar9462_2p1_pciephy_clkreq_disable_L1); }else if (AR_SREV_9462_20 (ah)) {INIT_INI_ARRAY (&ah->iniMac[ATH_INI_CORE ], ar9462_2p0_mac_core);
drivers/net/wireless/ath/ath9k/ar9462_2p1_initvals.h +7 -0
@@ -1771,4 +1771,11 @@ static const u32 ar9462_2p1_baseband_core_txfir_coeff_japan_2484[][2] = { {0x0000a3a0, 0xca9228ee}, }; +static const u32 ar9462_2p1_pciephy_clkreq_disable_L1[][2] = { + /* Addr allmodes */ + {0x00018c00, 0x18213ede}, + {0x00018c04, 0x000801d8}, + {0x00018c08, 0x0003780c}, +}; + #endif /* INITVALS_9462_2P1_H */
Signature · 1 line
1.8.4.2
PATCH 9/13 ath9k: Remove unused AR9462 2.0 initvals
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- drivers/net/wireless/ath/ath9k/ar9462_2p0_initvals.h | 14 -------------- 1 file changed, 14 deletions(-)
drivers/net/wireless/ath/ath9k/ar9462_2p0_initvals.h +0 -14
@@ -33,13 +33,6 @@ static const u32 ar9462_modes_fast_clock_2p0[][3] = { {0x0000a254, 0x00000898, 0x00001130}, }; -static const u32 ar9462_pciephy_clkreq_enable_L1_2p0[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18253ede }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0003780c }, -}; -static const u32 ar9462_2p0_baseband_postamble[][5 ] = {/* Addr 5G_HT20 5G_HT40 2G_HT40 2G_HT20 */ {0x00009810, 0xd00a8005, 0xd00a8005, 0xd00a8011, 0xd00a800d},
@@ -366,13 +359,6 @@ static const u32 ar9462_pciephy_clkreq_disable_L1_2p0[][2] = { {0x00018c08, 0x0003780c}, }; -static const u32 ar9462_pciephy_pll_on_clkreq_disable_L1_2p0[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18212ede }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0003780c }, -}; -static const u32 ar9462_2p0_radio_postamble_sys2ant[][5 ] = {/* Addr 5G_HT20 5G_HT40 2G_HT40 2G_HT20 */ {0x000160ac, 0xa4646c08, 0xa4646c08, 0x24645808, 0x24645808},
Signature · 1 line
1.8.4.2
PATCH 10/13 ath9k: Remove pcieSerDesWrite
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
This HW config option is always set to true and is not needed.
--- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 20 +++++++++----------- drivers/net/wireless/ath/ath9k/hw.c | 1 - drivers/net/wireless/ath/ath9k/hw.h | 1 - 3 files changed, 9 insertions(+), 13 deletions(-)
drivers/net/wireless/ath/ath9k/ar9003_hw.c +9 -11
@@ -754,6 +754,9 @@ static void ar9003_hw_init_mode_gain_regs(struct ath_hw *ah)static void ar9003_hw_configpcipowersave (struct ath_hw *ah,bool power_off) { +unsigned int i; +struct ar5416IniArray *array; +/* * Increase L1 Entry Latency. Some WB222 boards don't have * this change in eeprom/OTP.
@@ -779,18 +782,13 @@ static void ar9003_hw_configpcipowersave(struct ath_hw *ah,* Configire PCIE after Ini init. SERDES values now come from ini file * This enables PCIe low power mode. */ -if (ah->config.pcieSerDesWrite) { -unsigned int i; -struct ar5416IniArray *array; - - array = power_off ? &ah->iniPcieSerdes : - &ah->iniPcieSerdesLowPower; + array = power_off ? &ah->iniPcieSerdes : + &ah->iniPcieSerdesLowPower; -for (i =0 ; i < array->ia_rows; i++) { -REG_WRITE (ah, -INI_RA (array, i,0 ), -INI_RA (array, i,1 )); - } +for (i =0 ; i < array->ia_rows; i++) { +REG_WRITE (ah, +INI_RA (array, i,0 ), +INI_RA (array, i,1 )); } }
drivers/net/wireless/ath/ath9k/hw.c +0 -1
@@ -454,7 +454,6 @@ static void ath9k_hw_init_config(struct ath_hw *ah) } ah->config.rx_intr_mitigation = true; - ah->config.pcieSerDesWrite = true;/* * We need this for PCI devices only (Cardbus, PCI, miniPCI)
drivers/net/wireless/ath/ath9k/hw.h +0 -1
@@ -283,7 +283,6 @@ struct ath9k_ops_config {int additional_swba_backoff;int ack_6mb;u32 cwm_ignore_extcca; -bool pcieSerDesWrite;u8 pcie_clock_req;u32 pcie_waen;u8 analog_shiftreg;
Signature · 1 line
1.8.4.2
PATCH 11/13 ath9k: Use correct PCIE initvals for AR9485
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
Currently, the PLL is turned off for AR9485 when switching to a low power state, but AR9485 has an issue where the card will become unresponsive if left idle for a long time without any traffic. To fix this, force the PLL to always be on using a different initval array, ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1.
--- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 11 ++------ drivers/net/wireless/ath/ath9k/ar9485_initvals.h | 35 +++++------------------- 2 files changed, 9 insertions(+), 37 deletions(-)
drivers/net/wireless/ath/ath9k/ar9003_hw.c +2 -9
@@ -187,17 +187,10 @@ static void ar9003_hw_init_mode_regs(struct ath_hw *ah)INIT_INI_ARRAY (&ah->iniCckfirJapan2484, ar9485_1_1_baseband_core_txfir_coeff_japan_2484); -/* Load PCIE SERDES settings from INI */ - -/* Awake Setting */ -INIT_INI_ARRAY (&ah->iniPcieSerdes, - ar9485_1_1_pcie_phy_clkreq_disable_L1); - -/* Sleep Setting */ - + ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1);INIT_INI_ARRAY (&ah->iniPcieSerdesLowPower, - ar9485_1_1_pcie_phy_clkreq_disable_L1); + ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1); }else if (AR_SREV_9462_21 (ah)) {INIT_INI_ARRAY (&ah->iniMac[ATH_INI_CORE ], ar9462_2p1_mac_core);
drivers/net/wireless/ath/ath9k/ar9485_initvals.h +7 -28
@@ -32,13 +32,6 @@ static const u32 ar9485_1_1_mac_postamble[][5] = { {0x00008318, 0x00003e80, 0x00007d00, 0x00006880, 0x00003440}, }; -static const u32 ar9485_1_1_pcie_phy_pll_on_clkreq_disable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18012e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485Common_wo_xlna_rx_gain_1_1[][2 ] = {/* Addr allmodes */ {0x00009e00, 0x037216a0},
@@ -1101,20 +1094,6 @@ static const u32 ar9485_common_rx_gain_1_1[][2] = { {0x0000a1fc, 0x00000296}, }; -static const u32 ar9485_1_1_pcie_phy_pll_on_clkreq_enable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18052e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; - -static const u32 ar9485_1_1_pcie_phy_clkreq_enable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18053e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485_1_1_soc_preamble[][2 ] = {/* Addr allmodes */ {0x00004014, 0xba280400},
@@ -1173,13 +1152,6 @@ static const u32 ar9485_1_1_baseband_postamble[][5] = { {0x0000be18, 0x00000000, 0x00000000, 0x00000000, 0x00000000}, }; -static const u32 ar9485_1_1_pcie_phy_clkreq_disable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18013e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485_1_1_radio_postamble[][2 ] = {/* Addr allmodes */ {0x0001609c, 0x0b283f31},
@@ -1358,4 +1330,11 @@ static const u32 ar9485_1_1_baseband_core_txfir_coeff_japan_2484[][2] = { {0x0000a3a0, 0xca9228ee}, }; +static const u32 ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1[][2] = { + /* Addr allmodes */ + {0x00018c00, 0x1801265e}, + {0x00018c04, 0x000801d8}, + {0x00018c08, 0x0000080c}, +}; + #endif /* INITVALS_9485_H */
Signature · 1 line
1.8.4.2
Re: [PATCH 11/13] ath9k: Use correct PCIE initvals for AR9485
John,
Please drop this patch. This fix is not applicable to a few variants based on AR9485 - they need to be identified.
Sujith
Quoted 111 lines · Sujith Manoharan
From: Sujith Manoharan <[email protected]>
Currently, the PLL is turned off for AR9485 when switching to a low power state, but AR9485 has an issue where the card will become unresponsive if left idle for a long time without any traffic. To fix this, force the PLL to always be on using a different initval array,
ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1.Signed-off-by Sujith Manoharan <[email protected]>--- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 11 ++------ drivers/net/wireless/ath/ath9k/ar9485_initvals.h | 35 +++++------------------- 2 files changed, 9 insertions(+), 37 deletions(-)drivers/net/wireless/ath/ath9k/ar9003_hw.c +2
-9@@ -187,17 +187,10 @@ static void ar9003_hw_init_mode_regs(struct ath_hw *ah)INIT_INI_ARRAY (&ah->iniCckfirJapan2484, ar9485_1_1_baseband_core_txfir_coeff_japan_2484); -/* Load PCIE SERDES settings from INI */ - -/* Awake Setting */ -INIT_INI_ARRAY (&ah->iniPcieSerdes, - ar9485_1_1_pcie_phy_clkreq_disable_L1); - -/* Sleep Setting */ - + ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1);INIT_INI_ARRAY (&ah->iniPcieSerdesLowPower, - ar9485_1_1_pcie_phy_clkreq_disable_L1); + ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1); }else if (AR_SREV_9462_21 (ah)) {INIT_INI_ARRAY (&ah->iniMac[ATH_INI_CORE ], ar9462_2p1_mac_core);drivers/net/wireless/ath/ath9k/ar9485_initvals.h +7
-28@@ -32,13 +32,6 @@ static const u32 ar9485_1_1_mac_postamble[][5] = { {0x00008318, 0x00003e80, 0x00007d00, 0x00006880, 0x00003440}, }; -static const u32 ar9485_1_1_pcie_phy_pll_on_clkreq_disable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18012e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485Common_wo_xlna_rx_gain_1_1[][2 ] = {/* Addr allmodes */ {0x00009e00, 0x037216a0},@@ -1101,20 +1094,6 @@ static const u32 ar9485_common_rx_gain_1_1[][2] = { {0x0000a1fc, 0x00000296}, }; -static const u32 ar9485_1_1_pcie_phy_pll_on_clkreq_enable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18052e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; - -static const u32 ar9485_1_1_pcie_phy_clkreq_enable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18053e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485_1_1_soc_preamble[][2 ] = {/* Addr allmodes */ {0x00004014, 0xba280400},@@ -1173,13 +1152,6 @@ static const u32 ar9485_1_1_baseband_postamble[][5] = { {0x0000be18, 0x00000000, 0x00000000, 0x00000000, 0x00000000}, }; -static const u32 ar9485_1_1_pcie_phy_clkreq_disable_L1[][2 ] = { -/* Addr allmodes */ - {0x00018c00 ,0x18013e5e }, - {0x00018c04 ,0x000801d8 }, - {0x00018c08 ,0x0000080c }, -}; -static const u32 ar9485_1_1_radio_postamble[][2 ] = {/* Addr allmodes */ {0x0001609c, 0x0b283f31},@@ -1358,4 +1330,11 @@ static const u32 ar9485_1_1_baseband_core_txfir_coeff_japan_2484[][2] = { {0x0000a3a0, 0xca9228ee}, }; +static const u32 ar9485_1_1_pll_on_cdr_on_clkreq_disable_L1[][2] = { + /* Addr allmodes */ + {0x00018c00, 0x1801265e}, + {0x00018c04, 0x000801d8}, + {0x00018c08, 0x0000080c}, +}; + #endif /* INITVALS_9485_H */Signature · 6 lines
1.8.4.2 -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
PATCH 12/13 ath9k: Apply CUS227 specific TX gain values
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
CUS227, which is an AR9340 based card used in Qualcomm's Allplay platforms requires a custom TX gain array, based on the index 7. Add suport for this.
--- drivers/net/wireless/ath/ath9k/ar9003_hw.c | 8 ++ drivers/net/wireless/ath/ath9k/ar9340_initvals.h | 102 +++++++++++++++++++++++ 2 files changed, 110 insertions(+)
drivers/net/wireless/ath/ath9k/ar9003_hw.c +8 -0
@@ -578,6 +578,13 @@ static void ar9003_tx_gain_table_mode6(struct ath_hw *ah) ar9580_1p0_type6_tx_gain_table); } +static void ar9003_tx_gain_table_mode7 (struct ath_hw *ah) +{ +if (AR_SREV_9340 (ah)) +INIT_INI_ARRAY (&ah->iniModesTxGain, + ar9340_cus227_tx_gain_table_1p0); +} +typedef void (*ath_txgain_tab )(struct ath_hw *ah);static void ar9003_tx_gain_table_apply (struct ath_hw *ah)
@@ -590,6 +597,7 @@ static void ar9003_tx_gain_table_apply(struct ath_hw *ah) ar9003_tx_gain_table_mode4, ar9003_tx_gain_table_mode5, ar9003_tx_gain_table_mode6, + ar9003_tx_gain_table_mode7, };int idx =ar9003_hw_get_tx_gain_idx (ah);
drivers/net/wireless/ath/ath9k/ar9340_initvals.h +102 -0
106 lines not on this page · raw message
Signature · 1 line
1.8.4.2
PATCH 13/13 ath9k: Update MAINTAINERS
In reply to Sujith ManoharanFrom: Sujith Manoharan <[email protected]>
--- MAINTAINERS | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-)
MAINTAINERS +8 -11
@@ -1444,17 +1444,6 @@ T: git git://github.com/kvalo/ath.git S: Supported F: drivers/net/wireless/ath/ath6kl/ -ATHEROS ATH9K WIRELESS DRIVER -M: "Luis R. Rodriguez" <[email protected]> -M: Jouni Malinen <[email protected]> -M: Vasanthakumar Thiagarajan <[email protected]> -M: Senthil Balasubramanian <[email protected]> -L: [email protected] -L: [email protected] -W: http://wireless.kernel.org/en/users/Drivers/ath9k -S: Supported -F: drivers/net/wireless/ath/ath9k/ - WILOCITY WIL6210 WIRELESS DRIVER M: Vladimir Kondratiev <[email protected]> L: [email protected]
@@ -6849,6 +6838,14 @@ T: git git://linuxtv.org/anttip/media_tree.git S: Maintained F: drivers/media/tuners/qt1010* +QUALCOMM ATHEROS ATH9K WIRELESS DRIVER +M: QCA ath9k Development <[email protected]> +L: [email protected] +L: [email protected] +W: http://wireless.kernel.org/en/users/Drivers/ath9k +S: Supported +F: drivers/net/wireless/ath/ath9k/ + QUALCOMM ATHEROS ATH10K WIRELESS DRIVER M: Kalle Valo <[email protected]> L: [email protected]
Signature · 1 line
1.8.4.2
Re: [PATCH 13/13] ath9k: Update MAINTAINERS
Quoted 30 lines · Sujith Manoharan
From: Sujith Manoharan <[email protected]>
Signed-off-by Sujith Manoharan <[email protected]>--- MAINTAINERS | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-)MAINTAINERS +0
-11@@ -1444,17 +1444,6 @@ T: git git://github.com/kvalo/ath.git S: Supported F: drivers/net/wireless/ath/ath6kl/ -ATHEROS ATH9K WIRELESS DRIVER -M: "Luis R. Rodriguez" <[email protected]> -M: Jouni Malinen <[email protected]> -M: Vasanthakumar Thiagarajan <[email protected]> -M: Senthil Balasubramanian <[email protected]> -L: [email protected] -L: [email protected] -W: http://wireless.kernel.org/en/users/Drivers/ath9k -S: Supported -F: drivers/net/wireless/ath/ath9k/ - WILOCITY WIL6210 WIRELESS DRIVER M: Vladimir Kondratiev <[email protected]> L: [email protected]
MAINTAINERS T: git git://linuxtv.org/anttip/media_tree.git · line 6842
Quoted 5 lines
MAINTAINERS +2
-0@@ -6849,6 +6838,14 @@ T: git git://linuxtv.org/anttip/media_tree.git S: Maintained F: drivers/media/tuners/qt1010* +QUALCOMM ATHEROS ATH9K WIRELESS DRIVER +M: QCA ath9k Development <[email protected]>
While I don't have a problem with this, it's
more common to appoint a single person as a
"lead" maintainer.
Quoted 9 lines
MAINTAINERS +6
-0+L: [email protected] +L: [email protected] +W: http://wireless.kernel.org/en/users/Drivers/ath9k +S: Supported +F: drivers/net/wireless/ath/ath9k/ + QUALCOMM ATHEROS ATH10K WIRELESS DRIVER M: Kalle Valo <[email protected]> L: [email protected]
Re: [PATCH 13/13] ath9k: Update MAINTAINERS
Quoted 3 lines · Joe Perches
While I don't have a problem with this, it's
more common to appoint a single person as a
"lead" maintainer.
Currently, there is no one to take on this role. But the existing entries are outdated, so the official list seems like a reasonable choice.
Sujith