ath9k: add some cleanups and minor fixes
[openwrt/svn-archive/archive.git] / package / kernel / mac80211 / Makefile
1 #
2 # Copyright (C) 2007-2012 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_NAME:=mac80211
12
13 PKG_VERSION:=2013-06-27
14 PKG_RELEASE:=1
15 PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources
16 PKG_BACKPORT_VERSION:=.1
17 PKG_MD5SUM:=73bd220c64c5c6fdc22b3bb7f180644f
18
19 PKG_SOURCE:=compat-wireless-$(PKG_VERSION)$(PKG_BACKPORT_VERSION).tar.bz2
20 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION)
21 PKG_BUILD_PARALLEL:=1
22
23 PKG_MAINTAINER:=Felix Fietkau <nbd@openwrt.org>
24
25 PKG_DRIVERS = \
26 adm8211 ath5k libertas-usb libertas-sd p54-common p54-pci p54-usb p54-spi \
27 rt2x00-lib rt2x00-pci rt2x00-usb rt2x00-soc rt2800-lib rt2400-pci \
28 rt2500-pci rt2500-usb rt61-pci rt73-usb rt2800-pci rt2800-usb \
29 rtl8180 rtl8187 zd1211rw mac80211-hwsim carl9170 b43 b43legacy \
30 ath9k-common ath9k ath9k-htc ath10k ath net-libipw net-ipw2100 net-ipw2200 \
31 mwl8k net-hermes net-hermes-pci net-hermes-plx net-hermes-pcmcia \
32 iwl-legacy iwl3945 iwl4965 iwlagn wl12xx lib80211 \
33 rtlwifi rtlwifi-pci rtlwifi-usb rtl8192c-common rtl8192ce rtl8192se \
34 rtl8192de rtl8192cu
35
36 PKG_CONFIG_DEPENDS:= \
37 CONFIG_PACKAGE_kmod-mac80211 \
38 $(patsubst %,CONFIG_PACKAGE_kmod-%,$(PKG_DRIVERS)) \
39 CONFIG_PACKAGE_MAC80211_DEBUGFS \
40 CONFIG_PACKAGE_MAC80211_MESH \
41 CONFIG_PACKAGE_ATH_DEBUG \
42 CONFIG_PACKAGE_B43_DEBUG \
43 CONFIG_PACKAGE_B43_PIO \
44 CONFIG_PACKAGE_B43_N_PHY \
45 CONFIG_PACKAGE_RTLWIFI_DEBUG \
46 CONFIG_ATH_USER_REGD \
47
48 include $(INCLUDE_DIR)/package.mk
49
50 WMENU:=Wireless Drivers
51
52 define KernelPackage/mac80211/Default
53 SUBMENU:=$(WMENU)
54 URL:=http://linuxwireless.org/
55 MAINTAINER:=Felix Fietkau <nbd@openwrt.org>
56 DEPENDS:=@(!(TARGET_avr32||TARGET_ps3||TARGET_pxcab)||BROKEN)
57 endef
58
59 define KernelPackage/cfg80211
60 $(call KernelPackage/mac80211/Default)
61 TITLE:=cfg80211 - wireless configuration API
62 DEPENDS+= +iw
63 FILES:= \
64 $(PKG_BUILD_DIR)/compat/compat.ko \
65 $(PKG_BUILD_DIR)/net/wireless/cfg80211.ko
66 endef
67
68 define KernelPackage/cfg80211/description
69 cfg80211 is the Linux wireless LAN (802.11) configuration API.
70 endef
71
72 define KernelPackage/mac80211
73 $(call KernelPackage/mac80211/Default)
74 TITLE:=Linux 802.11 Wireless Networking Stack
75 DEPENDS+= +kmod-crypto-core +kmod-crypto-arc4 +kmod-crypto-aes +kmod-cfg80211
76 KCONFIG:=\
77 CONFIG_AVERAGE=y
78 FILES:= $(PKG_BUILD_DIR)/net/mac80211/mac80211.ko
79 MENU:=1
80 endef
81
82 define KernelPackage/mac80211/config
83 if PACKAGE_kmod-mac80211
84
85 config PACKAGE_MAC80211_DEBUGFS
86 bool "Export mac80211 internals in DebugFS"
87 select KERNEL_DEBUG_FS
88 select KERNEL_RELAY if PACKAGE_kmod-ath9k-common
89 default y
90 help
91 Select this to see extensive information about
92 the internal state of mac80211 in debugfs.
93
94 config PACKAGE_MAC80211_MESH
95 bool "Enable 802.11s mesh support"
96 default y
97
98 endif
99 endef
100
101 define KernelPackage/mac80211/description
102 Generic IEEE 802.11 Networking Stack (mac80211)
103 endef
104
105 PKG_LINUX_FIRMWARE_NAME:=linux-firmware
106 PKG_LINUX_FIRMWARE_VERSION:=6942dba419d2ebf8c15514972e89734fd7a8cebc
107 PKG_LINUX_FIRMWARE_SOURCE:=$(PKG_LINUX_FIRMWARE_NAME)-$(PKG_LINUX_FIRMWARE_VERSION).tar.bz2
108 PKG_LINUX_FIRMWARE_PROTO:=git
109 PKG_LINUX_FIRMWARE_SOURCE_URL:=git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git
110 PKG_LINUX_FIRMWARE_SUBDIR:=$(PKG_LINUX_FIRMWARE_NAME)-$(PKG_LINUX_FIRMWARE_VERSION)
111 PKG_LINUX_FIRMWARE_MIRROR_MD5SUM:=a5f8c27af9e43f0ad24d7f821c5a781e
112
113 define Download/linux-firmware
114 FILE:=$(PKG_LINUX_FIRMWARE_SOURCE)
115 URL:=$(PKG_LINUX_FIRMWARE_SOURCE_URL)
116 MD5SUM:=$(PKG_LINUX_FIRMWARE_MD5SUM)
117 PROTO:=$(PKG_LINUX_FIRMWARE_PROTO)
118 VERSION:=$(PKG_LINUX_FIRMWARE_VERSION)
119 SUBDIR:=$(PKG_LINUX_FIRMWARE_SUBDIR)
120 MIRROR_MD5SUM:=$(PKG_LINUX_FIRMWARE_MIRROR_MD5SUM)
121 endef
122 $(eval $(call Download,linux-firmware))
123
124 PKG_ATH10K_LINUX_FIRMWARE_NAME:=ath10k-firmware
125 PKG_ATH10K_LINUX_FIRMWARE_VERSION:=9374d42c01bd84487855af9f9bffc622c50e7331
126 PKG_ATH10K_LINUX_FIRMWARE_SOURCE:=$(PKG_ATH10K_LINUX_FIRMWARE_NAME)-$(PKG_ATH10K_LINUX_FIRMWARE_VERSION).tar.bz2
127 PKG_ATH10K_LINUX_FIRMWARE_PROTO:=git
128 PKG_ATH10K_LINUX_FIRMWARE_SOURCE_URL:=https://github.com/kvalo/ath10k-firmware.git
129 PKG_ATH10K_LINUX_FIRMWARE_SUBDIR:=$(PKG_ATH10K_LINUX_FIRMWARE_NAME)-$(PKG_ATH10K_LINUX_FIRMWARE_VERSION)
130 #PKG_ATH10K_LINUX_FIRMWARE_MIRROR_MD5SUM:=?
131
132 define Download/ath10k-firmware
133 FILE:=$(PKG_ATH10K_LINUX_FIRMWARE_SOURCE)
134 URL:=$(PKG_ATH10K_LINUX_FIRMWARE_SOURCE_URL)
135 PROTO:=$(PKG_ATH10K_LINUX_FIRMWARE_PROTO)
136 VERSION:=$(PKG_ATH10K_LINUX_FIRMWARE_VERSION)
137 SUBDIR:=$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)
138 #MIRROR_MD5SUM:=$(PKG_ATH10K_LINUX_FIRMWARE_MIRROR_MD5SUM)
139 endef
140 $(eval $(call Download,ath10k-firmware))
141
142 # Prism54 drivers
143 P54PCIFW:=2.13.12.0.arm
144 P54USBFW:=2.13.24.0.lm87.arm
145 P54SPIFW:=2.13.0.0.a.13.14.arm
146
147 define Download/p54usb
148 FILE:=$(P54USBFW)
149 URL:=http://daemonizer.de/prism54/prism54-fw/fw-usb
150 MD5SUM:=8e8ab005a4f8f0123bcdc51bc25b47f6
151 endef
152 $(eval $(call Download,p54usb))
153
154 define Download/p54pci
155 FILE:=$(P54PCIFW)
156 URL:=http://daemonizer.de/prism54/prism54-fw/fw-softmac
157 MD5SUM:=ff7536af2092b1c4b21315bd103ef4c4
158 endef
159 $(eval $(call Download,p54pci))
160
161 define Download/p54spi
162 FILE:=$(P54SPIFW)
163 URL:=http://daemonizer.de/prism54/prism54-fw/stlc4560
164 MD5SUM:=42661f8ecbadd88012807493f596081d
165 endef
166 $(eval $(call Download,p54spi))
167
168 define KernelPackage/p54/Default
169 $(call KernelPackage/mac80211/Default)
170 TITLE:=Prism54 Drivers
171 endef
172
173 define KernelPackage/p54/description
174 Kernel module for Prism54 chipsets (mac80211)
175 endef
176
177 define KernelPackage/p54-common
178 $(call KernelPackage/p54/Default)
179 DEPENDS+= @PCI_SUPPORT||@USB_SUPPORT||@TARGET_omap24xx +kmod-mac80211 +kmod-lib-crc-ccitt
180 TITLE+= (COMMON)
181 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54common.ko
182 endef
183
184 define KernelPackage/p54-pci
185 $(call KernelPackage/p54/Default)
186 TITLE+= (PCI)
187 DEPENDS+= @PCI_SUPPORT +kmod-p54-common
188 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54pci.ko
189 AUTOLOAD:=$(call AutoProbe,p54pci)
190 endef
191
192 define KernelPackage/p54-usb
193 $(call KernelPackage/p54/Default)
194 TITLE+= (USB)
195 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-p54-common
196 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54usb.ko
197 AUTOLOAD:=$(call AutoProbe,p54usb)
198 endef
199
200 define KernelPackage/p54-spi
201 $(call KernelPackage/p54/Default)
202 TITLE+= (SPI)
203 DEPENDS+= @TARGET_omap24xx +kmod-p54-common
204 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54spi.ko
205 AUTOLOAD:=$(call AutoProbe,p54spi)
206 endef
207
208 define KernelPackage/rt2x00/Default
209 $(call KernelPackage/mac80211/Default)
210 TITLE:=Ralink Drivers for RT2x00 cards
211 endef
212
213 define KernelPackage/rt2x00-lib
214 $(call KernelPackage/rt2x00/Default)
215 DEPENDS+= @(PCI_SUPPORT||USB_SUPPORT||TARGET_ramips) +kmod-mac80211 +kmod-lib-crc-itu-t
216 TITLE+= (LIB)
217 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00lib.ko
218 MENU:=1
219 endef
220
221 define KernelPackage/rt2x00-lib/config
222 if PACKAGE_kmod-rt2x00-lib
223
224 config PACKAGE_RT2X00_LIB_DEBUGFS
225 bool "Enable rt2x00 debugfs support"
226 depends on PACKAGE_MAC80211_DEBUGFS
227 help
228 Enable creation of debugfs files for the rt2x00 drivers.
229 These debugfs files support both reading and writing of the
230 most important register types of the rt2x00 hardware.
231
232 config PACKAGE_RT2X00_DEBUG
233 bool "Enable rt2x00 debug output"
234 help
235 Enable debugging output for all rt2x00 modules
236
237 endif
238 endef
239
240 define KernelPackage/rt2x00-mmio
241 $(call KernelPackage/rt2x00/Default)
242 DEPENDS+= @(PCI_SUPPORT||TARGET_ramips) +kmod-rt2x00-lib +kmod-eeprom-93cx6
243 TITLE+= (MMIO)
244 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00mmio.ko
245 endef
246
247 define KernelPackage/rt2x00-pci
248 $(call KernelPackage/rt2x00/Default)
249 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-mmio +kmod-rt2x00-lib
250 TITLE+= (PCI)
251 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00pci.ko
252 AUTOLOAD:=$(call AutoProbe,rt2x00pci)
253 endef
254
255 define KernelPackage/rt2x00-usb
256 $(call KernelPackage/rt2x00/Default)
257 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-lib +kmod-usb-core
258 TITLE+= (USB)
259 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00usb.ko
260 AUTOLOAD:=$(call AutoProbe,rt2x00usb)
261 endef
262
263 define KernelPackage/rt2x00-soc
264 $(call KernelPackage/rt2x00/Default)
265 DEPENDS+=@TARGET_ramips_rt305x +kmod-rt2x00-mmio +kmod-rt2x00-lib
266 TITLE+= (SoC)
267 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00soc.ko
268 AUTOLOAD:=$(call AutoProbe,rt2x00soc)
269 endef
270
271 define KernelPackage/rt2800-lib
272 $(call KernelPackage/rt2x00/Default)
273 DEPENDS+= @(PCI_SUPPORT||USB_SUPPORT||TARGET_ramips) +kmod-rt2x00-lib +kmod-lib-crc-ccitt +@DRIVER_11N_SUPPORT
274 TITLE+= (rt2800 LIB)
275 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2800lib.ko
276 endef
277
278 define KernelPackage/rt2400-pci
279 $(call KernelPackage/rt2x00/Default)
280 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
281 TITLE+= (RT2400 PCI)
282 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2400pci.ko
283 AUTOLOAD:=$(call AutoProbe,rt2400pci)
284 endef
285
286 define KernelPackage/rt2500-pci
287 $(call KernelPackage/rt2x00/Default)
288 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
289 TITLE+= (RT2500 PCI)
290 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2500pci.ko
291 AUTOLOAD:=$(call AutoProbe,rt2500pci)
292 endef
293
294 define KernelPackage/rt2500-usb
295 $(call KernelPackage/rt2x00/Default)
296 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-usb
297 TITLE+= (RT2500 USB)
298 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2500usb.ko
299 AUTOLOAD:=$(call AutoProbe,rt2500usb)
300 endef
301
302 define KernelPackage/rt61-pci
303 $(call KernelPackage/rt2x00/Default)
304 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
305 TITLE+= (RT2x61 PCI)
306 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt61pci.ko
307 AUTOLOAD:=$(call AutoProbe,rt61pci)
308 endef
309
310 define KernelPackage/rt73-usb
311 $(call KernelPackage/rt2x00/Default)
312 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-usb
313 TITLE+= (RT73 USB)
314 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt73usb.ko
315 AUTOLOAD:=$(call AutoProbe,rt73usb)
316 endef
317
318 define KernelPackage/rt2800-pci
319 $(call KernelPackage/rt2x00/Default)
320 DEPENDS+= @(PCI_SUPPORT||TARGET_ramips_rt305x) +PCI_SUPPORT:kmod-rt2x00-pci +kmod-rt2800-lib +kmod-lib-crc-ccitt +TARGET_ramips_rt305x:kmod-rt2x00-soc
321 TITLE+= (RT2860 PCI)
322 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2800pci.ko
323 AUTOLOAD:=$(call AutoProbe,rt2800pci)
324 endef
325
326 define KernelPackage/rt2800-usb
327 $(call KernelPackage/rt2x00/Default)
328 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-usb +kmod-rt2800-lib +kmod-lib-crc-ccitt
329 TITLE+= (RT2870 USB)
330 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2800usb.ko
331 AUTOLOAD:=$(call AutoProbe,rt2800usb)
332 endef
333
334 define KernelPackage/rtl818x/Default
335 $(call KernelPackage/mac80211/Default)
336 TITLE:=Realtek Drivers for RTL818x devices
337 URL:=http://wireless.kernel.org/en/users/Drivers/rtl8187
338 DEPENDS+= +kmod-eeprom-93cx6 +kmod-mac80211
339 endef
340
341 define KernelPackage/rtl8180
342 $(call KernelPackage/rtl818x/Default)
343 DEPENDS+= @PCI_SUPPORT
344 TITLE+= (RTL8180 PCI)
345 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtl818x/rtl8180/rtl8180.ko
346 AUTOLOAD:=$(call AutoProbe,rtl8180)
347 endef
348
349 define KernelPackage/rtl8187
350 $(call KernelPackage/rtl818x/Default)
351 DEPENDS+= @USB_SUPPORT +kmod-usb-core
352 TITLE+= (RTL8187 USB)
353 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtl818x/rtl8187/rtl8187.ko
354 AUTOLOAD:=$(call AutoProbe,rtl8187)
355 endef
356
357 define KernelPackage/rtlwifi/config
358 menu "Configuration"
359 depends on PACKAGE_kmod-rtlwifi
360
361 config PACKAGE_RTLWIFI_DEBUG
362 bool "Realtek wireless debugging"
363 help
364 Say Y, if you want to debug realtek wireless drivers.
365
366 endmenu
367 endef
368
369 define KernelPackage/rtlwifi
370 $(call KernelPackage/mac80211/Default)
371 TITLE:=Realtek common driver part
372 DEPENDS+= @(PCI_SUPPORT||USB_SUPPORT) +kmod-mac80211 +@DRIVER_11N_SUPPORT
373 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtlwifi.ko
374 MENU:=1
375 endef
376
377 define KernelPackage/rtlwifi-pci
378 $(call KernelPackage/mac80211/Default)
379 TITLE:=Realtek common driver part (PCI support)
380 DEPENDS+= @PCI_SUPPORT +kmod-rtlwifi
381 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl_pci.ko
382 AUTOLOAD:=$(call AutoProbe,rtl_pci)
383 HIDDEN:=1
384 endef
385
386 define KernelPackage/rtlwifi-usb
387 $(call KernelPackage/mac80211/Default)
388 TITLE:=Realtek common driver part (USB support)
389 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-rtlwifi
390 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl_usb.ko
391 AUTOLOAD:=$(call AutoProbe,rtl_usb)
392 HIDDEN:=1
393 endef
394
395 define KernelPackage/rtl8192c-common
396 $(call KernelPackage/mac80211/Default)
397 TITLE:=Realtek RTL8192CE/RTL8192CU common support module
398 DEPENDS+= +kmod-rtlwifi
399 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl8192c/rtl8192c-common.ko
400 HIDDEN:=1
401 endef
402
403 define KernelPackage/rtl8192ce
404 $(call KernelPackage/mac80211/Default)
405 TITLE:=Realtek RTL8192CE/RTL8188CE support
406 DEPENDS+= +kmod-rtlwifi-pci +kmod-rtl8192c-common
407 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192ce.ko
408 AUTOLOAD:=$(call AutoProbe,rtl8192ce)
409 endef
410
411 define KernelPackage/rtl8192ce/install
412 $(INSTALL_DIR) $(1)/lib/firmware/rtlwifi
413 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rtlwifi/rtl8192cfw.bin $(1)/lib/firmware/rtlwifi
414 endef
415
416 define KernelPackage/rtl8192se
417 $(call KernelPackage/mac80211/Default)
418 TITLE:=Realtek RTL8192SE/RTL8191SE support
419 DEPENDS+= +kmod-rtlwifi-pci
420 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl8192se/rtl8192se.ko
421 AUTOLOAD:=$(call AutoProbe,rtl8192se)
422 endef
423
424 define KernelPackage/rtl8192se/install
425 $(INSTALL_DIR) $(1)/lib/firmware/rtlwifi
426 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rtlwifi/rtl8192sefw.bin $(1)/lib/firmware/rtlwifi
427 endef
428
429 define KernelPackage/rtl8192de
430 $(call KernelPackage/mac80211/Default)
431 TITLE:=Realtek RTL8192DE/RTL8188DE support
432 DEPENDS+= +kmod-rtlwifi-pci
433 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl8192de/rtl8192de.ko
434 AUTOLOAD:=$(call AutoProbe,rtl8192de)
435 endef
436
437 define KernelPackage/rtl8192de/install
438 $(INSTALL_DIR) $(1)/lib/firmware/rtlwifi
439 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rtlwifi/rtl8192defw.bin $(1)/lib/firmware/rtlwifi
440 endef
441
442 define KernelPackage/rtl8192cu
443 $(call KernelPackage/mac80211/Default)
444 TITLE:=Realtek RTL8192CU/RTL8188CU support
445 DEPENDS+= +kmod-rtlwifi-usb +kmod-rtl8192c-common
446 FILES:= $(PKG_BUILD_DIR)/drivers/net/wireless/rtlwifi/rtl8192cu/rtl8192cu.ko
447 AUTOLOAD:=$(call AutoProbe,rtl8192cu)
448 endef
449
450 define KernelPackage/rtl8192cu/install
451 $(INSTALL_DIR) $(1)/lib/firmware/rtlwifi
452 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rtlwifi/rtl8192cufw.bin $(1)/lib/firmware/rtlwifi
453 endef
454
455 ZD1211FW_NAME:=zd1211-firmware
456 ZD1211FW_VERSION:=1.4
457 define Download/zd1211rw
458 FILE:=$(ZD1211FW_NAME)-$(ZD1211FW_VERSION).tar.bz2
459 URL:=@SF/zd1211/
460 MD5SUM:=19f28781d76569af8551c9d11294c870
461 endef
462 $(eval $(call Download,zd1211rw))
463
464 define KernelPackage/zd1211rw
465 $(call KernelPackage/mac80211/Default)
466 TITLE:=Zydas ZD1211 support
467 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-mac80211
468 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/zd1211rw/zd1211rw.ko
469 AUTOLOAD:=$(call AutoProbe,zd1211rw)
470 endef
471
472 define KernelPackage/adm8211
473 $(call KernelPackage/mac80211/Default)
474 TITLE:=ADMTek 8211 support
475 DEPENDS+=@PCI_SUPPORT +kmod-mac80211 +kmod-eeprom-93cx6
476 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/adm8211.ko
477 AUTOLOAD:=$(call AutoProbe,adm8211)
478 endef
479
480 define KernelPackage/ath/config
481 if PACKAGE_kmod-ath
482 config ATH_USER_REGD
483 bool "Force Atheros drivers to respect the user's regdomain settings"
484 help
485 Atheros' idea of regulatory handling is that the EEPROM of the card defines
486 the regulatory limits and the user is only allowed to restrict the settings
487 even further, even if the country allows frequencies or power levels that
488 are forbidden by the EEPROM settings.
489
490 Select this option if you want the driver to respect the user's decision about
491 regulatory settings.
492
493 config PACKAGE_ATH_DEBUG
494 bool "Atheros wireless debugging"
495 help
496 Say Y, if you want to debug atheros wireless drivers.
497 Right now only ath9k makes use of this.
498 endif
499 endef
500
501 define KernelPackage/ath
502 $(call KernelPackage/mac80211/Default)
503 TITLE:=Atheros common driver part
504 DEPENDS+= @PCI_SUPPORT||USB_SUPPORT||TARGET_ar71xx||TARGET_atheros +kmod-mac80211
505 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath.ko
506 MENU:=1
507 endef
508
509 define KernelPackage/ath/description
510 This module contains some common parts needed by Atheros Wireless drivers.
511 endef
512
513 define KernelPackage/ath5k
514 $(call KernelPackage/mac80211/Default)
515 TITLE:=Atheros 5xxx wireless cards support
516 URL:=http://linuxwireless.org/en/users/Drivers/ath5k
517 DEPENDS+= @PCI_SUPPORT||@TARGET_atheros +kmod-ath
518 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath5k/ath5k.ko
519 AUTOLOAD:=$(call AutoProbe,ath5k)
520 endef
521
522 define KernelPackage/ath5k/description
523 This module adds support for wireless adapters based on
524 Atheros 5xxx chipset.
525 endef
526
527 define KernelPackage/ath9k-common
528 $(call KernelPackage/mac80211/Default)
529 TITLE:=Atheros 802.11n wireless devices (common code for ath9k and ath9k_htc)
530 URL:=http://linuxwireless.org/en/users/Drivers/ath9k
531 DEPENDS+= @PCI_SUPPORT||USB_SUPPORT||TARGET_ar71xx +kmod-ath +@DRIVER_11N_SUPPORT
532 FILES:= \
533 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_common.ko \
534 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_hw.ko
535 endef
536
537 define KernelPackage/ath9k
538 $(call KernelPackage/mac80211/Default)
539 TITLE:=Atheros 802.11n PCI wireless cards support
540 URL:=http://linuxwireless.org/en/users/Drivers/ath9k
541 DEPENDS+= @PCI_SUPPORT||TARGET_ar71xx +kmod-ath9k-common
542 FILES:= \
543 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k.ko
544 AUTOLOAD:=$(call AutoProbe,ath9k)
545 endef
546
547 define KernelPackage/ath9k/description
548 This module adds support for wireless adapters based on
549 Atheros IEEE 802.11n AR5008 and AR9001 family of chipsets.
550 endef
551
552 define KernelPackage/ath9k-htc
553 $(call KernelPackage/mac80211/Default)
554 TITLE:=Atheros 802.11n USB device support
555 URL:=http://linuxwireless.org/en/users/Drivers/ath9k
556 DEPENDS+= @USB_SUPPORT +kmod-ath9k-common +kmod-usb-core
557 FILES:= \
558 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath9k/ath9k_htc.ko
559 AUTOLOAD:=$(call AutoProbe,ath9k_htc)
560 endef
561
562 define KernelPackage/ath9k-htc/description
563 This module adds support for wireless adapters based on
564 Atheros USB AR9271 and AR7010 family of chipsets.
565 endef
566
567 define KernelPackage/ath10k
568 $(call KernelPackage/mac80211/Default)
569 TITLE:=Atheros 802.11ac wireless cards support
570 URL:=http://wireless.kernel.org/en/users/Drivers/ath10k
571 DEPENDS+= @PCI_SUPPORT +kmod-ath +@DRIVER_11N_SUPPORT
572 FILES:= \
573 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_core.ko \
574 $(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_pci.ko
575 AUTOLOAD:=$(call AutoLoad,55,ath10k_core ath10k_pci)
576 endef
577
578 define KernelPackage/ath10k/description
579 This module adds support for wireless adapters based on
580 Atheros IEEE 802.11ac family of chipsets. For now only
581 PCI is supported.
582 endef
583
584 define KernelPackage/carl9170
585 $(call KernelPackage/mac80211/Default)
586 TITLE:=Driver for Atheros AR9170 USB sticks
587 DEPENDS:=@USB_SUPPORT +kmod-mac80211 +kmod-ath +kmod-usb-core +kmod-input-core +@DRIVER_11N_SUPPORT
588 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath/carl9170/carl9170.ko
589 AUTOLOAD:=$(call AutoProbe,carl9170)
590 endef
591
592 define KernelPackage/lib80211
593 $(call KernelPackage/mac80211/Default)
594 TITLE:=802.11 Networking stack
595 DEPENDS:=+kmod-cfg80211
596 FILES:= \
597 $(PKG_BUILD_DIR)/net/wireless/lib80211.ko \
598 $(PKG_BUILD_DIR)/net/wireless/lib80211_crypt_wep.ko \
599 $(PKG_BUILD_DIR)/net/wireless/lib80211_crypt_ccmp.ko \
600 $(PKG_BUILD_DIR)/net/wireless/lib80211_crypt_tkip.ko
601 AUTOLOAD:=$(call AutoProbe, \
602 lib80211 \
603 lib80211_crypt_wep \
604 lib80211_crypt_ccmp \
605 lib80211_crypt_tkip \
606 )
607 endef
608
609 define KernelPackage/lib80211/description
610 Kernel modules for 802.11 Networking stack
611 Includes:
612 - lib80211
613 - lib80211_crypt_wep
614 - lib80211_crypt_tkip
615 - lib80211_crytp_ccmp
616 endef
617
618 define KernelPackage/libertas-usb
619 $(call KernelPackage/mac80211/Default)
620 DEPENDS+= @USB_SUPPORT +kmod-cfg80211 +kmod-usb-core +kmod-lib80211 +@DRIVER_WEXT_SUPPORT
621 TITLE:=Marvell 88W8015 Wireless Driver
622 FILES:= \
623 $(PKG_BUILD_DIR)/drivers/net/wireless/libertas/libertas.ko \
624 $(PKG_BUILD_DIR)/drivers/net/wireless/libertas/usb8xxx.ko
625 AUTOLOAD:=$(call AutoProbe,libertas usb8xxx)
626 endef
627
628 define KernelPackage/libertas-sd
629 $(call KernelPackage/mac80211/Default)
630 DEPENDS+= +kmod-cfg80211 +kmod-lib80211 +kmod-mmc +@DRIVER_WEXT_SUPPORT
631 TITLE:=Marvell 88W8686 Wireless Driver
632 FILES:= \
633 $(PKG_BUILD_DIR)/drivers/net/wireless/libertas/libertas.ko \
634 $(PKG_BUILD_DIR)/drivers/net/wireless/libertas/libertas_sdio.ko
635 AUTOLOAD:=$(call AutoProbe,libertas libertas_sdio)
636 endef
637
638 define KernelPackage/mac80211-hwsim
639 $(call KernelPackage/mac80211/Default)
640 TITLE:=mac80211 HW simulation device
641 DEPENDS+= +kmod-mac80211
642 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/mac80211_hwsim.ko
643 AUTOLOAD:=$(call AutoProbe,mac80211_hwsim)
644 endef
645
646 define KernelPackage/net-libipw
647 $(call KernelPackage/mac80211/Default)
648 TITLE:=libipw for ipw2100 and ipw2200
649 DEPENDS:=@PCI_SUPPORT +kmod-crypto-core +kmod-crypto-arc4 +kmod-crypto-aes +kmod-crypto-michael-mic +kmod-lib80211 +kmod-cfg80211 +@DRIVER_WEXT_SUPPORT
650 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ipw2x00/libipw.ko
651 AUTOLOAD:=$(call AutoProbe,libipw)
652 endef
653
654 define KernelPackage/net-libipw/description
655 Hardware independent IEEE 802.11 networking stack for ipw2100 and ipw2200.
656 endef
657
658 IPW2100_NAME:=ipw2100-fw
659 IPW2100_VERSION:=1.3
660
661 define Download/net-ipw2100
662 URL:=http://bughost.org/firmware/
663 FILE:=$(IPW2100_NAME)-$(IPW2100_VERSION).tgz
664 MD5SUM=46aa75bcda1a00efa841f9707bbbd113
665 endef
666 $(eval $(call Download,net-ipw2100))
667
668 define KernelPackage/net-ipw2100
669 $(call KernelPackage/mac80211/Default)
670 TITLE:=Intel IPW2100 driver
671 DEPENDS:=@PCI_SUPPORT +kmod-net-libipw
672 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ipw2x00/ipw2100.ko
673 AUTOLOAD:=$(call AutoProbe,ipw2100)
674 endef
675
676 define KernelPackage/net-ipw2100/description
677 Kernel support for Intel IPW2100
678 Includes:
679 - ipw2100
680 endef
681
682 IPW2200_NAME:=ipw2200-fw
683 IPW2200_VERSION:=3.1
684
685 define Download/net-ipw2200
686 URL:=http://bughost.org/firmware/
687 FILE:=$(IPW2200_NAME)-$(IPW2200_VERSION).tgz
688 MD5SUM=eaba788643c7cc7483dd67ace70f6e99
689 endef
690 $(eval $(call Download,net-ipw2200))
691
692 define KernelPackage/net-ipw2200
693 $(call KernelPackage/mac80211/Default)
694 TITLE:=Intel IPW2200 driver
695 DEPENDS:=@PCI_SUPPORT +kmod-net-libipw
696 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ipw2x00/ipw2200.ko
697 AUTOLOAD:=$(call AutoProbe,ipw2200)
698 endef
699
700 define KernelPackage/net-ipw2200/description
701 Kernel support for Intel IPW2200
702 Includes:
703 - ipw2200
704 endef
705
706
707 define KernelPackage/net-hermes
708 $(call KernelPackage/mac80211/Default)
709 TITLE:=Hermes 802.11b chipset support
710 DEPENDS:=@PCI_SUPPORT||PCMCIA_SUPPORT +kmod-cfg80211 +@DRIVER_WEXT_SUPPORT
711 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/orinoco/orinoco.ko
712 AUTOLOAD:=$(call AutoProbe,orinoco)
713 endef
714
715 define KernelPackage/net-hermes/description
716 Kernel support for Hermes 802.11b chipsets
717 endef
718
719 define KernelPackage/net-hermes-pci
720 $(call KernelPackage/mac80211/Default)
721 TITLE:=Intersil Prism 2.5 PCI support
722 DEPENDS:=@PCI_SUPPORT +kmod-net-hermes
723 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/orinoco/orinoco_pci.ko
724 AUTOLOAD:=$(call AutoProbe,orinoco_pci)
725 endef
726
727 define KernelPackage/net-hermes-pci/description
728 Kernel modules for Intersil Prism 2.5 PCI support
729 endef
730
731 define KernelPackage/net-hermes-plx
732 $(call KernelPackage/mac80211/Default)
733 TITLE:=PLX9052 based PCI adaptor
734 DEPENDS:=@PCI_SUPPORT +kmod-net-hermes
735 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/orinoco/orinoco_plx.ko
736 AUTOLOAD:=$(call AutoProbe,orinoco_plx)
737 endef
738
739 define KernelPackage/net-hermes-plx/description
740 Kernel modules for Hermes in PLX9052 based PCI adaptors
741 endef
742
743 define KernelPackage/net-hermes-pcmcia
744 $(call KernelPackage/mac80211/Default)
745 TITLE:=Hermes based PCMCIA adaptors
746 DEPENDS:=@PCMCIA_SUPPORT +kmod-net-hermes @BROKEN
747 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/orinoco/orinoco_cs.ko
748 AUTOLOAD:=$(call AutoProbe,orinoco_cs)
749 endef
750
751 define KernelPackage/net-hermes-pcmcia/description
752 Kernel modules for Hermes based PCMCIA adaptors
753 endef
754
755 define KernelPackage/iwlagn
756 $(call KernelPackage/mac80211/Default)
757 DEPENDS:= +kmod-mac80211 @PCI_SUPPORT +@DRIVER_11N_SUPPORT
758 TITLE:=Intel AGN Wireless support
759 FILES:= \
760 $(PKG_BUILD_DIR)/drivers/net/wireless/iwlwifi/iwlwifi.ko \
761 $(PKG_BUILD_DIR)/drivers/net/wireless/iwlwifi/dvm/iwldvm.ko
762 AUTOLOAD:=$(call AutoProbe,iwlwifi iwldvm)
763 MENU:=1
764 endef
765
766 define KernelPackage/iwlagn/description
767 iwlagn kernel module for Intel 5000/5150/1000/6000/6050/6005/6030/100 support
768 endef
769
770 define KernelPackage/iwlagn/config
771 if PACKAGE_kmod-iwlagn
772
773 config IWL5000_FW
774 bool "Intel 5000 Firmware"
775 default y
776 help
777 Download and install firmware for:
778 Intel Wireless WiFi 5100AGN, 5300AGN, and 5350AGN
779
780 config IWL5150_FW
781 bool "Intel 5150 Firmware"
782 default y
783 help
784 Download and install firmware for:
785 Intel Wireless WiFi 5150AGN
786
787 config IWL1000_FW
788 bool "Intel 1000 Firmware"
789 default y
790 help
791 Download and install firmware for:
792 Intel Centrino Wireless-N 1000
793
794 config IWL6000_FW
795 bool "Intel 6000 Firmware"
796 default y
797 help
798 Download and install firmware for:
799 Intel Centrino Ultimate-N 6300 and Advanced-N 6200
800
801 config IWL6050_FW
802 bool "Intel 6050 Firmware"
803 default y
804 help
805 Download and install firmware for:
806 Intel Centrino Advanced-N + WiMAX 6250 and Wireless-N + WiMAX 6150
807
808 config IWL6005_FW
809 bool "Intel 6005 Firmware"
810 default y
811 help
812 Download and install firmware for:
813 Intel Centrino Advanced-N 6205
814
815 config IWL6030_FW
816 bool "Intel 6030 Firmware"
817 default y
818 help
819 Download and install firmware for:
820 Intel Centrino Advanced-N 6230, Wireless-N 1030, Wireless-N 130 and Advanced-N 6235
821
822 config IWL100_FW
823 bool "Intel 100 Firmware"
824 default y
825 help
826 Download and install firmware for:
827 Intel Centrino Wireless-N 100
828
829 config IWL2000_FW
830 bool "Intel 2000 Firmware"
831 default y
832 help
833 Download and install firmware for:
834 Intel Centrino Wireless-N 2200
835
836 config IWL2030_FW
837 bool "Intel 2030 Firmware"
838 default y
839 help
840 Download and install firmware for:
841 Intel Centrino Wireless-N 2230
842
843 config IWL105_FW
844 bool "Intel 105 Firmware"
845 default y
846 help
847 Download and install firmware for:
848 Intel Centrino Wireless-N 105
849
850 config IWL135_FW
851 bool "Intel 135 Firmware"
852 default y
853 help
854 Download and install firmware for:
855 Intel Centrino Wireless-N 135
856 endif
857 endef
858
859 define KernelPackage/iwl-legacy
860 $(call KernelPackage/mac80211/Default)
861 DEPENDS:= +kmod-mac80211 @PCI_SUPPORT
862 TITLE:=Intel legacy Wireless support
863 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/iwlegacy/iwlegacy.ko
864 AUTOLOAD:=$(call AutoProbe,iwlegacy)
865 endef
866
867 define KernelPackage/iwl-legacy/description
868 iwl-legacy kernel module for legacy Intel wireless support
869 endef
870
871 define KernelPackage/iwl3945
872 $(call KernelPackage/mac80211/Default)
873 DEPENDS:= +kmod-mac80211 +kmod-iwl-legacy
874 TITLE:=Intel iwl3945 Wireless support
875 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/iwlegacy/iwl3945.ko
876 AUTOLOAD:=$(call AutoProbe,iwl3945)
877 endef
878
879 define KernelPackage/iwl3945/description
880 iwl3945 kernel module for Intel 3945 support
881 endef
882
883 define KernelPackage/iwl4965
884 $(call KernelPackage/mac80211/Default)
885 DEPENDS:= +kmod-mac80211 +kmod-iwl-legacy +@DRIVER_11N_SUPPORT
886 TITLE:=Intel iwl4965 Wireless support
887 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/iwlegacy/iwl4965.ko
888 AUTOLOAD:=$(call AutoProbe,iwl4965)
889 endef
890
891 define KernelPackage/iwl4965/description
892 iwl4965 kernel module for Intel 4965 support
893 endef
894
895
896 define KernelPackage/mwl8k
897 $(call KernelPackage/mac80211/Default)
898 TITLE:=Driver for Marvell TOPDOG 802.11 Wireless cards
899 URL:=http://wireless.kernel.org/en/users/Drivers/mwl8k
900 DEPENDS+= @PCI_SUPPORT +kmod-mac80211 +@DRIVER_11N_SUPPORT
901 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/mwl8k.ko
902 AUTOLOAD:=$(call AutoProbe,mwl8k)
903 endef
904
905 define KernelPackage/mwl8k/description
906 Kernel modules for Marvell TOPDOG 802.11 Wireless cards
907 endef
908
909
910 define KernelPackage/wl12xx
911 $(call KernelPackage/mac80211/Default)
912 TITLE:=Driver for TI WL12xx
913 URL:=http://wireless.kernel.org/en/users/Drivers/wl12xx
914 DEPENDS+= @TARGET_omap4 +kmod-mac80211
915 FILES:= \
916 $(PKG_BUILD_DIR)/drivers/net/wireless/ti/wl12xx/wl12xx.ko \
917 $(PKG_BUILD_DIR)/drivers/net/wireless/ti/wlcore/wlcore.ko \
918 $(PKG_BUILD_DIR)/drivers/net/wireless/ti/wlcore/wlcore_sdio.ko
919 AUTOLOAD:=$(call AutoProbe,wlcore wlcore_sdio wl12xx)
920 endef
921
922 define KernelPackage/wl12xx/description
923 Kernel modules for TI WL12xx
924 endef
925
926 #Broadcom firmware
927 ifneq ($(CONFIG_B43_FW_5_10),)
928 PKG_B43_FWV4_NAME:=broadcom-wl
929 PKG_B43_FWV4_VERSION:=5.10.56.27.3
930 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/driver/wl_apsta/wl_prebuilt.o
931 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)_mipsel.tar.bz2
932 PKG_B43_FWV4_SOURCE_URL:=http://mirror2.openwrt.org/sources/
933 PKG_B43_FWV4_MD5SUM:=3363e3a6b3d9d73c49dea870c7834eac
934 else
935 ifneq ($(CONFIG_B43_FW_4_178),)
936 PKG_B43_FWV4_NAME:=broadcom-wl
937 PKG_B43_FWV4_VERSION:=4.178.10.4
938 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/linux/wl_apsta.o
939 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION).tar.bz2
940 PKG_B43_FWV4_SOURCE_URL:=http://mirror2.openwrt.org/sources/
941 PKG_B43_FWV4_MD5SUM:=14477e8cbbb91b11896affac9b219fdb
942 else
943 ifneq ($(CONFIG_B43_FW_5_100_138),)
944 PKG_B43_FWV4_NAME:=broadcom-wl
945 PKG_B43_FWV4_VERSION:=5.100.138
946 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/linux/wl_apsta.o
947 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION).tar.bz2
948 PKG_B43_FWV4_SOURCE_URL:=http://www.lwfinger.com/b43-firmware/
949 PKG_B43_FWV4_MD5SUM:=f4e357b09eaf5d8b1f1920cf3493a555
950 else
951 PKG_B43_FWV4_NAME:=broadcom-wl
952 PKG_B43_FWV4_VERSION:=4.150.10.5
953 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/driver/wl_apsta_mimo.o
954 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION).tar.bz2
955 PKG_B43_FWV4_SOURCE_URL:=http://mirror2.openwrt.org/sources/
956 PKG_B43_FWV4_MD5SUM:=0c6ba9687114c6b598e8019e262d9a60
957 endif
958 endif
959 endif
960 ifneq ($(CONFIG_B43_OPENFIRMWARE),)
961 PKG_B43_FWV4_NAME:=broadcom-wl
962 PKG_B43_FWV4_VERSION:=5.2
963 PKG_B43_FWV4_OBJECT:=openfwwf-$(PKG_B43_FWV4_VERSION)
964 PKG_B43_FWV4_SOURCE:=openfwwf-$(PKG_B43_FWV4_VERSION).tar.gz
965 PKG_B43_FWV4_SOURCE_URL:=http://www.ing.unibs.it/openfwwf/firmware/
966 PKG_B43_FWV4_MD5SUM:=e045a135453274e439ae183f8498b0fa
967 endif
968
969
970 PKG_B43_FWV3_NAME:=wl_apsta
971 PKG_B43_FWV3_VERSION:=3.130.20.0
972 PKG_B43_FWV3_SOURCE:=$(PKG_B43_FWV3_NAME)-$(PKG_B43_FWV3_VERSION).o
973 PKG_B43_FWV3_SOURCE_URL:=http://downloads.openwrt.org/sources/
974 PKG_B43_FWV3_MD5SUM:=e08665c5c5b66beb9c3b2dd54aa80cb3
975
976 define Download/b43
977 FILE:=$(PKG_B43_FWV4_SOURCE)
978 URL:=$(PKG_B43_FWV4_SOURCE_URL)
979 MD5SUM:=$(PKG_B43_FWV4_MD5SUM)
980 endef
981 $(eval $(call Download,b43))
982
983 define Download/b43legacy
984 FILE:=$(PKG_B43_FWV3_SOURCE)
985 URL:=$(PKG_B43_FWV3_SOURCE_URL)
986 MD5SUM:=$(PKG_B43_FWV3_MD5SUM)
987 endef
988 $(eval $(call Download,b43legacy))
989
990
991 define KernelPackage/b43
992 $(call KernelPackage/mac80211/Default)
993 TITLE:=Broadcom 43xx wireless support
994 URL:=http://linuxwireless.org/en/users/Drivers/b43
995 KCONFIG:= \
996 CONFIG_HW_RANDOM=y
997 DEPENDS+= +kmod-mac80211 +!TARGET_brcm47xx:kmod-bcma +!(TARGET_brcm47xx||TARGET_brcm63xx):kmod-ssb
998 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/b43/b43.ko
999 AUTOLOAD:=$(call AutoProbe,b43)
1000 MENU:=1
1001 endef
1002
1003 define KernelPackage/b43/config
1004 if PACKAGE_kmod-b43
1005
1006 choice
1007 prompt "b43 firmware version"
1008 default B43_FW_5_100_138
1009 help
1010 This option allows you to select the version of the b43 firmware.
1011
1012 config B43_FW_4_150
1013 bool "Firmware 410.2160 from driver 4.150.10.5 (old stable)"
1014 help
1015 Stable firmware for BCM43xx devices.
1016
1017 If unsure, select this.
1018
1019 config B43_FW_4_178
1020 bool "Firmware 478.104 from driver 4.178.10.4"
1021 help
1022 Experimental firmware for BCM43xx devices.
1023
1024 This firmware is not tested as much as the "stable" firmware.
1025
1026 If unsure, select the "stable" firmware.
1027
1028 config B43_FW_5_10
1029 bool "Firmware 508.1084 from driver 5.10.56.27"
1030 help
1031 Newer experimental firmware for BCM43xx devices.
1032
1033 This firmware is mostly untested. It is needed for some N-PHY devices.
1034
1035 If unsure, select the "stable" firmware.
1036
1037 config B43_FW_5_100_138
1038 bool "Firmware 666.2 from driver 5.100.138 (stable)"
1039 help
1040 Newer experimental firmware for BCM43xx devices.
1041
1042 This firmware is mostly untested. It is needed for some N-PHY devices.
1043
1044 If unsure, select the "stable" firmware.
1045
1046 config B43_OPENFIRMWARE
1047 bool "Open FirmWare for WiFi networks"
1048 help
1049 Opensource firmware for BCM43xx devices.
1050
1051 Do _not_ select this, unless you know what you are doing.
1052 The Opensource firmware is not suitable for embedded devices, yet.
1053 It does not support QoS, which is bad for AccessPoints.
1054 It does not support hardware crypto acceleration, which is a showstopper
1055 for embedded devices with low CPU resources.
1056
1057 If unsure, select the "stable" firmware.
1058
1059 endchoice
1060
1061 config B43_FW_SQUASH
1062 bool "Remove unnecessary firmware files"
1063 depends on !B43_OPENFIRMWARE
1064 default y
1065 help
1066 This options allows you to remove unnecessary b43 firmware files
1067 from the final rootfs image. This can reduce the rootfs size by
1068 up to 200k.
1069
1070 If unsure, say Y.
1071
1072 config B43_FW_SQUASH_COREREVS
1073 string "Core revisions to include"
1074 depends on B43_FW_SQUASH
1075 default "5,6,7,8,9,10,11,13,15,16,29"
1076 help
1077 This is a comma seperated list of core revision numbers.
1078
1079 Example (keep files for rev5 only):
1080 5
1081
1082 Example (keep files for rev5 and rev11):
1083 5,11
1084
1085 config B43_FW_SQUASH_PHYTYPES
1086 string "PHY types to include"
1087 depends on B43_FW_SQUASH
1088 default "G,LP,N,HT"
1089 help
1090 This is a comma seperated list of PHY types:
1091 A => A-PHY
1092 AG => Dual A-PHY G-PHY
1093 G => G-PHY
1094 LP => LP-PHY
1095 N => N-PHY
1096 HT => HT-PHY
1097 LCN => LCN-PHY
1098
1099 Example (keep files for G-PHY only):
1100 G
1101
1102 Example (keep files for G-PHY and N-PHY):
1103 G,N
1104
1105 config PACKAGE_B43_DEBUG
1106 bool "Enable debug output and debugfs for b43"
1107 default n
1108 help
1109 Enable additional debug output and runtime sanity checks for b43
1110 and enables the debugfs interface.
1111
1112 If unsure, say N.
1113
1114 config PACKAGE_B43_PIO
1115 bool "Enable support for PIO transfer mode"
1116 default n
1117 help
1118 Enable support for using PIO instead of DMA. Unless you have DMA
1119 transfer problems you don't need this.
1120
1121 If unsure, say N.
1122
1123 config PACKAGE_B43_PHY_N
1124 bool "Enable support for N-PHYs"
1125 default y
1126 help
1127 Enable support for N-PHY. This includes support for the following devices:
1128 PCI: BCM4321, BCM4322, BCM43222, BCM43224, BCM43225
1129 SoC: BCM4716, BCM4717, BCM4718
1130
1131 Currently only 11g speed is available.
1132
1133 If unsure, say Y.
1134
1135 config PACKAGE_B43_PHY_HT
1136 bool "Enable support for HT-PHYs"
1137 default y
1138 help
1139 Enable support for HT-PHY. This includes support for the following devices:
1140 PCI: BCM4331
1141
1142 Currently only 11g speed is available.
1143
1144 If unsure, say Y.
1145
1146 config PACKAGE_B43_PHY_LCN
1147 bool "Enable support for LCN-PHYs"
1148 depends on BROKEN
1149 default n
1150 help
1151 Currently broken.
1152
1153 If unsure, say N.
1154
1155 endif
1156 endef
1157
1158 define KernelPackage/b43/description
1159 Kernel module for Broadcom 43xx wireless support (mac80211 stack) new
1160 endef
1161
1162 define KernelPackage/b43legacy
1163 $(call KernelPackage/mac80211/Default)
1164 TITLE:=Broadcom 43xx-legacy wireless support
1165 URL:=http://linuxwireless.org/en/users/Drivers/b43
1166 KCONFIG:= \
1167 CONFIG_HW_RANDOM=y
1168 DEPENDS+= +kmod-mac80211 +!(TARGET_brcm47xx||TARGET_brcm63xx):kmod-ssb
1169 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/b43legacy/b43legacy.ko
1170 AUTOLOAD:=$(call AutoProbe,b43legacy)
1171 MENU:=1
1172 endef
1173
1174 define KernelPackage/b43legacy/config
1175 if PACKAGE_kmod-b43legacy
1176
1177 config B43LEGACY_FW_SQUASH
1178 bool "Remove unnecessary firmware files"
1179 default y
1180 help
1181 This options allows you to remove unnecessary b43legacy firmware files
1182 from the final rootfs image. This can reduce the rootfs size by
1183 up to 50k.
1184
1185 If unsure, say Y.
1186
1187 config B43LEGACY_FW_SQUASH_COREREVS
1188 string "Core revisions to include"
1189 depends on B43LEGACY_FW_SQUASH
1190 default "1,2,3,4"
1191 help
1192 This is a comma seperated list of core revision numbers.
1193
1194 Example (keep files for rev4 only):
1195 4
1196
1197 Example (keep files for rev2 and rev4):
1198 2,4
1199
1200 endif
1201 endef
1202
1203 define KernelPackage/b43legacy/description
1204 Kernel module for Broadcom 43xx-legacy wireless support (mac80211 stack) new
1205 endef
1206
1207
1208 define KernelPackage/brcmutil
1209 $(call KernelPackage/mac80211/Default)
1210 TITLE:=Broadcom IEEE802.11n common driver parts
1211 URL:=http://linuxwireless.org/en/users/Drivers/brcm80211
1212 DEPENDS+=@PCI_SUPPORT||USB_SUPPORT
1213 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/brcm80211/brcmutil/brcmutil.ko
1214 AUTOLOAD:=$(call AutoProbe,brcmutil)
1215 MENU:=1
1216 endef
1217
1218 define KernelPackage/brcmutil/description
1219 This module contains some common parts needed by Broadcom Wireless drivers brcmsmac and brcmfmac.
1220 endef
1221
1222 define KernelPackage/brcmutil/config
1223 if PACKAGE_kmod-brcmutil
1224
1225 config PACKAGE_BRCM80211_DEBUG
1226 bool "Broadcom wireless driver debugging"
1227 help
1228 Say Y, if you want to debug brcmsmac and brcmfmac wireless driver.
1229
1230 endif
1231 endef
1232
1233 PKG_BRCMSMAC_FW_NAME:=broadcom-wl
1234 PKG_BRCMSMAC_FW_VERSION:=5.100.138
1235 PKG_BRCMSMAC_FW_OBJECT:=$(PKG_BRCMSMAC_FW_NAME)-$(PKG_BRCMSMAC_FW_VERSION)/linux/wl_apsta.o
1236 PKG_BRCMSMAC_FW_SOURCE:=$(PKG_BRCMSMAC_FW_NAME)-$(PKG_BRCMSMAC_FW_VERSION).tar.bz2
1237 PKG_BRCMSMAC_FW_SOURCE_URL:=http://www.lwfinger.com/b43-firmware/
1238 PKG_BRCMSMAC_FW_MD5SUM:=f4e357b09eaf5d8b1f1920cf3493a555
1239
1240 define Download/brcmsmac
1241 FILE:=$(PKG_BRCMSMAC_FW_SOURCE)
1242 URL:=$(PKG_BRCMSMAC_FW_SOURCE_URL)
1243 MD5SUM:=$(PKG_BRCMSMAC_FW_MD5SUM)
1244 endef
1245 $(eval $(call Download,brcmsmac))
1246
1247 define KernelPackage/brcmsmac
1248 $(call KernelPackage/mac80211/Default)
1249 TITLE:=Broadcom IEEE802.11n PCIe SoftMAC WLAN driver
1250 URL:=http://linuxwireless.org/en/users/Drivers/brcm80211
1251 DEPENDS+= +kmod-mac80211 +@DRIVER_11N_SUPPORT +!TARGET_brcm47xx:kmod-bcma +kmod-lib-cordic +kmod-lib-crc8 +kmod-brcmutil
1252 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/brcm80211/brcmsmac/brcmsmac.ko
1253 AUTOLOAD:=$(call AutoProbe,brcmsmac)
1254 MENU:=1
1255 endef
1256
1257 define KernelPackage/brcmsmac/description
1258 Kernel module for Broadcom IEEE802.11n PCIe Wireless cards
1259 endef
1260
1261 define KernelPackage/brcmsmac/config
1262 if PACKAGE_kmod-brcmsmac
1263
1264 config BRCMSMAC_USE_FW_FROM_WL
1265 bool "Use firmware extracted from broadcom proprietary driver"
1266 default y
1267 help
1268 Instead of using the official brcmsmac firmware a firmware
1269 version 666.2 extracted from the proprietary Broadcom driver
1270 is used. This is needed to get core rev 17 used in bcm4716
1271 to work.
1272
1273 If unsure, say Y.
1274
1275 endif
1276 endef
1277
1278
1279 define KernelPackage/brcmfmac
1280 $(call KernelPackage/mac80211/Default)
1281 TITLE:=Broadcom IEEE802.11n USB FullMAC WLAN driver
1282 URL:=http://linuxwireless.org/en/users/Drivers/brcm80211
1283 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-cfg80211 +@DRIVER_11N_SUPPORT +kmod-brcmutil
1284 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/brcm80211/brcmfmac/brcmfmac.ko
1285 AUTOLOAD:=$(call AutoProbe,brcmfmac)
1286 endef
1287
1288 define KernelPackage/brcmfmac/description
1289 Kernel module for Broadcom IEEE802.11n USB Wireless cards
1290 endef
1291
1292 config_package=$(if $(CONFIG_PACKAGE_kmod-$(1)),m)
1293
1294 config-y:= \
1295 WLAN \
1296 NL80211_TESTMODE \
1297 CFG80211_WEXT \
1298 CFG80211_INTERNAL_REGDB \
1299 MAC80211_RC_MINSTREL \
1300 MAC80211_RC_MINSTREL_HT \
1301 MAC80211_RC_DEFAULT_MINSTREL \
1302
1303 config-$(call config_package,cfg80211) += CFG80211
1304
1305 config-$(call config_package,mac80211) += MAC80211
1306 config-$(CONFIG_PACKAGE_MAC80211_MESH) += MAC80211_MESH
1307 ifdef CONFIG_PACKAGE_MAC80211_DEBUGFS
1308 config-y += \
1309 CFG80211_DEBUGFS \
1310 MAC80211_DEBUGFS \
1311 ATH9K_DEBUGFS \
1312 ATH9K_HTC_DEBUGFS \
1313 ATH10K_DEBUGFS \
1314 CARL9170_DEBUGFS \
1315 ATH5K_DEBUG
1316 endif
1317
1318 config-$(call config_package,lib80211) += LIB80211 LIB80211_CRYPT_WEP LIB80211_CRYPT_CCMP LIB80211_CRYPT_TKIP
1319
1320 config-$(call config_package,ath) += ATH_CARDS ATH_COMMON
1321 config-$(CONFIG_PACKAGE_ATH_DEBUG) += ATH_DEBUG ATH10K_DEBUG
1322
1323 config-$(call config_package,ath9k) += ATH9K
1324 config-$(call config_package,ath9k-common) += ATH9K_COMMON
1325 config-$(CONFIG_TARGET_ar71xx) += ATH9K_AHB
1326 config-$(CONFIG_PCI) += ATH9K_PCI
1327 config-$(CONFIG_ATH_USER_REGD) += ATH_USER_REGD
1328
1329 config-$(call config_package,ath9k-htc) += ATH9K_HTC
1330 config-$(call config_package,ath10k) += ATH10K ATH10K_PCI
1331
1332 config-$(call config_package,ath5k) += ATH5K
1333 ifdef CONFIG_TARGET_atheros
1334 config-y += ATH5K_AHB
1335 else
1336 config-y += ATH5K_PCI
1337 endif
1338
1339 config-$(call config_package,carl9170) += CARL9170
1340
1341 config-$(call config_package,b43) += B43
1342 config-y += B43_SSB B43_BCMA B43_PHY_LP
1343 config-$(CONFIG_PACKAGE_B43_PHY_N) += B43_PHY_N
1344 config-$(CONFIG_PACKAGE_B43_PHY_HT) += B43_PHY_HT
1345 config-$(CONFIG_PACKAGE_B43_PIO) += B43_PIO
1346 config-$(CONFIG_PACKAGE_B43_DEBUG) += B43_DEBUG
1347
1348 config-$(call config_package,b43legacy) += B43LEGACY
1349 config-y += B43LEGACY_DMA_MODE
1350
1351 config-$(call config_package,brcmutil) += BRCMUTIL
1352 config-$(call config_package,brcmsmac) += BRCMSMAC
1353 config-$(call config_package,brcmfmac) += BRCMFMAC
1354 config-y += BRCMFMAC_USB
1355 config-$(CONFIG_PACKAGE_BRCM80211_DEBUG) += BRCMDBG
1356
1357 config-$(call config_package,mac80211-hwsim) += MAC80211_HWSIM
1358
1359 config-$(call config_package,rt2x00-lib) += RT2X00 RT2X00_LIB
1360 config-$(call config_package,rt2x00-pci) += RT2X00_LIB_PCI
1361 config-$(call config_package,rt2x00-mmio) += RT2X00_LIB_MMIO
1362 config-$(call config_package,rt2x00-usb) += RT2X00_LIB_USB
1363 config-$(call config_package,rt2x00-soc) += RT2X00_LIB_SOC
1364 config-$(CONFIG_PACKAGE_RT2X00_LIB_DEBUGFS) += RT2X00_LIB_DEBUGFS
1365 config-$(CONFIG_PACKAGE_RT2X00_DEBUG) += RT2X00_DEBUG
1366
1367 config-$(call config_package,rt2400-pci) += RT2400PCI
1368 config-$(call config_package,rt2500-pci) += RT2500PCI
1369 config-$(call config_package,rt2500-usb) += RT2500USB
1370 config-$(call config_package,rt61-pci) += RT61PCI
1371 config-$(call config_package,rt73-usb) += RT73USB
1372
1373 config-$(call config_package,rt2800-lib) += RT2800_LIB
1374
1375 config-$(call config_package,rt2800-pci) += RT2800PCI
1376 config-y += RT2800PCI_RT33XX RT2800PCI_RT35XX RT2800PCI_RT53XX RT2800PCI_RT3290
1377
1378 config-$(call config_package,rt2800-usb) += RT2800USB
1379 config-y += RT2800USB_RT33XX RT2800USB_RT35XX RT2800USB_RT3573 RT2800USB_RT53XX RT2800USB_RT55XX
1380
1381 config-$(call config_package,iwl-legacy) += IWLEGACY
1382 config-$(call config_package,iwl3945) += IWL3945
1383 config-$(call config_package,iwl4965) += IWL4965
1384 config-$(call config_package,iwlagn) += IWLWIFI IWLDVM
1385
1386 config-$(call config_package,net-libipw) += LIBIPW
1387 config-$(call config_package,net-ipw2100) += IPW2100
1388 config-$(call config_package,net-ipw2200) += IPW2200
1389
1390 config-$(call config_package,p54-common) += P54_COMMON
1391 config-$(call config_package,p54-pci) += P54_PCI
1392 config-$(call config_package,p54-usb) += P54_USB
1393 config-$(call config_package,p54-spi) += P54_SPI
1394
1395 config-$(call config_package,net-hermes) += HERMES
1396 config-$(call config_package,net-hermes-pci) += PCI_HERMES
1397 config-$(call config_package,net-hermes-plx) += PLX_HERMES
1398 config-$(call config_package,net-hermes-pcmcia) += PCMCIA_HERMES
1399 config-y += HERMES_PRISM
1400
1401 config-$(call config_package,adm8211) += ADM8211
1402 config-$(call config_package,libertas-sd) += LIBERTAS LIBERTAS_SDIO
1403 config-$(call config_package,libertas-usb) += LIBERTAS LIBERTAS_USB
1404 config-$(call config_package,mwl8k) += MWL8K
1405 config-$(call config_package,rtl8180) += RTL8180
1406 config-$(call config_package,rtl8187) += RTL8187
1407 config-$(call config_package,wl12xx) += WLCORE WLCORE_SDIO WL12XX
1408 config-y += WL_TI
1409 config-$(call config_package,zd1211rw) += ZD1211RW
1410
1411 config-$(call config_package,rtlwifi) += RTL_CARDS RTLWIFI
1412 config-$(call config_package,rtlwifi-pci) += RTLWIFI_PCI
1413 config-$(call config_package,rtlwifi-usb) += RTLWIFI_USB
1414 config-$(call config_package,rtl8192c-common) += RTL8192C_COMMON
1415 config-$(call config_package,rtl8192ce) += RTL8192CE
1416 config-$(call config_package,rtl8192se) += RTL8192SE
1417 config-$(call config_package,rtl8192de) += RTL8192DE
1418 config-$(call config_package,rtl8192cu) += RTL8192CU
1419 config-$(CONFIG_PACKAGE_RTLWIFI_DEBUG) += RTLWIFI_DEBUG
1420
1421 config-$(CONFIG_LEDS_TRIGGERS) += MAC80211_LEDS B43_LEDS B43LEGACY_LEDS
1422
1423 MAKE_OPTS:= -C "$(PKG_BUILD_DIR)" \
1424 CROSS_COMPILE="$(KERNEL_CROSS)" \
1425 ARCH="$(LINUX_KARCH)" \
1426 EXTRA_CFLAGS="-I$(PKG_BUILD_DIR)/include" \
1427 KLIB_BUILD="$(LINUX_DIR)" \
1428 MODPROBE=true \
1429 KLIB=$(TARGET_MODULES_DIR) \
1430 KERNEL_SUBLEVEL=$(lastword $(subst ., ,$(KERNEL_PATCHVER))) \
1431 KBUILD_LDFLAGS_MODULE_PREREQ=
1432
1433 ifneq ($(findstring c,$(OPENWRT_VERBOSE)),)
1434 MAKE_OPTS += V=1
1435 endif
1436
1437 define ConfigVars
1438 $(subst $(space),,$(foreach opt,$(config-$(1)),CPTCFG_$(opt)=$(1)
1439 ))
1440 endef
1441
1442 define mac80211_config
1443 $(call ConfigVars,m)$(call ConfigVars,y)
1444 endef
1445 $(eval $(call shexport,mac80211_config))
1446
1447 define Build/Prepare
1448 rm -rf $(PKG_BUILD_DIR)
1449 mkdir -p $(PKG_BUILD_DIR)
1450 $(PKG_UNPACK)
1451 $(Build/Patch)
1452 $(TAR) -C $(PKG_BUILD_DIR) -xzf $(DL_DIR)/$(IPW2100_NAME)-$(IPW2100_VERSION).tgz
1453 $(TAR) -C $(PKG_BUILD_DIR) -xzf $(DL_DIR)/$(IPW2200_NAME)-$(IPW2200_VERSION).tgz
1454 $(TAR) -C $(PKG_BUILD_DIR) -xjf $(DL_DIR)/$(ZD1211FW_NAME)-$(ZD1211FW_VERSION).tar.bz2
1455 $(TAR) -C $(PKG_BUILD_DIR) -xjf $(DL_DIR)/$(PKG_LINUX_FIRMWARE_SOURCE)
1456 $(TAR) -C $(PKG_BUILD_DIR) -xjf $(DL_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SOURCE)
1457 rm -rf \
1458 $(PKG_BUILD_DIR)/include/linux/ssb \
1459 $(PKG_BUILD_DIR)/include/linux/bcma \
1460 $(PKG_BUILD_DIR)/include/net/bluetooth
1461
1462 rm -f \
1463 $(PKG_BUILD_DIR)/include/linux/cordic.h \
1464 $(PKG_BUILD_DIR)/include/linux/crc8.h \
1465 $(PKG_BUILD_DIR)/include/linux/eeprom_93cx6.h \
1466 $(PKG_BUILD_DIR)/include/linux/wl12xx.h \
1467 $(PKG_BUILD_DIR)/include/linux/spi/libertas_spi.h \
1468 $(PKG_BUILD_DIR)/include/net/ieee80211.h
1469
1470 echo 'compat-wireless-$(PKG_VERSION)-$(PKG_RELEASE)-$(REVISION)' > $(PKG_BUILD_DIR)/compat_version
1471 $(CP) ./files/regdb.txt $(PKG_BUILD_DIR)/net/wireless/db.txt
1472 endef
1473
1474 ifneq ($(CONFIG_PACKAGE_kmod-cfg80211)$(CONFIG_PACKAGE_kmod-lib80211),)
1475 define Build/Compile/kmod
1476 rm -rf $(PKG_BUILD_DIR)/modules
1477 +$(MAKE) $(PKG_JOBS) $(MAKE_OPTS) modules
1478 endef
1479 endif
1480
1481 define Build/Configure
1482 cmp $(PKG_BUILD_DIR)/include/linux/ath9k_platform.h $(LINUX_DIR)/include/linux/ath9k_platform.h
1483 cmp $(PKG_BUILD_DIR)/include/linux/ath5k_platform.h $(LINUX_DIR)/include/linux/ath5k_platform.h
1484 cmp $(PKG_BUILD_DIR)/include/linux/rt2x00_platform.h $(LINUX_DIR)/include/linux/rt2x00_platform.h
1485 endef
1486
1487 define Build/Compile
1488 $(SH_FUNC) var2file "$(call shvar,mac80211_config)" $(PKG_BUILD_DIR)/.config
1489 $(MAKE) $(MAKE_OPTS) allnoconfig
1490 $(call Build/Compile/kmod)
1491 endef
1492
1493 define Build/InstallDev
1494 mkdir -p \
1495 $(1)/usr/include/mac80211 \
1496 $(1)/usr/include/mac80211-backport \
1497 $(1)/usr/include/mac80211/ath \
1498 $(1)/usr/include/net/mac80211
1499 $(CP) $(PKG_BUILD_DIR)/net/mac80211/*.h $(PKG_BUILD_DIR)/include/* $(1)/usr/include/mac80211/
1500 $(CP) $(PKG_BUILD_DIR)/backport-include/* $(1)/usr/include/mac80211-backport/
1501 $(CP) $(PKG_BUILD_DIR)/net/mac80211/rate.h $(1)/usr/include/net/mac80211/
1502 $(CP) $(PKG_BUILD_DIR)/drivers/net/wireless/ath/*.h $(1)/usr/include/mac80211/ath/
1503 endef
1504
1505 define KernelPackage/libertas-usb/install
1506 $(INSTALL_DIR) $(1)/lib/firmware/libertas
1507 $(INSTALL_DATA) \
1508 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/usb8388_v9.bin \
1509 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/usb8682.bin \
1510 $(1)/lib/firmware/libertas/
1511 endef
1512
1513 define KernelPackage/libertas-sd/install
1514 $(INSTALL_DIR) $(1)/lib/firmware/libertas
1515 $(INSTALL_DATA) \
1516 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8385_helper.bin \
1517 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8385.bin \
1518 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8686_v9_helper.bin \
1519 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8686_v9.bin \
1520 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8688_helper.bin \
1521 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/libertas/sd8688.bin \
1522 $(1)/lib/firmware/libertas
1523 endef
1524
1525 define KernelPackage/cfg80211/install
1526 $(INSTALL_DIR) $(1)/lib/wifi
1527 $(INSTALL_DATA) ./files/lib/wifi/mac80211.sh $(1)/lib/wifi
1528 endef
1529
1530 define KernelPackage/p54-pci/install
1531 $(INSTALL_DIR) $(1)/lib/firmware
1532 $(INSTALL_DATA) $(DL_DIR)/$(P54PCIFW) $(1)/lib/firmware/isl3886pci
1533 endef
1534
1535 define KernelPackage/p54-usb/install
1536 $(INSTALL_DIR) $(1)/lib/firmware
1537 $(INSTALL_DATA) $(DL_DIR)/$(P54USBFW) $(1)/lib/firmware/isl3887usb
1538 endef
1539
1540 define KernelPackage/p54-spi/install
1541 $(INSTALL_DIR) $(1)/lib/firmware
1542 $(INSTALL_DATA) $(DL_DIR)/$(P54SPIFW) $(1)/lib/firmware/3826.arm
1543 endef
1544
1545 define KernelPackage/rt61-pci/install
1546 $(INSTALL_DIR) $(1)/lib/firmware
1547 $(INSTALL_DATA) \
1548 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt2561.bin \
1549 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt2561s.bin \
1550 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt2661.bin \
1551 $(1)/lib/firmware/
1552 endef
1553
1554 define KernelPackage/rt73-usb/install
1555 $(INSTALL_DIR) $(1)/lib/firmware
1556 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt73.bin $(1)/lib/firmware/
1557 endef
1558
1559 define KernelPackage/rt2800-pci/install
1560 $(INSTALL_DIR) $(1)/lib/firmware
1561 $(INSTALL_DATA) \
1562 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt2860.bin \
1563 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt3290.bin \
1564 $(1)/lib/firmware
1565 endef
1566
1567 define KernelPackage/rt2800-usb/install
1568 $(INSTALL_DIR) $(1)/lib/firmware
1569 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/rt2870.bin $(1)/lib/firmware/
1570 endef
1571
1572 define KernelPackage/wl12xx/install
1573 $(INSTALL_DIR) $(1)/lib/firmware/ti-connectivity
1574 $(INSTALL_DATA) \
1575 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/ti-connectivity/wl127x-fw-5-mr.bin \
1576 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/ti-connectivity/wl127x-fw-5-plt.bin \
1577 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/ti-connectivity/wl127x-fw-5-sr.bin \
1578 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/ti-connectivity/wl1271-nvs.bin \
1579 $(1)/lib/firmware/ti-connectivity
1580 endef
1581
1582
1583 define KernelPackage/zd1211rw/install
1584 $(INSTALL_DIR) $(1)/lib/firmware/zd1211
1585 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(ZD1211FW_NAME)/zd1211* $(1)/lib/firmware/zd1211
1586 endef
1587
1588 define KernelPackage/carl9170/install
1589 $(INSTALL_DIR) $(1)/lib/firmware
1590 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/carl9170-1.fw $(1)/lib/firmware
1591 endef
1592
1593 define KernelPackage/ath9k-htc/install
1594 $(INSTALL_DIR) $(1)/lib/firmware
1595 $(INSTALL_DATA) \
1596 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/htc_9271.fw \
1597 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/htc_7010.fw \
1598 $(1)/lib/firmware/
1599 endef
1600
1601 define KernelPackage/ath10k/install
1602 $(INSTALL_DIR) $(1)/lib/firmware/ath10k/QCA988X/hw2.0
1603 $(INSTALL_DATA) \
1604 $(PKG_BUILD_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)/ath10k/QCA988X/hw2.0/board.bin \
1605 $(PKG_BUILD_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)/ath10k/QCA988X/hw2.0/firmware.bin \
1606 $(PKG_BUILD_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)/ath10k/QCA988X/hw2.0/otp.bin \
1607 $(1)/lib/firmware/ath10k/QCA988X/hw2.0/
1608 endef
1609
1610 define KernelPackage/mwl8k/install
1611 $(INSTALL_DIR) $(1)/lib/firmware/mwl8k
1612 $(INSTALL_DATA) \
1613 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/mwl8k/fmimage_8366_ap-3.fw \
1614 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/mwl8k/fmimage_8366.fw \
1615 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/mwl8k/helper_8366.fw \
1616 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/mwl8k/fmimage_8687.fw \
1617 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/mwl8k/helper_8687.fw \
1618 $(1)/lib/firmware/mwl8k/
1619 endef
1620
1621 define KernelPackage/net-ipw2100/install
1622 $(INSTALL_DIR) $(1)/lib/firmware
1623 $(INSTALL_DATA) $(PKG_BUILD_DIR)/ipw2100-$(IPW2100_VERSION)*.fw $(1)/lib/firmware
1624 endef
1625
1626 define KernelPackage/net-ipw2200/install
1627 $(INSTALL_DIR) $(1)/lib/firmware
1628 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(IPW2200_NAME)-$(IPW2200_VERSION)/ipw2200*.fw $(1)/lib/firmware
1629 endef
1630
1631 define KernelPackage/iwlagn/install
1632 $(INSTALL_DIR) $(1)/lib/firmware
1633 ifneq ($(CONFIG_IWL5000_FW),)
1634 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-5000-5.ucode $(1)/lib/firmware
1635 endif
1636 ifneq ($(CONFIG_IWL5150_FW),)
1637 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-5150-2.ucode $(1)/lib/firmware
1638 endif
1639 ifneq ($(CONFIG_IWL1000_FW),)
1640 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-1000-5.ucode $(1)/lib/firmware
1641 endif
1642 ifneq ($(CONFIG_IWL6000_FW),)
1643 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-6000-4.ucode $(1)/lib/firmware
1644 endif
1645 ifneq ($(CONFIG_IWL6050_FW),)
1646 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-6050-5.ucode $(1)/lib/firmware
1647 endif
1648 ifneq ($(CONFIG_IWL6005_FW),)
1649 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-6000g2a-6.ucode $(1)/lib/firmware
1650 endif
1651 ifneq ($(CONFIG_IWL6030_FW),)
1652 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-6000g2b-6.ucode $(1)/lib/firmware
1653 endif
1654 ifneq ($(CONFIG_IWL100_FW),)
1655 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-100-5.ucode $(1)/lib/firmware
1656 endif
1657 ifneq ($(CONFIG_IWL2000_FW),)
1658 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-2000-6.ucode $(1)/lib/firmware
1659 endif
1660 ifneq ($(CONFIG_IWL2030_FW),)
1661 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-2030-6.ucode $(1)/lib/firmware
1662 endif
1663 ifneq ($(CONFIG_IWL105_FW),)
1664 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-105-6.ucode $(1)/lib/firmware
1665 endif
1666 ifneq ($(CONFIG_IWL135_FW),)
1667 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-135-6.ucode $(1)/lib/firmware
1668 endif
1669 endef
1670
1671 define KernelPackage/iwl3945/install
1672 $(INSTALL_DIR) $(1)/lib/firmware
1673 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-3945-2.ucode $(1)/lib/firmware
1674 endef
1675
1676 define KernelPackage/iwl4965/install
1677 $(INSTALL_DIR) $(1)/lib/firmware
1678 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/iwlwifi-4965-2.ucode $(1)/lib/firmware
1679 endef
1680
1681 define KernelPackage/b43/install
1682 rm -rf $(1)/lib/firmware/
1683 ifeq ($(CONFIG_B43_OPENFIRMWARE),y)
1684 tar xzf "$(DL_DIR)/$(PKG_B43_FWV4_SOURCE)" -C "$(PKG_BUILD_DIR)"
1685 else
1686 tar xjf "$(DL_DIR)/$(PKG_B43_FWV4_SOURCE)" -C "$(PKG_BUILD_DIR)"
1687 endif
1688 $(INSTALL_DIR) $(1)/lib/firmware/
1689 ifeq ($(CONFIG_B43_OPENFIRMWARE),y)
1690 $(MAKE) -C "$(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/"
1691 $(INSTALL_DIR) $(1)/lib/firmware/b43-open/
1692 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/ucode5.fw $(1)/lib/firmware/b43-open/ucode5.fw
1693 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/b0g0bsinitvals5.fw $(1)/lib/firmware/b43-open/b0g0bsinitvals5.fw
1694 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/b0g0initvals5.fw $(1)/lib/firmware/b43-open/b0g0initvals5.fw
1695 else
1696 b43-fwcutter -w $(1)/lib/firmware/ $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)
1697 endif
1698 ifneq ($(CONFIG_B43_FW_SQUASH),)
1699 b43-fwsquash.py "$(CONFIG_B43_FW_SQUASH_PHYTYPES)" "$(CONFIG_B43_FW_SQUASH_COREREVS)" "$(1)/lib/firmware/b43"
1700 endif
1701 endef
1702
1703 define KernelPackage/b43legacy/install
1704 $(INSTALL_DIR) $(1)/lib/firmware/
1705 b43-fwcutter --unsupported -w $(1)/lib/firmware/ $(DL_DIR)/$(PKG_B43_FWV3_SOURCE)
1706 ifneq ($(CONFIG_B43LEGACY_FW_SQUASH),)
1707 b43-fwsquash.py "G" "$(CONFIG_B43LEGACY_FW_SQUASH_COREREVS)" "$(1)/lib/firmware/b43legacy"
1708 endif
1709 endef
1710
1711 define KernelPackage/brcmsmac/install
1712 $(INSTALL_DIR) $(1)/lib/firmware/brcm
1713 ifeq ($(CONFIG_BRCMSMAC_USE_FW_FROM_WL),y)
1714 tar xjf "$(DL_DIR)/$(PKG_BRCMSMAC_FW_SOURCE)" -C "$(PKG_BUILD_DIR)"
1715 b43-fwcutter --brcmsmac -w $(1)/lib/firmware/ $(PKG_BUILD_DIR)/$(PKG_BRCMSMAC_FW_OBJECT)
1716 else
1717 $(INSTALL_DATA) \
1718 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/brcm/bcm43xx-0.fw \
1719 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/brcm/bcm43xx_hdr-0.fw \
1720 $(1)/lib/firmware/brcm/
1721 endif
1722 endef
1723
1724 define KernelPackage/brcmfmac/install
1725 $(INSTALL_DIR) $(1)/lib/firmware/brcm
1726 $(INSTALL_DATA) \
1727 $(PKG_BUILD_DIR)/$(PKG_LINUX_FIRMWARE_SUBDIR)/brcm/brcmfmac43236b.bin \
1728 $(1)/lib/firmware/brcm/
1729 endef
1730
1731 $(eval $(call KernelPackage,adm8211))
1732 $(eval $(call KernelPackage,ath5k))
1733 $(eval $(call KernelPackage,lib80211))
1734 $(eval $(call KernelPackage,libertas-usb))
1735 $(eval $(call KernelPackage,libertas-sd))
1736 $(eval $(call KernelPackage,cfg80211))
1737 $(eval $(call KernelPackage,mac80211))
1738 $(eval $(call KernelPackage,p54-common))
1739 $(eval $(call KernelPackage,p54-pci))
1740 $(eval $(call KernelPackage,p54-usb))
1741 $(eval $(call KernelPackage,p54-spi))
1742 $(eval $(call KernelPackage,rt2x00-lib))
1743 $(eval $(call KernelPackage,rt2x00-mmio))
1744 $(eval $(call KernelPackage,rt2x00-pci))
1745 $(eval $(call KernelPackage,rt2x00-usb))
1746 $(eval $(call KernelPackage,rt2x00-soc))
1747 $(eval $(call KernelPackage,rt2800-lib))
1748 $(eval $(call KernelPackage,rt2400-pci))
1749 $(eval $(call KernelPackage,rt2500-pci))
1750 $(eval $(call KernelPackage,rt2500-usb))
1751 $(eval $(call KernelPackage,rt61-pci))
1752 $(eval $(call KernelPackage,rt73-usb))
1753 $(eval $(call KernelPackage,rt2800-pci))
1754 $(eval $(call KernelPackage,rt2800-usb))
1755 $(eval $(call KernelPackage,rtl8180))
1756 $(eval $(call KernelPackage,rtl8187))
1757 $(eval $(call KernelPackage,rtlwifi))
1758 $(eval $(call KernelPackage,rtlwifi-pci))
1759 $(eval $(call KernelPackage,rtlwifi-usb))
1760 $(eval $(call KernelPackage,rtl8192c-common))
1761 $(eval $(call KernelPackage,rtl8192ce))
1762 $(eval $(call KernelPackage,rtl8192se))
1763 $(eval $(call KernelPackage,rtl8192de))
1764 $(eval $(call KernelPackage,rtl8192cu))
1765 $(eval $(call KernelPackage,zd1211rw))
1766 $(eval $(call KernelPackage,mac80211-hwsim))
1767 $(eval $(call KernelPackage,ath9k-common))
1768 $(eval $(call KernelPackage,ath9k))
1769 $(eval $(call KernelPackage,ath9k-htc))
1770 $(eval $(call KernelPackage,ath10k))
1771 $(eval $(call KernelPackage,ath))
1772 $(eval $(call KernelPackage,carl9170))
1773 $(eval $(call KernelPackage,b43))
1774 $(eval $(call KernelPackage,b43legacy))
1775 $(eval $(call KernelPackage,brcmutil))
1776 $(eval $(call KernelPackage,brcmsmac))
1777 $(eval $(call KernelPackage,brcmfmac))
1778 $(eval $(call KernelPackage,net-libipw))
1779 $(eval $(call KernelPackage,net-ipw2100))
1780 $(eval $(call KernelPackage,net-ipw2200))
1781 $(eval $(call KernelPackage,iwlagn))
1782 $(eval $(call KernelPackage,iwl-legacy))
1783 $(eval $(call KernelPackage,iwl4965))
1784 $(eval $(call KernelPackage,iwl3945))
1785 $(eval $(call KernelPackage,mwl8k))
1786 $(eval $(call KernelPackage,net-hermes))
1787 $(eval $(call KernelPackage,net-hermes-pci))
1788 $(eval $(call KernelPackage,net-hermes-plx))
1789 $(eval $(call KernelPackage,net-hermes-pcmcia))
1790 $(eval $(call KernelPackage,wl12xx))