uboot-envtools: add env settings for Edgerouter-X
[openwrt/openwrt.git] / package / kernel / mac80211 / ath.mk
1 PKG_DRIVERS += \
2 ath ath5k ath6kl ath6kl-sdio ath6kl-usb ath9k ath9k-common ath9k-htc ath10k ath10k-smallbuffers \
3 carl9170 owl-loader ar5523 wil6210
4
5 PKG_CONFIG_DEPENDS += \
6 CONFIG_PACKAGE_ATH_DEBUG \
7 CONFIG_PACKAGE_ATH_DFS \
8 CONFIG_PACKAGE_ATH_SPECTRAL \
9 CONFIG_PACKAGE_ATH_DYNACK \
10 CONFIG_ATH9K_HWRNG \
11 CONFIG_ATH9K_SUPPORT_PCOEM \
12 CONFIG_ATH9K_TX99 \
13 CONFIG_ATH10K_LEDS \
14 CONFIG_ATH10K_THERMAL \
15 CONFIG_ATH_USER_REGD
16
17 ifdef CONFIG_PACKAGE_MAC80211_DEBUGFS
18 config-y += \
19 ATH9K_DEBUGFS \
20 ATH9K_HTC_DEBUGFS \
21 ATH10K_DEBUGFS \
22 CARL9170_DEBUGFS \
23 ATH5K_DEBUG \
24 ATH6KL_DEBUG \
25 WIL6210_DEBUGFS
26 endif
27
28 ifdef CONFIG_PACKAGE_MAC80211_TRACING
29 config-y += \
30 ATH10K_TRACING \
31 ATH6KL_TRACING \
32 ATH_TRACEPOINTS \
33 ATH5K_TRACER \
34 WIL6210_TRACING
35 endif
36
37 config-$(call config_package,ath) += ATH_CARDS ATH_COMMON
38 config-$(CONFIG_PACKAGE_ATH_DEBUG) += ATH_DEBUG ATH10K_DEBUG ATH9K_STATION_STATISTICS
39 config-$(CONFIG_PACKAGE_ATH_DFS) += ATH9K_DFS_CERTIFIED ATH10K_DFS_CERTIFIED
40 config-$(CONFIG_PACKAGE_ATH_SPECTRAL) += ATH9K_COMMON_SPECTRAL ATH10K_SPECTRAL
41 config-$(CONFIG_PACKAGE_ATH_DYNACK) += ATH9K_DYNACK
42 config-$(call config_package,ath9k) += ATH9K
43 config-$(call config_package,ath9k-common) += ATH9K_COMMON
44 config-$(call config_package,owl-loader) += ATH9K_PCI_NO_EEPROM
45 config-$(CONFIG_TARGET_ath79) += ATH9K_AHB
46 config-$(CONFIG_TARGET_ipq40xx) += ATH10K_AHB
47 config-$(CONFIG_PCI) += ATH9K_PCI
48 config-$(CONFIG_ATH_USER_REGD) += ATH_USER_REGD ATH_REG_DYNAMIC_USER_REG_HINTS
49 config-$(CONFIG_ATH9K_HWRNG) += ATH9K_HWRNG
50 config-$(CONFIG_ATH9K_SUPPORT_PCOEM) += ATH9K_PCOEM
51 config-$(CONFIG_ATH9K_TX99) += ATH9K_TX99
52 config-$(CONFIG_ATH9K_UBNTHSR) += ATH9K_UBNTHSR
53 config-$(CONFIG_ATH10K_LEDS) += ATH10K_LEDS
54 config-$(CONFIG_ATH10K_THERMAL) += ATH10K_THERMAL
55
56 config-$(call config_package,ath9k-htc) += ATH9K_HTC
57 config-$(call config_package,ath10k) += ATH10K ATH10K_PCI
58 config-$(call config_package,ath10k-smallbuffers) += ATH10K ATH10K_PCI ATH10K_SMALLBUFFERS
59
60 config-$(call config_package,ath5k) += ATH5K
61 ifdef CONFIG_TARGET_ath25
62 config-y += ATH5K_AHB
63 else
64 config-y += ATH5K_PCI
65 endif
66
67 config-$(call config_package,ath6kl) += ATH6KL
68 config-$(call config_package,ath6kl-sdio) += ATH6KL_SDIO
69 config-$(call config_package,ath6kl-usb) += ATH6KL_USB
70
71 config-$(call config_package,carl9170) += CARL9170
72 config-$(call config_package,ar5523) += AR5523
73
74 config-$(call config_package,wil6210) += WIL6210
75
76 define KernelPackage/ath/config
77 if PACKAGE_kmod-ath
78 config ATH_USER_REGD
79 bool "Force Atheros drivers to respect the user's regdomain settings"
80 default y
81 help
82 Atheros' idea of regulatory handling is that the EEPROM of the card defines
83 the regulatory limits and the user is only allowed to restrict the settings
84 even further, even if the country allows frequencies or power levels that
85 are forbidden by the EEPROM settings.
86
87 Select this option if you want the driver to respect the user's decision about
88 regulatory settings.
89
90 config PACKAGE_ATH_DEBUG
91 bool "Atheros wireless debugging"
92 help
93 Say Y, if you want to debug atheros wireless drivers.
94 Only ath9k & ath10k make use of this.
95
96 config PACKAGE_ATH_DFS
97 bool "Enable DFS support"
98 default y
99 help
100 Dynamic frequency selection (DFS) is required for most of the 5 GHz band
101 channels in Europe, US, and Japan.
102
103 Select this option if you want to use such channels.
104
105 config PACKAGE_ATH_SPECTRAL
106 bool "Atheros spectral scan support"
107 depends on PACKAGE_ATH_DEBUG
108 select KERNEL_RELAY
109 help
110 Say Y to enable access to the FFT/spectral data via debugfs.
111
112 config PACKAGE_ATH_DYNACK
113 bool "Enable Dynack support"
114 depends on PACKAGE_kmod-ath9k-common
115 help
116 Enables support for Dynamic ACK estimation, which allows the fastest possible speed
117 at any distance automatically by increasing/decreasing the max frame ACK time for
118 the most remote station detected. It can be enabled by using iw (iw phy0 set distance auto),
119 or by sending the NL80211_ATTR_WIPHY_DYN_ACK flag to mac80211 driver using netlink.
120
121 Select this option if you want to enable this feature
122
123 endif
124 endef
125
126 define KernelPackage/ath
127 $(call KernelPackage/mac80211/Default)
128 TITLE:=Atheros common driver part
129 DEPENDS+= @PCI_SUPPORT||USB_SUPPORT||TARGET_ath79||TARGET_ath25 +kmod-mac80211
130 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath.ko
131 MENU:=1
132 endef
133
134 define KernelPackage/ath/description
135 This module contains some common parts needed by Atheros Wireless drivers.
136 endef
137
138 define KernelPackage/ath5k
139 $(call KernelPackage/mac80211/Default)
140 TITLE:=Atheros 5xxx wireless cards support
141 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath5k
142 DEPENDS+= @(PCI_SUPPORT||TARGET_ath25) +kmod-ath
143 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath5k/ath5k.ko
144 AUTOLOAD:=$(call AutoProbe,ath5k)
145 endef
146
147 define KernelPackage/ath5k/description
148 This module adds support for wireless adapters based on
149 Atheros 5xxx chipset.
150 endef
151
152 define KernelPackage/ath6kl
153 $(call KernelPackage/mac80211/Default)
154 TITLE:=Atheros FullMAC wireless devices (common code for ath6kl_sdio and ath6kl_usb)
155 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath6kl
156 HIDDEN:=1
157 DEPENDS+= +kmod-ath +@DRIVER_11N_SUPPORT
158 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath6kl/ath6kl_core.ko
159 endef
160
161 define KernelPackage/ath6kl-sdio
162 $(call KernelPackage/mac80211/Default)
163 TITLE:=Atheros 802.11n SDIO wireless cards support
164 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath6kl
165 DEPENDS+= +kmod-mmc +kmod-ath6kl
166 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath6kl/ath6kl_sdio.ko
167 AUTOLOAD:=$(call AutoProbe,ath6kl_sdio)
168 endef
169
170 define KernelPackage/ath6kl-sdio/description
171 This module adds support for wireless adapters based on
172 Atheros IEEE 802.11n AR6003 and AR6004 family of chipsets.
173 endef
174
175 define KernelPackage/ath6kl-usb
176 $(call KernelPackage/mac80211/Default)
177 TITLE:=Atheros 802.11n USB wireless cards support
178 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath6kl
179 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-ath6kl
180 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath6kl/ath6kl_usb.ko
181 AUTOLOAD:=$(call AutoProbe,ath6kl_usb)
182 endef
183
184 define KernelPackage/ath6kl-usb/description
185 This module adds support for wireless adapters based on the
186 Atheros IEEE 802.11n AR6004 chipset.
187 endef
188
189 define KernelPackage/ath9k-common
190 $(call KernelPackage/mac80211/Default)
191 TITLE:=Atheros 802.11n wireless devices (common code for ath9k and ath9k_htc)
192 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath9k
193 HIDDEN:=1
194 DEPENDS+= @PCI_SUPPORT||USB_SUPPORT||TARGET_ath79 +kmod-ath +@DRIVER_11N_SUPPORT
195 FILES:= \
196 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_common.ko \
197 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_hw.ko
198 endef
199
200 define KernelPackage/ath9k
201 $(call KernelPackage/mac80211/Default)
202 TITLE:=Atheros 802.11n PCI wireless cards support
203 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath9k
204 DEPENDS+= @PCI_SUPPORT||TARGET_ath79 +kmod-ath9k-common
205 FILES:= \
206 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k.ko
207 AUTOLOAD:=$(call AutoProbe,ath9k)
208 endef
209
210 define KernelPackage/ath9k/description
211 This module adds support for wireless adapters based on
212 Atheros IEEE 802.11n AR5008 and AR9001 family of chipsets.
213 endef
214
215 define KernelPackage/ath9k/config
216
217 config ATH9K_HWRNG
218 bool "Add wireless noise as source of randomness to kernel entropy pool"
219 depends on PACKAGE_kmod-ath9k
220 select PACKAGE_kmod-random-core
221 default n
222
223 config ATH9K_SUPPORT_PCOEM
224 bool "Support chips used in PC OEM cards"
225 depends on PACKAGE_kmod-ath9k
226 default y if (x86_64 || i386)
227
228 config ATH9K_TX99
229 bool "Enable TX99 support (WARNING: testing only, breaks normal operation!)"
230 depends on PACKAGE_kmod-ath9k
231
232 config ATH9K_UBNTHSR
233 bool "Support for Ubiquiti UniFi Outdoor+ access point"
234 depends on PACKAGE_kmod-ath9k && TARGET_ath79
235 default y
236
237 endef
238
239 define KernelPackage/ath9k-htc
240 $(call KernelPackage/mac80211/Default)
241 TITLE:=Atheros 802.11n USB device support
242 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath9k
243 DEPENDS+= @USB_SUPPORT +kmod-ath9k-common +kmod-usb-core +ath9k-htc-firmware
244 FILES:= \
245 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_htc.ko
246 AUTOLOAD:=$(call AutoProbe,ath9k_htc)
247 endef
248
249 define KernelPackage/ath9k-htc/description
250 This module adds support for wireless adapters based on
251 Atheros USB AR9271 and AR7010 family of chipsets.
252 endef
253
254 define KernelPackage/ath10k
255 $(call KernelPackage/mac80211/Default)
256 TITLE:=Atheros 802.11ac wireless cards support
257 URL:=https://wireless.wiki.kernel.org/en/users/drivers/ath10k
258 DEPENDS+= @PCI_SUPPORT +kmod-ath +@DRIVER_11N_SUPPORT +@DRIVER_11AC_SUPPORT \
259 +ATH10K_THERMAL:kmod-hwmon-core +ATH10K_THERMAL:kmod-thermal
260 FILES:= \
261 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_core.ko \
262 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_pci.ko
263 AUTOLOAD:=$(call AutoProbe,ath10k_core ath10k_pci)
264 MODPARAMS.ath10k_core:=frame_mode=2
265 VARIANT:=regular
266 endef
267
268 define KernelPackage/ath10k/description
269 This module adds support for wireless adapters based on
270 Atheros IEEE 802.11ac family of chipsets. For now only
271 PCI is supported.
272 endef
273
274 define KernelPackage/ath10k/config
275
276 config ATH10K_LEDS
277 bool "Enable LED support"
278 default y
279 depends on PACKAGE_kmod-ath10k || PACKAGE_kmod-ath10k-smallbuffers
280
281 config ATH10K_THERMAL
282 bool "Enable thermal sensors and throttling support"
283 depends on PACKAGE_kmod-ath10k || PACKAGE_kmod-ath10k-smallbuffers
284
285 endef
286
287 define KernelPackage/ath10k-smallbuffers
288 $(call KernelPackage/ath10k)
289 TITLE+= (small buffers for low-RAM devices)
290 VARIANT:=smallbuffers
291 endef
292
293 define KernelPackage/carl9170
294 $(call KernelPackage/mac80211/Default)
295 TITLE:=Driver for Atheros AR9170 USB sticks
296 DEPENDS:=@USB_SUPPORT +kmod-mac80211 +kmod-ath +kmod-usb-core +kmod-input-core +@DRIVER_11N_SUPPORT +carl9170-firmware
297 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/carl9170/carl9170.ko
298 AUTOLOAD:=$(call AutoProbe,carl9170)
299 endef
300
301 define KernelPackage/owl-loader
302 $(call KernelPackage/mac80211/Default)
303 TITLE:=Owl loader for initializing Atheros PCI(e) Wifi chips
304 DEPENDS:=@PCI_SUPPORT +kmod-ath9k
305 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_pci_owl_loader.ko
306 AUTOLOAD:=$(call AutoProbe,ath9k_pci_owl_loader)
307 endef
308
309 define KernelPackage/owl-loader/description
310 Kernel module that helps to initialize certain Qualcomm
311 Atheros' PCI(e) Wifi chips, which have the init data
312 (which contains the PCI device ID for example) stored
313 together with the calibration data in the file system.
314
315 This is necessary for devices like the Cisco Meraki Z1.
316 endef
317
318 define KernelPackage/ar5523
319 $(call KernelPackage/mac80211/Default)
320 TITLE:=Driver for Atheros AR5523 USB sticks
321 DEPENDS:=@USB_SUPPORT +kmod-mac80211 +kmod-ath +kmod-usb-core +kmod-input-core
322 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ar5523/ar5523.ko
323 AUTOLOAD:=$(call AutoProbe,ar5523)
324 endef
325
326 define KernelPackage/wil6210
327 $(call KernelPackage/mac80211/Default)
328 TITLE:=QCA/Wilocity 60g WiFi card wil6210 support
329 DEPENDS+= @PCI_SUPPORT +kmod-mac80211 +wil6210-firmware
330 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/wil6210/wil6210.ko
331 AUTOLOAD:=$(call AutoProbe,wil6210)
332 endef