diff options
author | Luis R. Rodriguez <lrodriguez@atheros.com> | 2009-09-23 23:07:00 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-10-07 16:39:41 -0400 |
commit | 7322fd19295fa7f7d954a19a5f0b77687d441846 (patch) | |
tree | b01daf52514d90ea2941a148059afd97696b614e | |
parent | 475a6e4d3907d6af412d081a9eab3b1e8a24afd1 (diff) |
ath9k: move hw code to its own module
hw code for Atheros 802.11n hardware is commmon between
different chipsets. This moves this code into a separate
module, the next expected user of this code will be
the ath9k_htc module.
The ath9k/ dir is now selected by ATH9K_HW, an option which
gets selected by either ath9k or ath9k_htc, but remains
invisible for user menuconfig configuration. If either
ath9k or ath9k_htc will be compiled into the kernel
ath9k_hw will also be compiled in.
Cc: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/ath/Makefile | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/Kconfig | 4 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/Makefile | 27 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/ani.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/btcoex.c | 6 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/calib.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 61 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/mac.c | 30 |
8 files changed, 121 insertions, 14 deletions
diff --git a/drivers/net/wireless/ath/Makefile b/drivers/net/wireless/ath/Makefile index 5c8e6b2bbaab..8113a5042afa 100644 --- a/drivers/net/wireless/ath/Makefile +++ b/drivers/net/wireless/ath/Makefile | |||
@@ -1,5 +1,5 @@ | |||
1 | obj-$(CONFIG_ATH5K) += ath5k/ | 1 | obj-$(CONFIG_ATH5K) += ath5k/ |
2 | obj-$(CONFIG_ATH9K) += ath9k/ | 2 | obj-$(CONFIG_ATH9K_HW) += ath9k/ |
3 | obj-$(CONFIG_AR9170_USB) += ar9170/ | 3 | obj-$(CONFIG_AR9170_USB) += ar9170/ |
4 | 4 | ||
5 | obj-$(CONFIG_ATH_COMMON) += ath.o | 5 | obj-$(CONFIG_ATH_COMMON) += ath.o |
diff --git a/drivers/net/wireless/ath/ath9k/Kconfig b/drivers/net/wireless/ath/ath9k/Kconfig index de4aeea8a005..99ce066392a7 100644 --- a/drivers/net/wireless/ath/ath9k/Kconfig +++ b/drivers/net/wireless/ath/ath9k/Kconfig | |||
@@ -1,6 +1,10 @@ | |||
1 | config ATH9K_HW | ||
2 | tristate | ||
3 | |||
1 | config ATH9K | 4 | config ATH9K |
2 | tristate "Atheros 802.11n wireless cards support" | 5 | tristate "Atheros 802.11n wireless cards support" |
3 | depends on PCI && MAC80211 && WLAN_80211 | 6 | depends on PCI && MAC80211 && WLAN_80211 |
7 | select ATH9K_HW | ||
4 | select MAC80211_LEDS | 8 | select MAC80211_LEDS |
5 | select LEDS_CLASS | 9 | select LEDS_CLASS |
6 | select NEW_LEDS | 10 | select NEW_LEDS |
diff --git a/drivers/net/wireless/ath/ath9k/Makefile b/drivers/net/wireless/ath/ath9k/Makefile index f3221af73eb7..8caf2a8f8953 100644 --- a/drivers/net/wireless/ath/ath9k/Makefile +++ b/drivers/net/wireless/ath/ath9k/Makefile | |||
@@ -1,16 +1,4 @@ | |||
1 | ATH9K_HW += hw.o \ | 1 | ath9k-y += beacon.o \ |
2 | eeprom.o \ | ||
3 | eeprom_def.o \ | ||
4 | eeprom_4k.o \ | ||
5 | eeprom_9287.o \ | ||
6 | calib.o \ | ||
7 | ani.o \ | ||
8 | phy.o \ | ||
9 | btcoex.o \ | ||
10 | mac.o \ | ||
11 | |||
12 | ath9k-y += $(ATH9K_HW) \ | ||
13 | beacon.o \ | ||
14 | main.o \ | 2 | main.o \ |
15 | recv.o \ | 3 | recv.o \ |
16 | xmit.o \ | 4 | xmit.o \ |
@@ -22,3 +10,16 @@ ath9k-$(CONFIG_ATHEROS_AR71XX) += ahb.o | |||
22 | ath9k-$(CONFIG_ATH9K_DEBUG) += debug.o | 10 | ath9k-$(CONFIG_ATH9K_DEBUG) += debug.o |
23 | 11 | ||
24 | obj-$(CONFIG_ATH9K) += ath9k.o | 12 | obj-$(CONFIG_ATH9K) += ath9k.o |
13 | |||
14 | ath9k_hw-y:= hw.o \ | ||
15 | eeprom.o \ | ||
16 | eeprom_def.o \ | ||
17 | eeprom_4k.o \ | ||
18 | eeprom_9287.o \ | ||
19 | calib.o \ | ||
20 | ani.o \ | ||
21 | phy.o \ | ||
22 | btcoex.o \ | ||
23 | mac.o \ | ||
24 | |||
25 | obj-$(CONFIG_ATH9K_HW) += ath9k_hw.o | ||
diff --git a/drivers/net/wireless/ath/ath9k/ani.c b/drivers/net/wireless/ath/ath9k/ani.c index ecb23f302c3d..2a0cd64c2bfb 100644 --- a/drivers/net/wireless/ath/ath9k/ani.c +++ b/drivers/net/wireless/ath/ath9k/ani.c | |||
@@ -629,6 +629,7 @@ void ath9k_hw_ani_monitor(struct ath_hw *ah, | |||
629 | } | 629 | } |
630 | } | 630 | } |
631 | } | 631 | } |
632 | EXPORT_SYMBOL(ath9k_hw_ani_monitor); | ||
632 | 633 | ||
633 | void ath9k_enable_mib_counters(struct ath_hw *ah) | 634 | void ath9k_enable_mib_counters(struct ath_hw *ah) |
634 | { | 635 | { |
@@ -756,6 +757,7 @@ void ath9k_hw_procmibevent(struct ath_hw *ah) | |||
756 | ath9k_ani_restart(ah); | 757 | ath9k_ani_restart(ah); |
757 | } | 758 | } |
758 | } | 759 | } |
760 | EXPORT_SYMBOL(ath9k_hw_procmibevent); | ||
759 | 761 | ||
760 | void ath9k_hw_ani_setup(struct ath_hw *ah) | 762 | void ath9k_hw_ani_setup(struct ath_hw *ah) |
761 | { | 763 | { |
diff --git a/drivers/net/wireless/ath/ath9k/btcoex.c b/drivers/net/wireless/ath/ath9k/btcoex.c index 0c54489ca443..fb4ac15f3b93 100644 --- a/drivers/net/wireless/ath/ath9k/btcoex.c +++ b/drivers/net/wireless/ath/ath9k/btcoex.c | |||
@@ -95,6 +95,7 @@ void ath9k_hw_init_btcoex_hw(struct ath_hw *ah, int qnum) | |||
95 | for (i = 0; i < 32; i++) | 95 | for (i = 0; i < 32; i++) |
96 | ah->hw_gen_timers.gen_timer_index[(debruijn32 << i) >> 27] = i; | 96 | ah->hw_gen_timers.gen_timer_index[(debruijn32 << i) >> 27] = i; |
97 | } | 97 | } |
98 | EXPORT_SYMBOL(ath9k_hw_init_btcoex_hw); | ||
98 | 99 | ||
99 | void ath9k_hw_btcoex_init_2wire(struct ath_hw *ah) | 100 | void ath9k_hw_btcoex_init_2wire(struct ath_hw *ah) |
100 | { | 101 | { |
@@ -116,6 +117,7 @@ void ath9k_hw_btcoex_init_2wire(struct ath_hw *ah) | |||
116 | /* Configure the desired gpio port for input */ | 117 | /* Configure the desired gpio port for input */ |
117 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btactive_gpio); | 118 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btactive_gpio); |
118 | } | 119 | } |
120 | EXPORT_SYMBOL(ath9k_hw_btcoex_init_2wire); | ||
119 | 121 | ||
120 | void ath9k_hw_btcoex_init_3wire(struct ath_hw *ah) | 122 | void ath9k_hw_btcoex_init_3wire(struct ath_hw *ah) |
121 | { | 123 | { |
@@ -141,6 +143,7 @@ void ath9k_hw_btcoex_init_3wire(struct ath_hw *ah) | |||
141 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btactive_gpio); | 143 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btactive_gpio); |
142 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btpriority_gpio); | 144 | ath9k_hw_cfg_gpio_input(ah, btcoex_hw->btpriority_gpio); |
143 | } | 145 | } |
146 | EXPORT_SYMBOL(ath9k_hw_btcoex_init_3wire); | ||
144 | 147 | ||
145 | static void ath9k_hw_btcoex_enable_2wire(struct ath_hw *ah) | 148 | static void ath9k_hw_btcoex_enable_2wire(struct ath_hw *ah) |
146 | { | 149 | { |
@@ -160,6 +163,7 @@ void ath9k_hw_btcoex_set_weight(struct ath_hw *ah, | |||
160 | btcoex_hw->bt_coex_weights = SM(bt_weight, AR_BTCOEX_BT_WGHT) | | 163 | btcoex_hw->bt_coex_weights = SM(bt_weight, AR_BTCOEX_BT_WGHT) | |
161 | SM(wlan_weight, AR_BTCOEX_WL_WGHT); | 164 | SM(wlan_weight, AR_BTCOEX_WL_WGHT); |
162 | } | 165 | } |
166 | EXPORT_SYMBOL(ath9k_hw_btcoex_set_weight); | ||
163 | 167 | ||
164 | static void ath9k_hw_btcoex_enable_3wire(struct ath_hw *ah) | 168 | static void ath9k_hw_btcoex_enable_3wire(struct ath_hw *ah) |
165 | { | 169 | { |
@@ -201,6 +205,7 @@ void ath9k_hw_btcoex_enable(struct ath_hw *ah) | |||
201 | 205 | ||
202 | ah->btcoex_hw.enabled = true; | 206 | ah->btcoex_hw.enabled = true; |
203 | } | 207 | } |
208 | EXPORT_SYMBOL(ath9k_hw_btcoex_enable); | ||
204 | 209 | ||
205 | void ath9k_hw_btcoex_disable(struct ath_hw *ah) | 210 | void ath9k_hw_btcoex_disable(struct ath_hw *ah) |
206 | { | 211 | { |
@@ -219,3 +224,4 @@ void ath9k_hw_btcoex_disable(struct ath_hw *ah) | |||
219 | 224 | ||
220 | ah->btcoex_hw.enabled = false; | 225 | ah->btcoex_hw.enabled = false; |
221 | } | 226 | } |
227 | EXPORT_SYMBOL(ath9k_hw_btcoex_disable); | ||
diff --git a/drivers/net/wireless/ath/ath9k/calib.c b/drivers/net/wireless/ath/ath9k/calib.c index d347ea79e778..f46bd05df443 100644 --- a/drivers/net/wireless/ath/ath9k/calib.c +++ b/drivers/net/wireless/ath/ath9k/calib.c | |||
@@ -594,6 +594,7 @@ bool ath9k_hw_reset_calvalid(struct ath_hw *ah) | |||
594 | 594 | ||
595 | return false; | 595 | return false; |
596 | } | 596 | } |
597 | EXPORT_SYMBOL(ath9k_hw_reset_calvalid); | ||
597 | 598 | ||
598 | void ath9k_hw_start_nfcal(struct ath_hw *ah) | 599 | void ath9k_hw_start_nfcal(struct ath_hw *ah) |
599 | { | 600 | { |
@@ -746,6 +747,7 @@ s16 ath9k_hw_getchan_noise(struct ath_hw *ah, struct ath9k_channel *chan) | |||
746 | 747 | ||
747 | return nf; | 748 | return nf; |
748 | } | 749 | } |
750 | EXPORT_SYMBOL(ath9k_hw_getchan_noise); | ||
749 | 751 | ||
750 | static void ath9k_olc_temp_compensation_9287(struct ath_hw *ah) | 752 | static void ath9k_olc_temp_compensation_9287(struct ath_hw *ah) |
751 | { | 753 | { |
@@ -1066,6 +1068,7 @@ bool ath9k_hw_calibrate(struct ath_hw *ah, struct ath9k_channel *chan, | |||
1066 | 1068 | ||
1067 | return iscaldone; | 1069 | return iscaldone; |
1068 | } | 1070 | } |
1071 | EXPORT_SYMBOL(ath9k_hw_calibrate); | ||
1069 | 1072 | ||
1070 | static bool ar9285_clc(struct ath_hw *ah, struct ath9k_channel *chan) | 1073 | static bool ar9285_clc(struct ath_hw *ah, struct ath9k_channel *chan) |
1071 | { | 1074 | { |
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 7a4de3d8e6fb..7d167a1b286d 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -33,6 +33,23 @@ static u32 ath9k_hw_ini_fixup(struct ath_hw *ah, | |||
33 | static void ath9k_hw_9280_spur_mitigate(struct ath_hw *ah, struct ath9k_channel *chan); | 33 | static void ath9k_hw_9280_spur_mitigate(struct ath_hw *ah, struct ath9k_channel *chan); |
34 | static void ath9k_hw_spur_mitigate(struct ath_hw *ah, struct ath9k_channel *chan); | 34 | static void ath9k_hw_spur_mitigate(struct ath_hw *ah, struct ath9k_channel *chan); |
35 | 35 | ||
36 | MODULE_AUTHOR("Atheros Communications"); | ||
37 | MODULE_DESCRIPTION("Support for Atheros 802.11n wireless LAN cards."); | ||
38 | MODULE_SUPPORTED_DEVICE("Atheros 802.11n WLAN cards"); | ||
39 | MODULE_LICENSE("Dual BSD/GPL"); | ||
40 | |||
41 | static int __init ath9k_init(void) | ||
42 | { | ||
43 | return 0; | ||
44 | } | ||
45 | module_init(ath9k_init); | ||
46 | |||
47 | static void __exit ath9k_exit(void) | ||
48 | { | ||
49 | return; | ||
50 | } | ||
51 | module_exit(ath9k_exit); | ||
52 | |||
36 | /********************/ | 53 | /********************/ |
37 | /* Helper Functions */ | 54 | /* Helper Functions */ |
38 | /********************/ | 55 | /********************/ |
@@ -99,6 +116,7 @@ bool ath9k_hw_wait(struct ath_hw *ah, u32 reg, u32 mask, u32 val, u32 timeout) | |||
99 | 116 | ||
100 | return false; | 117 | return false; |
101 | } | 118 | } |
119 | EXPORT_SYMBOL(ath9k_hw_wait); | ||
102 | 120 | ||
103 | u32 ath9k_hw_reverse_bits(u32 val, u32 n) | 121 | u32 ath9k_hw_reverse_bits(u32 val, u32 n) |
104 | { | 122 | { |
@@ -186,6 +204,7 @@ u16 ath9k_hw_computetxtime(struct ath_hw *ah, | |||
186 | 204 | ||
187 | return txTime; | 205 | return txTime; |
188 | } | 206 | } |
207 | EXPORT_SYMBOL(ath9k_hw_computetxtime); | ||
189 | 208 | ||
190 | void ath9k_hw_get_channel_centers(struct ath_hw *ah, | 209 | void ath9k_hw_get_channel_centers(struct ath_hw *ah, |
191 | struct ath9k_channel *chan, | 210 | struct ath9k_channel *chan, |
@@ -402,6 +421,7 @@ static void ath9k_hw_init_config(struct ath_hw *ah) | |||
402 | if (num_possible_cpus() > 1) | 421 | if (num_possible_cpus() > 1) |
403 | ah->config.serialize_regmode = SER_REG_MODE_AUTO; | 422 | ah->config.serialize_regmode = SER_REG_MODE_AUTO; |
404 | } | 423 | } |
424 | EXPORT_SYMBOL(ath9k_hw_init); | ||
405 | 425 | ||
406 | static void ath9k_hw_init_defaults(struct ath_hw *ah) | 426 | static void ath9k_hw_init_defaults(struct ath_hw *ah) |
407 | { | 427 | { |
@@ -1223,6 +1243,7 @@ void ath9k_hw_detach(struct ath_hw *ah) | |||
1223 | kfree(ah); | 1243 | kfree(ah); |
1224 | ah = NULL; | 1244 | ah = NULL; |
1225 | } | 1245 | } |
1246 | EXPORT_SYMBOL(ath9k_hw_detach); | ||
1226 | 1247 | ||
1227 | /*******/ | 1248 | /*******/ |
1228 | /* INI */ | 1249 | /* INI */ |
@@ -2561,6 +2582,7 @@ int ath9k_hw_reset(struct ath_hw *ah, struct ath9k_channel *chan, | |||
2561 | 2582 | ||
2562 | return 0; | 2583 | return 0; |
2563 | } | 2584 | } |
2585 | EXPORT_SYMBOL(ath9k_hw_reset); | ||
2564 | 2586 | ||
2565 | /************************/ | 2587 | /************************/ |
2566 | /* Key Cache Management */ | 2588 | /* Key Cache Management */ |
@@ -2599,6 +2621,7 @@ bool ath9k_hw_keyreset(struct ath_hw *ah, u16 entry) | |||
2599 | 2621 | ||
2600 | return true; | 2622 | return true; |
2601 | } | 2623 | } |
2624 | EXPORT_SYMBOL(ath9k_hw_keyreset); | ||
2602 | 2625 | ||
2603 | bool ath9k_hw_keysetmac(struct ath_hw *ah, u16 entry, const u8 *mac) | 2626 | bool ath9k_hw_keysetmac(struct ath_hw *ah, u16 entry, const u8 *mac) |
2604 | { | 2627 | { |
@@ -2627,6 +2650,7 @@ bool ath9k_hw_keysetmac(struct ath_hw *ah, u16 entry, const u8 *mac) | |||
2627 | 2650 | ||
2628 | return true; | 2651 | return true; |
2629 | } | 2652 | } |
2653 | EXPORT_SYMBOL(ath9k_hw_keysetmac); | ||
2630 | 2654 | ||
2631 | bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | 2655 | bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, |
2632 | const struct ath9k_keyval *k, | 2656 | const struct ath9k_keyval *k, |
@@ -2825,6 +2849,7 @@ bool ath9k_hw_set_keycache_entry(struct ath_hw *ah, u16 entry, | |||
2825 | 2849 | ||
2826 | return true; | 2850 | return true; |
2827 | } | 2851 | } |
2852 | EXPORT_SYMBOL(ath9k_hw_set_keycache_entry); | ||
2828 | 2853 | ||
2829 | bool ath9k_hw_keyisvalid(struct ath_hw *ah, u16 entry) | 2854 | bool ath9k_hw_keyisvalid(struct ath_hw *ah, u16 entry) |
2830 | { | 2855 | { |
@@ -2835,6 +2860,7 @@ bool ath9k_hw_keyisvalid(struct ath_hw *ah, u16 entry) | |||
2835 | } | 2860 | } |
2836 | return false; | 2861 | return false; |
2837 | } | 2862 | } |
2863 | EXPORT_SYMBOL(ath9k_hw_keyisvalid); | ||
2838 | 2864 | ||
2839 | /******************************/ | 2865 | /******************************/ |
2840 | /* Power Management (Chipset) */ | 2866 | /* Power Management (Chipset) */ |
@@ -2951,6 +2977,7 @@ bool ath9k_hw_setpower(struct ath_hw *ah, enum ath9k_power_mode mode) | |||
2951 | 2977 | ||
2952 | return status; | 2978 | return status; |
2953 | } | 2979 | } |
2980 | EXPORT_SYMBOL(ath9k_hw_setpower); | ||
2954 | 2981 | ||
2955 | /* | 2982 | /* |
2956 | * Helper for ASPM support. | 2983 | * Helper for ASPM support. |
@@ -3083,6 +3110,7 @@ void ath9k_hw_configpcipowersave(struct ath_hw *ah, int restore, int power_off) | |||
3083 | } | 3110 | } |
3084 | } | 3111 | } |
3085 | } | 3112 | } |
3113 | EXPORT_SYMBOL(ath9k_hw_configpcipowersave); | ||
3086 | 3114 | ||
3087 | /**********************/ | 3115 | /**********************/ |
3088 | /* Interrupt Handling */ | 3116 | /* Interrupt Handling */ |
@@ -3106,6 +3134,7 @@ bool ath9k_hw_intrpend(struct ath_hw *ah) | |||
3106 | 3134 | ||
3107 | return false; | 3135 | return false; |
3108 | } | 3136 | } |
3137 | EXPORT_SYMBOL(ath9k_hw_intrpend); | ||
3109 | 3138 | ||
3110 | bool ath9k_hw_getisr(struct ath_hw *ah, enum ath9k_int *masked) | 3139 | bool ath9k_hw_getisr(struct ath_hw *ah, enum ath9k_int *masked) |
3111 | { | 3140 | { |
@@ -3258,6 +3287,7 @@ bool ath9k_hw_getisr(struct ath_hw *ah, enum ath9k_int *masked) | |||
3258 | 3287 | ||
3259 | return true; | 3288 | return true; |
3260 | } | 3289 | } |
3290 | EXPORT_SYMBOL(ath9k_hw_getisr); | ||
3261 | 3291 | ||
3262 | enum ath9k_int ath9k_hw_set_interrupts(struct ath_hw *ah, enum ath9k_int ints) | 3292 | enum ath9k_int ath9k_hw_set_interrupts(struct ath_hw *ah, enum ath9k_int ints) |
3263 | { | 3293 | { |
@@ -3365,6 +3395,7 @@ enum ath9k_int ath9k_hw_set_interrupts(struct ath_hw *ah, enum ath9k_int ints) | |||
3365 | 3395 | ||
3366 | return omask; | 3396 | return omask; |
3367 | } | 3397 | } |
3398 | EXPORT_SYMBOL(ath9k_hw_set_interrupts); | ||
3368 | 3399 | ||
3369 | /*******************/ | 3400 | /*******************/ |
3370 | /* Beacon Handling */ | 3401 | /* Beacon Handling */ |
@@ -3426,6 +3457,7 @@ void ath9k_hw_beaconinit(struct ath_hw *ah, u32 next_beacon, u32 beacon_period) | |||
3426 | 3457 | ||
3427 | REG_SET_BIT(ah, AR_TIMER_MODE, flags); | 3458 | REG_SET_BIT(ah, AR_TIMER_MODE, flags); |
3428 | } | 3459 | } |
3460 | EXPORT_SYMBOL(ath9k_hw_beaconinit); | ||
3429 | 3461 | ||
3430 | void ath9k_hw_set_sta_beacon_timers(struct ath_hw *ah, | 3462 | void ath9k_hw_set_sta_beacon_timers(struct ath_hw *ah, |
3431 | const struct ath9k_beacon_state *bs) | 3463 | const struct ath9k_beacon_state *bs) |
@@ -3489,6 +3521,7 @@ void ath9k_hw_set_sta_beacon_timers(struct ath_hw *ah, | |||
3489 | /* TSF Out of Range Threshold */ | 3521 | /* TSF Out of Range Threshold */ |
3490 | REG_WRITE(ah, AR_TSFOOR_THRESHOLD, bs->bs_tsfoor_threshold); | 3522 | REG_WRITE(ah, AR_TSFOOR_THRESHOLD, bs->bs_tsfoor_threshold); |
3491 | } | 3523 | } |
3524 | EXPORT_SYMBOL(ath9k_hw_set_sta_beacon_timers); | ||
3492 | 3525 | ||
3493 | /*******************/ | 3526 | /*******************/ |
3494 | /* HW Capabilities */ | 3527 | /* HW Capabilities */ |
@@ -3756,6 +3789,7 @@ bool ath9k_hw_getcapability(struct ath_hw *ah, enum ath9k_capability_type type, | |||
3756 | return false; | 3789 | return false; |
3757 | } | 3790 | } |
3758 | } | 3791 | } |
3792 | EXPORT_SYMBOL(ath9k_hw_getcapability); | ||
3759 | 3793 | ||
3760 | bool ath9k_hw_setcapability(struct ath_hw *ah, enum ath9k_capability_type type, | 3794 | bool ath9k_hw_setcapability(struct ath_hw *ah, enum ath9k_capability_type type, |
3761 | u32 capability, u32 setting, int *status) | 3795 | u32 capability, u32 setting, int *status) |
@@ -3789,6 +3823,7 @@ bool ath9k_hw_setcapability(struct ath_hw *ah, enum ath9k_capability_type type, | |||
3789 | return false; | 3823 | return false; |
3790 | } | 3824 | } |
3791 | } | 3825 | } |
3826 | EXPORT_SYMBOL(ath9k_hw_setcapability); | ||
3792 | 3827 | ||
3793 | /****************************/ | 3828 | /****************************/ |
3794 | /* GPIO / RFKILL / Antennae */ | 3829 | /* GPIO / RFKILL / Antennae */ |
@@ -3835,6 +3870,7 @@ void ath9k_hw_cfg_gpio_input(struct ath_hw *ah, u32 gpio) | |||
3835 | (AR_GPIO_OE_OUT_DRV_NO << gpio_shift), | 3870 | (AR_GPIO_OE_OUT_DRV_NO << gpio_shift), |
3836 | (AR_GPIO_OE_OUT_DRV << gpio_shift)); | 3871 | (AR_GPIO_OE_OUT_DRV << gpio_shift)); |
3837 | } | 3872 | } |
3873 | EXPORT_SYMBOL(ath9k_hw_cfg_gpio_input); | ||
3838 | 3874 | ||
3839 | u32 ath9k_hw_gpio_get(struct ath_hw *ah, u32 gpio) | 3875 | u32 ath9k_hw_gpio_get(struct ath_hw *ah, u32 gpio) |
3840 | { | 3876 | { |
@@ -3853,6 +3889,7 @@ u32 ath9k_hw_gpio_get(struct ath_hw *ah, u32 gpio) | |||
3853 | else | 3889 | else |
3854 | return MS_REG_READ(AR, gpio) != 0; | 3890 | return MS_REG_READ(AR, gpio) != 0; |
3855 | } | 3891 | } |
3892 | EXPORT_SYMBOL(ath9k_hw_gpio_get); | ||
3856 | 3893 | ||
3857 | void ath9k_hw_cfg_output(struct ath_hw *ah, u32 gpio, | 3894 | void ath9k_hw_cfg_output(struct ath_hw *ah, u32 gpio, |
3858 | u32 ah_signal_type) | 3895 | u32 ah_signal_type) |
@@ -3868,22 +3905,26 @@ void ath9k_hw_cfg_output(struct ath_hw *ah, u32 gpio, | |||
3868 | (AR_GPIO_OE_OUT_DRV_ALL << gpio_shift), | 3905 | (AR_GPIO_OE_OUT_DRV_ALL << gpio_shift), |
3869 | (AR_GPIO_OE_OUT_DRV << gpio_shift)); | 3906 | (AR_GPIO_OE_OUT_DRV << gpio_shift)); |
3870 | } | 3907 | } |
3908 | EXPORT_SYMBOL(ath9k_hw_cfg_output); | ||
3871 | 3909 | ||
3872 | void ath9k_hw_set_gpio(struct ath_hw *ah, u32 gpio, u32 val) | 3910 | void ath9k_hw_set_gpio(struct ath_hw *ah, u32 gpio, u32 val) |
3873 | { | 3911 | { |
3874 | REG_RMW(ah, AR_GPIO_IN_OUT, ((val & 1) << gpio), | 3912 | REG_RMW(ah, AR_GPIO_IN_OUT, ((val & 1) << gpio), |
3875 | AR_GPIO_BIT(gpio)); | 3913 | AR_GPIO_BIT(gpio)); |
3876 | } | 3914 | } |
3915 | EXPORT_SYMBOL(ath9k_hw_set_gpio); | ||
3877 | 3916 | ||
3878 | u32 ath9k_hw_getdefantenna(struct ath_hw *ah) | 3917 | u32 ath9k_hw_getdefantenna(struct ath_hw *ah) |
3879 | { | 3918 | { |
3880 | return REG_READ(ah, AR_DEF_ANTENNA) & 0x7; | 3919 | return REG_READ(ah, AR_DEF_ANTENNA) & 0x7; |
3881 | } | 3920 | } |
3921 | EXPORT_SYMBOL(ath9k_hw_getdefantenna); | ||
3882 | 3922 | ||
3883 | void ath9k_hw_setantenna(struct ath_hw *ah, u32 antenna) | 3923 | void ath9k_hw_setantenna(struct ath_hw *ah, u32 antenna) |
3884 | { | 3924 | { |
3885 | REG_WRITE(ah, AR_DEF_ANTENNA, (antenna & 0x7)); | 3925 | REG_WRITE(ah, AR_DEF_ANTENNA, (antenna & 0x7)); |
3886 | } | 3926 | } |
3927 | EXPORT_SYMBOL(ath9k_hw_setantenna); | ||
3887 | 3928 | ||
3888 | bool ath9k_hw_setantennaswitch(struct ath_hw *ah, | 3929 | bool ath9k_hw_setantennaswitch(struct ath_hw *ah, |
3889 | enum ath9k_ant_setting settings, | 3930 | enum ath9k_ant_setting settings, |
@@ -3946,6 +3987,7 @@ u32 ath9k_hw_getrxfilter(struct ath_hw *ah) | |||
3946 | 3987 | ||
3947 | return bits; | 3988 | return bits; |
3948 | } | 3989 | } |
3990 | EXPORT_SYMBOL(ath9k_hw_getrxfilter); | ||
3949 | 3991 | ||
3950 | void ath9k_hw_setrxfilter(struct ath_hw *ah, u32 bits) | 3992 | void ath9k_hw_setrxfilter(struct ath_hw *ah, u32 bits) |
3951 | { | 3993 | { |
@@ -3967,6 +4009,7 @@ void ath9k_hw_setrxfilter(struct ath_hw *ah, u32 bits) | |||
3967 | REG_WRITE(ah, AR_RXCFG, | 4009 | REG_WRITE(ah, AR_RXCFG, |
3968 | REG_READ(ah, AR_RXCFG) & ~AR_RXCFG_ZLFDMA); | 4010 | REG_READ(ah, AR_RXCFG) & ~AR_RXCFG_ZLFDMA); |
3969 | } | 4011 | } |
4012 | EXPORT_SYMBOL(ath9k_hw_setrxfilter); | ||
3970 | 4013 | ||
3971 | bool ath9k_hw_phy_disable(struct ath_hw *ah) | 4014 | bool ath9k_hw_phy_disable(struct ath_hw *ah) |
3972 | { | 4015 | { |
@@ -3976,6 +4019,7 @@ bool ath9k_hw_phy_disable(struct ath_hw *ah) | |||
3976 | ath9k_hw_init_pll(ah, NULL); | 4019 | ath9k_hw_init_pll(ah, NULL); |
3977 | return true; | 4020 | return true; |
3978 | } | 4021 | } |
4022 | EXPORT_SYMBOL(ath9k_hw_phy_disable); | ||
3979 | 4023 | ||
3980 | bool ath9k_hw_disable(struct ath_hw *ah) | 4024 | bool ath9k_hw_disable(struct ath_hw *ah) |
3981 | { | 4025 | { |
@@ -3988,6 +4032,7 @@ bool ath9k_hw_disable(struct ath_hw *ah) | |||
3988 | ath9k_hw_init_pll(ah, NULL); | 4032 | ath9k_hw_init_pll(ah, NULL); |
3989 | return true; | 4033 | return true; |
3990 | } | 4034 | } |
4035 | EXPORT_SYMBOL(ath9k_hw_disable); | ||
3991 | 4036 | ||
3992 | void ath9k_hw_set_txpowerlimit(struct ath_hw *ah, u32 limit) | 4037 | void ath9k_hw_set_txpowerlimit(struct ath_hw *ah, u32 limit) |
3993 | { | 4038 | { |
@@ -4004,22 +4049,26 @@ void ath9k_hw_set_txpowerlimit(struct ath_hw *ah, u32 limit) | |||
4004 | min((u32) MAX_RATE_POWER, | 4049 | min((u32) MAX_RATE_POWER, |
4005 | (u32) regulatory->power_limit)); | 4050 | (u32) regulatory->power_limit)); |
4006 | } | 4051 | } |
4052 | EXPORT_SYMBOL(ath9k_hw_set_txpowerlimit); | ||
4007 | 4053 | ||
4008 | void ath9k_hw_setmac(struct ath_hw *ah, const u8 *mac) | 4054 | void ath9k_hw_setmac(struct ath_hw *ah, const u8 *mac) |
4009 | { | 4055 | { |
4010 | memcpy(ath9k_hw_common(ah)->macaddr, mac, ETH_ALEN); | 4056 | memcpy(ath9k_hw_common(ah)->macaddr, mac, ETH_ALEN); |
4011 | } | 4057 | } |
4058 | EXPORT_SYMBOL(ath9k_hw_setmac); | ||
4012 | 4059 | ||
4013 | void ath9k_hw_setopmode(struct ath_hw *ah) | 4060 | void ath9k_hw_setopmode(struct ath_hw *ah) |
4014 | { | 4061 | { |
4015 | ath9k_hw_set_operating_mode(ah, ah->opmode); | 4062 | ath9k_hw_set_operating_mode(ah, ah->opmode); |
4016 | } | 4063 | } |
4064 | EXPORT_SYMBOL(ath9k_hw_setopmode); | ||
4017 | 4065 | ||
4018 | void ath9k_hw_setmcastfilter(struct ath_hw *ah, u32 filter0, u32 filter1) | 4066 | void ath9k_hw_setmcastfilter(struct ath_hw *ah, u32 filter0, u32 filter1) |
4019 | { | 4067 | { |
4020 | REG_WRITE(ah, AR_MCAST_FIL0, filter0); | 4068 | REG_WRITE(ah, AR_MCAST_FIL0, filter0); |
4021 | REG_WRITE(ah, AR_MCAST_FIL1, filter1); | 4069 | REG_WRITE(ah, AR_MCAST_FIL1, filter1); |
4022 | } | 4070 | } |
4071 | EXPORT_SYMBOL(ath9k_hw_setmcastfilter); | ||
4023 | 4072 | ||
4024 | void ath9k_hw_write_associd(struct ath_hw *ah) | 4073 | void ath9k_hw_write_associd(struct ath_hw *ah) |
4025 | { | 4074 | { |
@@ -4029,6 +4078,7 @@ void ath9k_hw_write_associd(struct ath_hw *ah) | |||
4029 | REG_WRITE(ah, AR_BSS_ID1, get_unaligned_le16(common->curbssid + 4) | | 4078 | REG_WRITE(ah, AR_BSS_ID1, get_unaligned_le16(common->curbssid + 4) | |
4030 | ((common->curaid & 0x3fff) << AR_BSS_ID1_AID_S)); | 4079 | ((common->curaid & 0x3fff) << AR_BSS_ID1_AID_S)); |
4031 | } | 4080 | } |
4081 | EXPORT_SYMBOL(ath9k_hw_write_associd); | ||
4032 | 4082 | ||
4033 | u64 ath9k_hw_gettsf64(struct ath_hw *ah) | 4083 | u64 ath9k_hw_gettsf64(struct ath_hw *ah) |
4034 | { | 4084 | { |
@@ -4039,12 +4089,14 @@ u64 ath9k_hw_gettsf64(struct ath_hw *ah) | |||
4039 | 4089 | ||
4040 | return tsf; | 4090 | return tsf; |
4041 | } | 4091 | } |
4092 | EXPORT_SYMBOL(ath9k_hw_gettsf64); | ||
4042 | 4093 | ||
4043 | void ath9k_hw_settsf64(struct ath_hw *ah, u64 tsf64) | 4094 | void ath9k_hw_settsf64(struct ath_hw *ah, u64 tsf64) |
4044 | { | 4095 | { |
4045 | REG_WRITE(ah, AR_TSF_L32, tsf64 & 0xffffffff); | 4096 | REG_WRITE(ah, AR_TSF_L32, tsf64 & 0xffffffff); |
4046 | REG_WRITE(ah, AR_TSF_U32, (tsf64 >> 32) & 0xffffffff); | 4097 | REG_WRITE(ah, AR_TSF_U32, (tsf64 >> 32) & 0xffffffff); |
4047 | } | 4098 | } |
4099 | EXPORT_SYMBOL(ath9k_hw_settsf64); | ||
4048 | 4100 | ||
4049 | void ath9k_hw_reset_tsf(struct ath_hw *ah) | 4101 | void ath9k_hw_reset_tsf(struct ath_hw *ah) |
4050 | { | 4102 | { |
@@ -4055,6 +4107,7 @@ void ath9k_hw_reset_tsf(struct ath_hw *ah) | |||
4055 | 4107 | ||
4056 | REG_WRITE(ah, AR_RESET_TSF, AR_RESET_TSF_ONCE); | 4108 | REG_WRITE(ah, AR_RESET_TSF, AR_RESET_TSF_ONCE); |
4057 | } | 4109 | } |
4110 | EXPORT_SYMBOL(ath9k_hw_reset_tsf); | ||
4058 | 4111 | ||
4059 | void ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting) | 4112 | void ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting) |
4060 | { | 4113 | { |
@@ -4063,6 +4116,7 @@ void ath9k_hw_set_tsfadjust(struct ath_hw *ah, u32 setting) | |||
4063 | else | 4116 | else |
4064 | ah->misc_mode &= ~AR_PCU_TX_ADD_TSF; | 4117 | ah->misc_mode &= ~AR_PCU_TX_ADD_TSF; |
4065 | } | 4118 | } |
4119 | EXPORT_SYMBOL(ath9k_hw_set_tsfadjust); | ||
4066 | 4120 | ||
4067 | bool ath9k_hw_setslottime(struct ath_hw *ah, u32 us) | 4121 | bool ath9k_hw_setslottime(struct ath_hw *ah, u32 us) |
4068 | { | 4122 | { |
@@ -4077,6 +4131,7 @@ bool ath9k_hw_setslottime(struct ath_hw *ah, u32 us) | |||
4077 | return true; | 4131 | return true; |
4078 | } | 4132 | } |
4079 | } | 4133 | } |
4134 | EXPORT_SYMBOL(ath9k_hw_setslottime); | ||
4080 | 4135 | ||
4081 | void ath9k_hw_set11nmac2040(struct ath_hw *ah) | 4136 | void ath9k_hw_set11nmac2040(struct ath_hw *ah) |
4082 | { | 4137 | { |
@@ -4140,6 +4195,7 @@ u32 ath9k_hw_gettsf32(struct ath_hw *ah) | |||
4140 | { | 4195 | { |
4141 | return REG_READ(ah, AR_TSF_L32); | 4196 | return REG_READ(ah, AR_TSF_L32); |
4142 | } | 4197 | } |
4198 | EXPORT_SYMBOL(ath9k_hw_gettsf32); | ||
4143 | 4199 | ||
4144 | struct ath_gen_timer *ath_gen_timer_alloc(struct ath_hw *ah, | 4200 | struct ath_gen_timer *ath_gen_timer_alloc(struct ath_hw *ah, |
4145 | void (*trigger)(void *), | 4201 | void (*trigger)(void *), |
@@ -4168,6 +4224,7 @@ struct ath_gen_timer *ath_gen_timer_alloc(struct ath_hw *ah, | |||
4168 | 4224 | ||
4169 | return timer; | 4225 | return timer; |
4170 | } | 4226 | } |
4227 | EXPORT_SYMBOL(ath_gen_timer_alloc); | ||
4171 | 4228 | ||
4172 | void ath9k_hw_gen_timer_start(struct ath_hw *ah, | 4229 | void ath9k_hw_gen_timer_start(struct ath_hw *ah, |
4173 | struct ath_gen_timer *timer, | 4230 | struct ath_gen_timer *timer, |
@@ -4209,6 +4266,7 @@ void ath9k_hw_gen_timer_start(struct ath_hw *ah, | |||
4209 | (SM(AR_GENTMR_BIT(timer->index), AR_IMR_S5_GENTIMER_THRESH) | | 4266 | (SM(AR_GENTMR_BIT(timer->index), AR_IMR_S5_GENTIMER_THRESH) | |
4210 | SM(AR_GENTMR_BIT(timer->index), AR_IMR_S5_GENTIMER_TRIG))); | 4267 | SM(AR_GENTMR_BIT(timer->index), AR_IMR_S5_GENTIMER_TRIG))); |
4211 | } | 4268 | } |
4269 | EXPORT_SYMBOL(ath9k_hw_gen_timer_start); | ||
4212 | 4270 | ||
4213 | void ath9k_hw_gen_timer_stop(struct ath_hw *ah, struct ath_gen_timer *timer) | 4271 | void ath9k_hw_gen_timer_stop(struct ath_hw *ah, struct ath_gen_timer *timer) |
4214 | { | 4272 | { |
@@ -4230,6 +4288,7 @@ void ath9k_hw_gen_timer_stop(struct ath_hw *ah, struct ath_gen_timer *timer) | |||
4230 | 4288 | ||
4231 | clear_bit(timer->index, &timer_table->timer_mask.timer_bits); | 4289 | clear_bit(timer->index, &timer_table->timer_mask.timer_bits); |
4232 | } | 4290 | } |
4291 | EXPORT_SYMBOL(ath9k_hw_gen_timer_stop); | ||
4233 | 4292 | ||
4234 | void ath_gen_timer_free(struct ath_hw *ah, struct ath_gen_timer *timer) | 4293 | void ath_gen_timer_free(struct ath_hw *ah, struct ath_gen_timer *timer) |
4235 | { | 4294 | { |
@@ -4239,6 +4298,7 @@ void ath_gen_timer_free(struct ath_hw *ah, struct ath_gen_timer *timer) | |||
4239 | timer_table->timers[timer->index] = NULL; | 4298 | timer_table->timers[timer->index] = NULL; |
4240 | kfree(timer); | 4299 | kfree(timer); |
4241 | } | 4300 | } |
4301 | EXPORT_SYMBOL(ath_gen_timer_free); | ||
4242 | 4302 | ||
4243 | /* | 4303 | /* |
4244 | * Generic Timer Interrupts handling | 4304 | * Generic Timer Interrupts handling |
@@ -4276,3 +4336,4 @@ void ath_gen_timer_isr(struct ath_hw *ah) | |||
4276 | timer->trigger(timer->arg); | 4336 | timer->trigger(timer->arg); |
4277 | } | 4337 | } |
4278 | } | 4338 | } |
4339 | EXPORT_SYMBOL(ath_gen_timer_isr); | ||
diff --git a/drivers/net/wireless/ath/ath9k/mac.c b/drivers/net/wireless/ath/ath9k/mac.c index 3be658d42a53..e2c1ba3ea483 100644 --- a/drivers/net/wireless/ath/ath9k/mac.c +++ b/drivers/net/wireless/ath/ath9k/mac.c | |||
@@ -39,11 +39,13 @@ u32 ath9k_hw_gettxbuf(struct ath_hw *ah, u32 q) | |||
39 | { | 39 | { |
40 | return REG_READ(ah, AR_QTXDP(q)); | 40 | return REG_READ(ah, AR_QTXDP(q)); |
41 | } | 41 | } |
42 | EXPORT_SYMBOL(ath9k_hw_gettxbuf); | ||
42 | 43 | ||
43 | void ath9k_hw_puttxbuf(struct ath_hw *ah, u32 q, u32 txdp) | 44 | void ath9k_hw_puttxbuf(struct ath_hw *ah, u32 q, u32 txdp) |
44 | { | 45 | { |
45 | REG_WRITE(ah, AR_QTXDP(q), txdp); | 46 | REG_WRITE(ah, AR_QTXDP(q), txdp); |
46 | } | 47 | } |
48 | EXPORT_SYMBOL(ath9k_hw_puttxbuf); | ||
47 | 49 | ||
48 | void ath9k_hw_txstart(struct ath_hw *ah, u32 q) | 50 | void ath9k_hw_txstart(struct ath_hw *ah, u32 q) |
49 | { | 51 | { |
@@ -51,6 +53,7 @@ void ath9k_hw_txstart(struct ath_hw *ah, u32 q) | |||
51 | "Enable TXE on queue: %u\n", q); | 53 | "Enable TXE on queue: %u\n", q); |
52 | REG_WRITE(ah, AR_Q_TXE, 1 << q); | 54 | REG_WRITE(ah, AR_Q_TXE, 1 << q); |
53 | } | 55 | } |
56 | EXPORT_SYMBOL(ath9k_hw_txstart); | ||
54 | 57 | ||
55 | u32 ath9k_hw_numtxpending(struct ath_hw *ah, u32 q) | 58 | u32 ath9k_hw_numtxpending(struct ath_hw *ah, u32 q) |
56 | { | 59 | { |
@@ -65,6 +68,7 @@ u32 ath9k_hw_numtxpending(struct ath_hw *ah, u32 q) | |||
65 | 68 | ||
66 | return npend; | 69 | return npend; |
67 | } | 70 | } |
71 | EXPORT_SYMBOL(ath9k_hw_numtxpending); | ||
68 | 72 | ||
69 | bool ath9k_hw_updatetxtriglevel(struct ath_hw *ah, bool bIncTrigLevel) | 73 | bool ath9k_hw_updatetxtriglevel(struct ath_hw *ah, bool bIncTrigLevel) |
70 | { | 74 | { |
@@ -94,6 +98,7 @@ bool ath9k_hw_updatetxtriglevel(struct ath_hw *ah, bool bIncTrigLevel) | |||
94 | 98 | ||
95 | return newLevel != curLevel; | 99 | return newLevel != curLevel; |
96 | } | 100 | } |
101 | EXPORT_SYMBOL(ath9k_hw_updatetxtriglevel); | ||
97 | 102 | ||
98 | bool ath9k_hw_stoptxdma(struct ath_hw *ah, u32 q) | 103 | bool ath9k_hw_stoptxdma(struct ath_hw *ah, u32 q) |
99 | { | 104 | { |
@@ -173,6 +178,7 @@ bool ath9k_hw_stoptxdma(struct ath_hw *ah, u32 q) | |||
173 | #undef ATH9K_TX_STOP_DMA_TIMEOUT | 178 | #undef ATH9K_TX_STOP_DMA_TIMEOUT |
174 | #undef ATH9K_TIME_QUANTUM | 179 | #undef ATH9K_TIME_QUANTUM |
175 | } | 180 | } |
181 | EXPORT_SYMBOL(ath9k_hw_stoptxdma); | ||
176 | 182 | ||
177 | void ath9k_hw_filltxdesc(struct ath_hw *ah, struct ath_desc *ds, | 183 | void ath9k_hw_filltxdesc(struct ath_hw *ah, struct ath_desc *ds, |
178 | u32 segLen, bool firstSeg, | 184 | u32 segLen, bool firstSeg, |
@@ -199,6 +205,7 @@ void ath9k_hw_filltxdesc(struct ath_hw *ah, struct ath_desc *ds, | |||
199 | ads->ds_txstatus6 = ads->ds_txstatus7 = 0; | 205 | ads->ds_txstatus6 = ads->ds_txstatus7 = 0; |
200 | ads->ds_txstatus8 = ads->ds_txstatus9 = 0; | 206 | ads->ds_txstatus8 = ads->ds_txstatus9 = 0; |
201 | } | 207 | } |
208 | EXPORT_SYMBOL(ath9k_hw_filltxdesc); | ||
202 | 209 | ||
203 | void ath9k_hw_cleartxdesc(struct ath_hw *ah, struct ath_desc *ds) | 210 | void ath9k_hw_cleartxdesc(struct ath_hw *ah, struct ath_desc *ds) |
204 | { | 211 | { |
@@ -210,6 +217,7 @@ void ath9k_hw_cleartxdesc(struct ath_hw *ah, struct ath_desc *ds) | |||
210 | ads->ds_txstatus6 = ads->ds_txstatus7 = 0; | 217 | ads->ds_txstatus6 = ads->ds_txstatus7 = 0; |
211 | ads->ds_txstatus8 = ads->ds_txstatus9 = 0; | 218 | ads->ds_txstatus8 = ads->ds_txstatus9 = 0; |
212 | } | 219 | } |
220 | EXPORT_SYMBOL(ath9k_hw_cleartxdesc); | ||
213 | 221 | ||
214 | int ath9k_hw_txprocdesc(struct ath_hw *ah, struct ath_desc *ds) | 222 | int ath9k_hw_txprocdesc(struct ath_hw *ah, struct ath_desc *ds) |
215 | { | 223 | { |
@@ -285,6 +293,7 @@ int ath9k_hw_txprocdesc(struct ath_hw *ah, struct ath_desc *ds) | |||
285 | 293 | ||
286 | return 0; | 294 | return 0; |
287 | } | 295 | } |
296 | EXPORT_SYMBOL(ath9k_hw_txprocdesc); | ||
288 | 297 | ||
289 | void ath9k_hw_set11n_txdesc(struct ath_hw *ah, struct ath_desc *ds, | 298 | void ath9k_hw_set11n_txdesc(struct ath_hw *ah, struct ath_desc *ds, |
290 | u32 pktLen, enum ath9k_pkt_type type, u32 txPower, | 299 | u32 pktLen, enum ath9k_pkt_type type, u32 txPower, |
@@ -320,6 +329,7 @@ void ath9k_hw_set11n_txdesc(struct ath_hw *ah, struct ath_desc *ds, | |||
320 | ads->ds_ctl11 = 0; | 329 | ads->ds_ctl11 = 0; |
321 | } | 330 | } |
322 | } | 331 | } |
332 | EXPORT_SYMBOL(ath9k_hw_set11n_txdesc); | ||
323 | 333 | ||
324 | void ath9k_hw_set11n_ratescenario(struct ath_hw *ah, struct ath_desc *ds, | 334 | void ath9k_hw_set11n_ratescenario(struct ath_hw *ah, struct ath_desc *ds, |
325 | struct ath_desc *lastds, | 335 | struct ath_desc *lastds, |
@@ -375,6 +385,7 @@ void ath9k_hw_set11n_ratescenario(struct ath_hw *ah, struct ath_desc *ds, | |||
375 | last_ads->ds_ctl2 = ads->ds_ctl2; | 385 | last_ads->ds_ctl2 = ads->ds_ctl2; |
376 | last_ads->ds_ctl3 = ads->ds_ctl3; | 386 | last_ads->ds_ctl3 = ads->ds_ctl3; |
377 | } | 387 | } |
388 | EXPORT_SYMBOL(ath9k_hw_set11n_ratescenario); | ||
378 | 389 | ||
379 | void ath9k_hw_set11n_aggr_first(struct ath_hw *ah, struct ath_desc *ds, | 390 | void ath9k_hw_set11n_aggr_first(struct ath_hw *ah, struct ath_desc *ds, |
380 | u32 aggrLen) | 391 | u32 aggrLen) |
@@ -385,6 +396,7 @@ void ath9k_hw_set11n_aggr_first(struct ath_hw *ah, struct ath_desc *ds, | |||
385 | ads->ds_ctl6 &= ~AR_AggrLen; | 396 | ads->ds_ctl6 &= ~AR_AggrLen; |
386 | ads->ds_ctl6 |= SM(aggrLen, AR_AggrLen); | 397 | ads->ds_ctl6 |= SM(aggrLen, AR_AggrLen); |
387 | } | 398 | } |
399 | EXPORT_SYMBOL(ath9k_hw_set11n_aggr_first); | ||
388 | 400 | ||
389 | void ath9k_hw_set11n_aggr_middle(struct ath_hw *ah, struct ath_desc *ds, | 401 | void ath9k_hw_set11n_aggr_middle(struct ath_hw *ah, struct ath_desc *ds, |
390 | u32 numDelims) | 402 | u32 numDelims) |
@@ -399,6 +411,7 @@ void ath9k_hw_set11n_aggr_middle(struct ath_hw *ah, struct ath_desc *ds, | |||
399 | ctl6 |= SM(numDelims, AR_PadDelim); | 411 | ctl6 |= SM(numDelims, AR_PadDelim); |
400 | ads->ds_ctl6 = ctl6; | 412 | ads->ds_ctl6 = ctl6; |
401 | } | 413 | } |
414 | EXPORT_SYMBOL(ath9k_hw_set11n_aggr_middle); | ||
402 | 415 | ||
403 | void ath9k_hw_set11n_aggr_last(struct ath_hw *ah, struct ath_desc *ds) | 416 | void ath9k_hw_set11n_aggr_last(struct ath_hw *ah, struct ath_desc *ds) |
404 | { | 417 | { |
@@ -408,6 +421,7 @@ void ath9k_hw_set11n_aggr_last(struct ath_hw *ah, struct ath_desc *ds) | |||
408 | ads->ds_ctl1 &= ~AR_MoreAggr; | 421 | ads->ds_ctl1 &= ~AR_MoreAggr; |
409 | ads->ds_ctl6 &= ~AR_PadDelim; | 422 | ads->ds_ctl6 &= ~AR_PadDelim; |
410 | } | 423 | } |
424 | EXPORT_SYMBOL(ath9k_hw_set11n_aggr_last); | ||
411 | 425 | ||
412 | void ath9k_hw_clr11n_aggr(struct ath_hw *ah, struct ath_desc *ds) | 426 | void ath9k_hw_clr11n_aggr(struct ath_hw *ah, struct ath_desc *ds) |
413 | { | 427 | { |
@@ -415,6 +429,7 @@ void ath9k_hw_clr11n_aggr(struct ath_hw *ah, struct ath_desc *ds) | |||
415 | 429 | ||
416 | ads->ds_ctl1 &= (~AR_IsAggr & ~AR_MoreAggr); | 430 | ads->ds_ctl1 &= (~AR_IsAggr & ~AR_MoreAggr); |
417 | } | 431 | } |
432 | EXPORT_SYMBOL(ath9k_hw_clr11n_aggr); | ||
418 | 433 | ||
419 | void ath9k_hw_set11n_burstduration(struct ath_hw *ah, struct ath_desc *ds, | 434 | void ath9k_hw_set11n_burstduration(struct ath_hw *ah, struct ath_desc *ds, |
420 | u32 burstDuration) | 435 | u32 burstDuration) |
@@ -424,6 +439,7 @@ void ath9k_hw_set11n_burstduration(struct ath_hw *ah, struct ath_desc *ds, | |||
424 | ads->ds_ctl2 &= ~AR_BurstDur; | 439 | ads->ds_ctl2 &= ~AR_BurstDur; |
425 | ads->ds_ctl2 |= SM(burstDuration, AR_BurstDur); | 440 | ads->ds_ctl2 |= SM(burstDuration, AR_BurstDur); |
426 | } | 441 | } |
442 | EXPORT_SYMBOL(ath9k_hw_set11n_burstduration); | ||
427 | 443 | ||
428 | void ath9k_hw_set11n_virtualmorefrag(struct ath_hw *ah, struct ath_desc *ds, | 444 | void ath9k_hw_set11n_virtualmorefrag(struct ath_hw *ah, struct ath_desc *ds, |
429 | u32 vmf) | 445 | u32 vmf) |
@@ -441,6 +457,7 @@ void ath9k_hw_gettxintrtxqs(struct ath_hw *ah, u32 *txqs) | |||
441 | *txqs &= ah->intr_txqs; | 457 | *txqs &= ah->intr_txqs; |
442 | ah->intr_txqs &= ~(*txqs); | 458 | ah->intr_txqs &= ~(*txqs); |
443 | } | 459 | } |
460 | EXPORT_SYMBOL(ath9k_hw_gettxintrtxqs); | ||
444 | 461 | ||
445 | bool ath9k_hw_set_txq_props(struct ath_hw *ah, int q, | 462 | bool ath9k_hw_set_txq_props(struct ath_hw *ah, int q, |
446 | const struct ath9k_tx_queue_info *qinfo) | 463 | const struct ath9k_tx_queue_info *qinfo) |
@@ -512,6 +529,7 @@ bool ath9k_hw_set_txq_props(struct ath_hw *ah, int q, | |||
512 | 529 | ||
513 | return true; | 530 | return true; |
514 | } | 531 | } |
532 | EXPORT_SYMBOL(ath9k_hw_set_txq_props); | ||
515 | 533 | ||
516 | bool ath9k_hw_get_txq_props(struct ath_hw *ah, int q, | 534 | bool ath9k_hw_get_txq_props(struct ath_hw *ah, int q, |
517 | struct ath9k_tx_queue_info *qinfo) | 535 | struct ath9k_tx_queue_info *qinfo) |
@@ -550,6 +568,7 @@ bool ath9k_hw_get_txq_props(struct ath_hw *ah, int q, | |||
550 | 568 | ||
551 | return true; | 569 | return true; |
552 | } | 570 | } |
571 | EXPORT_SYMBOL(ath9k_hw_get_txq_props); | ||
553 | 572 | ||
554 | int ath9k_hw_setuptxqueue(struct ath_hw *ah, enum ath9k_tx_queue type, | 573 | int ath9k_hw_setuptxqueue(struct ath_hw *ah, enum ath9k_tx_queue type, |
555 | const struct ath9k_tx_queue_info *qinfo) | 574 | const struct ath9k_tx_queue_info *qinfo) |
@@ -617,6 +636,7 @@ int ath9k_hw_setuptxqueue(struct ath_hw *ah, enum ath9k_tx_queue type, | |||
617 | 636 | ||
618 | return q; | 637 | return q; |
619 | } | 638 | } |
639 | EXPORT_SYMBOL(ath9k_hw_setuptxqueue); | ||
620 | 640 | ||
621 | bool ath9k_hw_releasetxqueue(struct ath_hw *ah, u32 q) | 641 | bool ath9k_hw_releasetxqueue(struct ath_hw *ah, u32 q) |
622 | { | 642 | { |
@@ -648,6 +668,7 @@ bool ath9k_hw_releasetxqueue(struct ath_hw *ah, u32 q) | |||
648 | 668 | ||
649 | return true; | 669 | return true; |
650 | } | 670 | } |
671 | EXPORT_SYMBOL(ath9k_hw_releasetxqueue); | ||
651 | 672 | ||
652 | bool ath9k_hw_resettxqueue(struct ath_hw *ah, u32 q) | 673 | bool ath9k_hw_resettxqueue(struct ath_hw *ah, u32 q) |
653 | { | 674 | { |
@@ -805,6 +826,7 @@ bool ath9k_hw_resettxqueue(struct ath_hw *ah, u32 q) | |||
805 | 826 | ||
806 | return true; | 827 | return true; |
807 | } | 828 | } |
829 | EXPORT_SYMBOL(ath9k_hw_resettxqueue); | ||
808 | 830 | ||
809 | int ath9k_hw_rxprocdesc(struct ath_hw *ah, struct ath_desc *ds, | 831 | int ath9k_hw_rxprocdesc(struct ath_hw *ah, struct ath_desc *ds, |
810 | u32 pa, struct ath_desc *nds, u64 tsf) | 832 | u32 pa, struct ath_desc *nds, u64 tsf) |
@@ -886,6 +908,7 @@ int ath9k_hw_rxprocdesc(struct ath_hw *ah, struct ath_desc *ds, | |||
886 | 908 | ||
887 | return 0; | 909 | return 0; |
888 | } | 910 | } |
911 | EXPORT_SYMBOL(ath9k_hw_rxprocdesc); | ||
889 | 912 | ||
890 | void ath9k_hw_setuprxdesc(struct ath_hw *ah, struct ath_desc *ds, | 913 | void ath9k_hw_setuprxdesc(struct ath_hw *ah, struct ath_desc *ds, |
891 | u32 size, u32 flags) | 914 | u32 size, u32 flags) |
@@ -901,6 +924,7 @@ void ath9k_hw_setuprxdesc(struct ath_hw *ah, struct ath_desc *ds, | |||
901 | if (!(pCap->hw_caps & ATH9K_HW_CAP_AUTOSLEEP)) | 924 | if (!(pCap->hw_caps & ATH9K_HW_CAP_AUTOSLEEP)) |
902 | memset(&(ads->u), 0, sizeof(ads->u)); | 925 | memset(&(ads->u), 0, sizeof(ads->u)); |
903 | } | 926 | } |
927 | EXPORT_SYMBOL(ath9k_hw_setuprxdesc); | ||
904 | 928 | ||
905 | bool ath9k_hw_setrxabort(struct ath_hw *ah, bool set) | 929 | bool ath9k_hw_setrxabort(struct ath_hw *ah, bool set) |
906 | { | 930 | { |
@@ -930,16 +954,19 @@ bool ath9k_hw_setrxabort(struct ath_hw *ah, bool set) | |||
930 | 954 | ||
931 | return true; | 955 | return true; |
932 | } | 956 | } |
957 | EXPORT_SYMBOL(ath9k_hw_setrxabort); | ||
933 | 958 | ||
934 | void ath9k_hw_putrxbuf(struct ath_hw *ah, u32 rxdp) | 959 | void ath9k_hw_putrxbuf(struct ath_hw *ah, u32 rxdp) |
935 | { | 960 | { |
936 | REG_WRITE(ah, AR_RXDP, rxdp); | 961 | REG_WRITE(ah, AR_RXDP, rxdp); |
937 | } | 962 | } |
963 | EXPORT_SYMBOL(ath9k_hw_putrxbuf); | ||
938 | 964 | ||
939 | void ath9k_hw_rxena(struct ath_hw *ah) | 965 | void ath9k_hw_rxena(struct ath_hw *ah) |
940 | { | 966 | { |
941 | REG_WRITE(ah, AR_CR, AR_CR_RXE); | 967 | REG_WRITE(ah, AR_CR, AR_CR_RXE); |
942 | } | 968 | } |
969 | EXPORT_SYMBOL(ath9k_hw_rxena); | ||
943 | 970 | ||
944 | void ath9k_hw_startpcureceive(struct ath_hw *ah) | 971 | void ath9k_hw_startpcureceive(struct ath_hw *ah) |
945 | { | 972 | { |
@@ -949,6 +976,7 @@ void ath9k_hw_startpcureceive(struct ath_hw *ah) | |||
949 | 976 | ||
950 | REG_CLR_BIT(ah, AR_DIAG_SW, (AR_DIAG_RX_DIS | AR_DIAG_RX_ABORT)); | 977 | REG_CLR_BIT(ah, AR_DIAG_SW, (AR_DIAG_RX_DIS | AR_DIAG_RX_ABORT)); |
951 | } | 978 | } |
979 | EXPORT_SYMBOL(ath9k_hw_startpcureceive); | ||
952 | 980 | ||
953 | void ath9k_hw_stoppcurecv(struct ath_hw *ah) | 981 | void ath9k_hw_stoppcurecv(struct ath_hw *ah) |
954 | { | 982 | { |
@@ -956,6 +984,7 @@ void ath9k_hw_stoppcurecv(struct ath_hw *ah) | |||
956 | 984 | ||
957 | ath9k_hw_disable_mib_counters(ah); | 985 | ath9k_hw_disable_mib_counters(ah); |
958 | } | 986 | } |
987 | EXPORT_SYMBOL(ath9k_hw_stoppcurecv); | ||
959 | 988 | ||
960 | bool ath9k_hw_stopdmarecv(struct ath_hw *ah) | 989 | bool ath9k_hw_stopdmarecv(struct ath_hw *ah) |
961 | { | 990 | { |
@@ -988,3 +1017,4 @@ bool ath9k_hw_stopdmarecv(struct ath_hw *ah) | |||
988 | #undef AH_RX_TIME_QUANTUM | 1017 | #undef AH_RX_TIME_QUANTUM |
989 | #undef AH_RX_STOP_DMA_TIMEOUT | 1018 | #undef AH_RX_STOP_DMA_TIMEOUT |
990 | } | 1019 | } |
1020 | EXPORT_SYMBOL(ath9k_hw_stopdmarecv); | ||