[package] mac80211: backport ath9k uninline patch
[openwrt.git] / package / mac80211 / Makefile
1 #
2 # Copyright (C) 2007-2009 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 ifneq ($(CONFIG_LINUX_2_6_21)$(CONFIG_LINUX_2_6_23)$(CONFIG_LINUX_2_6_24)$(CONFIG_LINUX_2_6_25)$(CONFIG_LINUX_2_6_26),)
14 PKG_VERSION:=2008-08-06
15 PKG_RELEASE:=2
16 PKG_SOURCE_URL:=http://www.orbit-lab.org/kernel/compat-wireless-2.6/2008/08
17 PKG_MD5SUM:=9563ceeed86bca0859ad5f010623277c
18 PATCH_DIR:=./patches-old
19 else
20 PKG_VERSION:=2009-03-31
21 PKG_RELEASE:=2
22 PKG_SOURCE_URL:= \
23 http://www.orbit-lab.org/kernel/compat-wireless-2.6/2009/03 \
24 http://wireless.kernel.org/download/compat-wireless-2.6
25 PKG_MD5SUM:=b5b2159081c36dd6c318a28eddf7e646
26 endif
27
28 PKG_SOURCE:=compat-wireless-$(PKG_VERSION).tar.bz2
29 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/compat-wireless-$(PKG_VERSION)
30
31 PKG_CONFIG_DEPENDS:= \
32 CONFIG_PACKAGE_kmod-mac80211 \
33
34 include $(INCLUDE_DIR)/package.mk
35
36 WMENU:=Wireless Drivers
37
38 define KernelPackage/mac80211/Default
39 SUBMENU:=$(WMENU)
40 URL:=http://linuxwireless.org/
41 DEPENDS:=@LINUX_2_6 @!TARGET_avr32
42 endef
43
44 define KernelPackage/mac80211
45 $(call KernelPackage/mac80211/Default)
46 TITLE:=Linux 802.11 Wireless Networking Stack
47 DEPENDS+= +kmod-crypto-arc4 +kmod-crypto-aes +wireless-tools
48 FILES:= \
49 $(PKG_BUILD_DIR)/net/mac80211/mac80211.$(LINUX_KMOD_SUFFIX) \
50 $(PKG_BUILD_DIR)/net/wireless/cfg80211.$(LINUX_KMOD_SUFFIX)
51 AUTOLOAD:=$(call AutoLoad,20,cfg80211 mac80211)
52 endef
53
54 define KernelPackage/mac80211/description
55 Linux 802.11 Wireless Networking Stack
56 endef
57
58 # Prism54 drivers
59 P54PCIFW:=2.13.12.0.arm
60 P54USBFW:=2.13.24.0.lm86.arm
61
62 define Download/p54usb
63 FILE:=$(P54USBFW)
64 URL:=http://daemonizer.de/prism54/prism54-fw/fw-usb
65 MD5SUM:=2efd50eab43c0d0376765576a54b7a30
66 endef
67 $(eval $(call Download,p54usb))
68
69 define Download/p54pci
70 FILE:=$(P54PCIFW)
71 URL:=http://daemonizer.de/prism54/prism54-fw/fw-softmac
72 MD5SUM:=ff7536af2092b1c4b21315bd103ef4c4
73 endef
74 $(eval $(call Download,p54pci))
75
76 define KernelPackage/p54/Default
77 $(call KernelPackage/mac80211/Default)
78 TITLE:=Prism54 Drivers
79 endef
80
81 define KernelPackage/p54/description
82 Kernel module for Prism54 chipsets (mac80211)
83 endef
84
85 define KernelPackage/p54-common
86 $(call KernelPackage/p54/Default)
87 DEPENDS+= @PCI_SUPPORT||@USB_SUPPORT +kmod-mac80211
88 TITLE+= (COMMON)
89 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54common.$(LINUX_KMOD_SUFFIX)
90 AUTOLOAD:=$(call AutoLoad,30,p54common)
91 endef
92
93 define KernelPackage/p54-pci
94 $(call KernelPackage/p54/Default)
95 TITLE+= (PCI)
96 DEPENDS+= @PCI_SUPPORT +kmod-p54-common
97 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54pci.$(LINUX_KMOD_SUFFIX)
98 AUTOLOAD:=$(call AutoLoad,31,p54pci)
99 endef
100
101 define KernelPackage/p54-usb
102 $(call KernelPackage/p54/Default)
103 TITLE+= (USB)
104 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-p54-common
105 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/p54/p54usb.$(LINUX_KMOD_SUFFIX)
106 AUTOLOAD:=$(call AutoLoad,31,p54usb)
107 endef
108
109 # Ralink rt2x00 drivers
110 RT61FW:=RT61_Firmware_V1.2.zip
111 RT71FW:=RT71W_Firmware_V1.8.zip
112 RT2860FW:=RT2860_Firmware_V11.zip
113
114 define Download/rt61
115 FILE:=$(RT61FW)
116 URL:=http://www.ralinktech.com.tw/data/
117 MD5SUM:=d4c690c93b470bc9a681297c2adc6281
118 endef
119 $(eval $(call Download,rt61))
120
121 define Download/rt71w
122 FILE:=$(RT71FW)
123 URL:=http://www.ralinktech.com.tw/data/
124 MD5SUM:=1e7a5dc574e0268574fcda3fd5cf52f7
125 endef
126 $(eval $(call Download,rt71w))
127
128 define Download/rt2860
129 FILE:=$(RT2860FW)
130 URL:=http://www.ralinktech.com.tw/data/drivers
131 MD5SUM:=440a81756a52c53528f16faa41c40124
132 endef
133 $(eval $(call Download,rt2860))
134
135 define KernelPackage/rt2x00/Default
136 $(call KernelPackage/mac80211/Default)
137 TITLE:=Ralink Drivers for RT2x00 cards
138 endef
139
140 define KernelPackage/rt2x00-lib
141 $(call KernelPackage/rt2x00/Default)
142 DEPENDS+= @PCI_SUPPORT||@USB_SUPPORT +kmod-mac80211 +kmod-crc-itu-t
143 TITLE+= (LIB)
144 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00lib.$(LINUX_KMOD_SUFFIX)
145 AUTOLOAD:=$(call AutoLoad,25,blkcipher ecb arc4 rt2x00lib)
146 endef
147
148 define KernelPackage/rt2x00-pci
149 $(call KernelPackage/rt2x00/Default)
150 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-lib +kmod-eeprom-93cx6
151 TITLE+= (PCI)
152 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00pci.$(LINUX_KMOD_SUFFIX)
153 AUTOLOAD:=$(call AutoLoad,26,rt2x00pci)
154 endef
155
156 define KernelPackage/rt2x00-usb
157 $(call KernelPackage/rt2x00/Default)
158 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-lib +kmod-usb-core
159 TITLE+= (USB)
160 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2x00usb.$(LINUX_KMOD_SUFFIX)
161 AUTOLOAD:=$(call AutoLoad,26,rt2x00usb)
162 endef
163
164 define KernelPackage/rt2400-pci
165 $(call KernelPackage/rt2x00/Default)
166 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
167 TITLE+= (RT2400 PCI)
168 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2400pci.$(LINUX_KMOD_SUFFIX)
169 AUTOLOAD:=$(call AutoLoad,27,rt2400pci)
170 endef
171
172 define KernelPackage/rt2500-pci
173 $(call KernelPackage/rt2x00/Default)
174 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
175 TITLE+= (RT2500 PCI)
176 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2500pci.$(LINUX_KMOD_SUFFIX)
177 AUTOLOAD:=$(call AutoLoad,27,rt2500pci)
178 endef
179
180 define KernelPackage/rt2500-usb
181 $(call KernelPackage/rt2x00/Default)
182 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-usb
183 TITLE+= (RT2500 USB)
184 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2500usb.$(LINUX_KMOD_SUFFIX)
185 AUTOLOAD:=$(call AutoLoad,27,rt2500usb)
186 endef
187
188 define KernelPackage/rt61-pci
189 $(call KernelPackage/rt2x00/Default)
190 DEPENDS+= @PCI_SUPPORT +kmod-rt2x00-pci
191 TITLE+= (RT2x61 PCI)
192 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt61pci.$(LINUX_KMOD_SUFFIX)
193 AUTOLOAD:=$(call AutoLoad,27,rt61pci)
194 endef
195
196 define KernelPackage/rt73-usb
197 $(call KernelPackage/rt2x00/Default)
198 DEPENDS+= @USB_SUPPORT +kmod-rt2x00-usb
199 TITLE+= (RT73 USB)
200 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt73usb.$(LINUX_KMOD_SUFFIX)
201 AUTOLOAD:=$(call AutoLoad,27,rt73usb)
202 endef
203
204 define KernelPackage/rt2800-pci
205 $(call KernelPackage/rt2x00/Default)
206 DEPENDS+= +kmod-rt2x00-pci +kmod-crc-ccitt @!LINUX_2_6_21||!LINUX_2_6_23||!LINUX_2_6_24||!LINUX_2_6_25||!LINUX_2_6_26
207 TITLE+= (RT2860 PCI)
208 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2800pci.$(LINUX_KMOD_SUFFIX)
209 AUTOLOAD:=$(call AutoLoad,27,rt2800pci)
210 endef
211
212 define KernelPackage/rt2800-usb
213 $(call KernelPackage/rt2x00/Default)
214 DEPENDS+= +kmod-rt2x00-usb +kmod-crc-ccitt @!LINUX_2_6_21||!LINUX_2_6_23||!LINUX_2_6_24||!LINUX_2_6_25||!LINUX_2_6_26
215 TITLE+= (RT2870 USB)
216 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/rt2x00/rt2800usb.$(LINUX_KMOD_SUFFIX)
217 AUTOLOAD:=$(call AutoLoad,27,rt2800usb)
218 endef
219
220 ZD1211FW_NAME:=zd1211-firmware
221 ZD1211FW_VERSION:=1.4
222 define Download/zd1211rw
223 FILE:=$(ZD1211FW_NAME)-$(ZD1211FW_VERSION).tar.bz2
224 URL:=@SF/zd1211/
225 MD5SUM:=19f28781d76569af8551c9d11294c870
226 endef
227 $(eval $(call Download,zd1211rw))
228
229 define KernelPackage/zd1211rw
230 $(call KernelPackage/mac80211/Default)
231 TITLE:=Zydas ZD1211 support
232 DEPENDS+= @USB_SUPPORT +kmod-usb-core +kmod-mac80211
233 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/zd1211rw/zd1211rw.$(LINUX_KMOD_SUFFIX)
234 AUTOLOAD:=$(call AutoLoad,60,zd1211rw)
235 endef
236
237 define KernelPackage/ath5k
238 $(call KernelPackage/mac80211/Default)
239 TITLE:=Atheros 5xxx wireless cards support
240 URL:=http://linuxwireless.org/en/users/Drivers/ath5k
241 DEPENDS+= @PCI_SUPPORT +kmod-mac80211
242 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath5k/ath5k.$(LINUX_KMOD_SUFFIX)
243 AUTOLOAD:=$(call AutoLoad,27,ath5k)
244 endef
245
246 define KernelPackage/ath5k/description
247 This module adds support for wireless adapters based on
248 Atheros 5xxx chipset.
249 endef
250
251 define KernelPackage/ath9k
252 $(call KernelPackage/mac80211/Default)
253 TITLE:=Atheros 802.11n wireless cards support
254 URL:=http://linuxwireless.org/en/users/Drivers/ath9k
255 DEPENDS+= @PCI_SUPPORT +kmod-mac80211 @!LINUX_2_6_21||!LINUX_2_6_23||!LINUX_2_6_24||!LINUX_2_6_25||!LINUX_2_6_26
256 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/ath9k/ath9k.$(LINUX_KMOD_SUFFIX)
257 AUTOLOAD:=$(call AutoLoad,27,ath9k)
258 endef
259
260 define KernelPackage/ath9k/description
261 This module adds support for wireless adapters based on
262 Atheros IEEE 802.11n AR5008 and AR9001 family of chipsets.
263 endef
264
265 define KernelPackage/mac80211-hwsim
266 $(call KernelPackage/mac80211/Default)
267 TITLE:=mac80211 HW simulation device
268 DEPENDS+= +kmod-mac80211
269 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/mac80211_hwsim.$(LINUX_KMOD_SUFFIX)
270 AUTOLOAD:=$(call AutoLoad,60,mac80211_hwsim)
271 endef
272
273 #Broadcom firmware
274 ifneq ($(CONFIG_B43_EXPERIMENTAL),)
275 PKG_B43_FWV4_NAME:=broadcom-wl
276 PKG_B43_FWV4_VERSION:=4.178.10.4
277 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/linux/wl.o
278 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION).tar.bz2
279 PKG_B43_FWV4_SOURCE_URL:=http://mirror2.openwrt.org/sources/
280 PKG_B43_FWV4_MD5SUM:=14477e8cbbb91b11896affac9b219fdb
281 else
282 PKG_B43_FWV4_NAME:=broadcom-wl
283 PKG_B43_FWV4_VERSION:=4.150.10.5
284 PKG_B43_FWV4_OBJECT:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION)/driver/wl_apsta_mimo.o
285 PKG_B43_FWV4_SOURCE:=$(PKG_B43_FWV4_NAME)-$(PKG_B43_FWV4_VERSION).tar.bz2
286 PKG_B43_FWV4_SOURCE_URL:=http://mirror2.openwrt.org/sources/
287 PKG_B43_FWV4_MD5SUM:=0c6ba9687114c6b598e8019e262d9a60
288 endif
289 ifneq ($(CONFIG_B43_OPENFIRMWARE),)
290 PKG_B43_FWV4_NAME:=broadcom-wl
291 PKG_B43_FWV4_VERSION:=5.1
292 PKG_B43_FWV4_OBJECT:=openfwwf-$(PKG_B43_FWV4_VERSION)
293 PKG_B43_FWV4_SOURCE:=openfwwf-$(PKG_B43_FWV4_VERSION).tar.gz
294 PKG_B43_FWV4_SOURCE_URL:=http://www.ing.unibs.it/openfwwf/firmware/
295 PKG_B43_FWV4_MD5SUM:=3510c133393bb4911c4aa35742cefcfd
296 endif
297
298
299 PKG_B43_FWV3_NAME:=wl_apsta
300 PKG_B43_FWV3_VERSION:=3.130.20.0
301 PKG_B43_FWV3_SOURCE:=$(PKG_B43_FWV3_NAME)-$(PKG_B43_FWV3_VERSION).o
302 PKG_B43_FWV3_SOURCE_URL:=http://downloads.openwrt.org/sources/
303 PKG_B43_FWV3_MD5SUM:=e08665c5c5b66beb9c3b2dd54aa80cb3
304
305 ifneq ($(CONFIG_B43_EXPERIMENTAL)$(CONFIG_B43_OPENFIRMWARE),)
306 PKG_B43_FWCUTTER_NAME:=b43-fwcutter
307 PKG_B43_FWCUTTER_VERSION:=3e69531aa65b8f664a0ab00dfc3e2eefeb0cb417
308 PKG_B43_FWCUTTER_SOURCE:=$(PKG_B43_FWCUTTER_NAME)-$(PKG_B43_FWCUTTER_VERSION).tar.bz2
309 PKG_B43_FWCUTTER_PROTO:=git
310 PKG_B43_FWCUTTER_SOURCE_URL:=http://git.bu3sch.de/git/b43-tools.git
311 PKG_B43_FWCUTTER_SUBDIR:=$(PKG_B43_FWCUTTER_NAME)-$(PKG_B43_FWCUTTER_VERSION)
312 PKG_B43_FWCUTTER_OBJECT:=$(PKG_B43_FWCUTTER_NAME)-$(PKG_B43_FWCUTTER_VERSION)/fwcutter/
313 else
314 PKG_B43_FWCUTTER_NAME:=b43-fwcutter
315 PKG_B43_FWCUTTER_VERSION:=011
316 PKG_B43_FWCUTTER_SOURCE:=$(PKG_B43_FWCUTTER_NAME)-$(PKG_B43_FWCUTTER_VERSION).tar.bz2
317 PKG_B43_FWCUTTER_PROTO:=default
318 PKG_B43_FWCUTTER_SOURCE_URL:=http://bu3sch.de/b43/fwcutter/
319 PKG_B43_FWCUTTER_MD5SUM:=3db2f4de85a459451f5b391cf67a8d44
320 PKG_B43_FWCUTTER_SUBDIR:=b43-fwcutter-$(PKG_B43_FWCUTTER_VERSION)
321 PKG_B43_FWCUTTER_OBJECT:=$(PKG_B43_FWCUTTER_NAME)-$(PKG_B43_FWCUTTER_VERSION)/
322 endif
323
324 define Download/b43-common
325 FILE:=$(PKG_B43_FWCUTTER_SOURCE)
326 URL:=$(PKG_B43_FWCUTTER_SOURCE_URL)
327 MD5SUM:=$(PKG_B43_FWCUTTER_MD5SUM)
328 PROTO:=$(PKG_B43_FWCUTTER_PROTO)
329 VERSION:=$(PKG_B43_FWCUTTER_VERSION)
330 SUBDIR:=$(PKG_B43_FWCUTTER_SUBDIR)
331 endef
332 $(eval $(call Download,b43-common))
333
334 define Download/b43
335 FILE:=$(PKG_B43_FWV4_SOURCE)
336 URL:=$(PKG_B43_FWV4_SOURCE_URL)
337 MD5SUM:=$(PKG_B43_FWV4_MD5SUM)
338 endef
339 $(eval $(call Download,b43))
340
341 define Download/b43legacy
342 FILE:=$(PKG_B43_FWV3_SOURCE)
343 URL:=$(PKG_B43_FWV3_SOURCE_URL)
344 MD5SUM:=$(PKG_B43_FWV3_MD5SUM)
345 endef
346 $(eval $(call Download,b43legacy))
347
348 define KernelPackage/b43-common
349 $(call KernelPackage/mac80211/Default)
350 TITLE:=Generic stuff for Broadcom wireless devices
351 URL:=http://linuxwireless.org/en/users/Drivers/b43
352 DEPENDS+= +kmod-mac80211 +!(TARGET_brcm47xx||TARGET_brcm63xx):kmod-ssb @!LINUX_2_6_21||!LINUX_2_6_23||!LINUX_2_6_24
353 endef
354
355 define KernelPackage/b43
356 $(call KernelPackage/b43-common)
357 TITLE:=Broadcom 43xx wireless support
358 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/b43/b43.$(LINUX_KMOD_SUFFIX)
359 AUTOLOAD:=$(call AutoLoad,30,b43)
360 endef
361
362 define KernelPackage/b43/config
363 source "$(SOURCE)/Config.in"
364 endef
365
366 define KernelPackage/b43/description
367 Kernel module for Broadcom 43xx wireless support (mac80211 stack) new
368 endef
369
370 define KernelPackage/b43legacy
371 $(call KernelPackage/b43-common)
372 TITLE:=Broadcom 43xx-legacy wireless support
373 FILES:=$(PKG_BUILD_DIR)/drivers/net/wireless/b43legacy/b43legacy.$(LINUX_KMOD_SUFFIX)
374 AUTOLOAD:=$(call AutoLoad,30,b43legacy)
375 endef
376
377 define KernelPackage/b43legacy/description
378 Kernel module for Broadcom 43xx-legacy wireless support (mac80211 stack) new
379 endef
380
381 BUILDFLAGS:= \
382 -I$(PKG_BUILD_DIR)/include \
383 $(foreach opt,$(CONFOPTS),-DCONFIG_$(opt)) \
384 $(if $(CONFIG_PCI),-DCONFIG_B43_PCI_AUTOSELECT -DCONFIG_B43_PCICORE_AUTOSELECT -DCONFIG_SSB_DRIVER_PCICORE_POSSIBLE -DCONFIG_SSB_DRIVER_PCICORE) \
385 $(if $(CONFIG_PCI),-DCONFIG_SSB_PCIHOST_POSSIBLE -DCONFIG_SSB_PCIHOST) \
386 $(if $(CONFIG_PCI),-DCONFIG_SSB_SPROM) \
387 $(if $(CONFIG_LEDS_TRIGGERS), -DCONFIG_MAC80211_LEDS -DCONFIG_LEDS_TRIGGERS -DCONFIG_B43_LEDS -DCONFIG_B43LEGACY_LEDS) \
388 $(if $(CONFIG_RFKILL),-DCONFIG_B43_RFKILL -DCONFIG_B43LEGACY_RFKILL) \
389 $(if $(CONFIG_HW_RANDOM),-DCONFIG_B43_HWRNG) \
390 $(if $(CONFIG_PCMCIA),-DCONFIG_SSB_PCMCIAHOST_POSSIBLE -DCONFIG_SSB_PCMCIAHOST -DCONFIG_B43_PCMCIA -DCONFIG_B43_PIO) \
391 $(if $(CONFIG_DEBUG_FS), -DCONFIG_MAC80211_DEBUGFS) \
392 -D__CONFIG_MAC80211_RC_DEFAULT=minstrel \
393
394 MAKE_OPTS:= \
395 CROSS_COMPILE="$(TARGET_CROSS)" \
396 ARCH="$(LINUX_KARCH)" \
397 EXTRA_CFLAGS="$(BUILDFLAGS)" \
398 $(foreach opt,$(CONFOPTS),CONFIG_$(opt)=m) \
399 CONFIG_NL80211=y \
400 CONFIG_MAC80211_RC_PID=y \
401 CONFIG_MAC80211_RC_MINSTREL=y \
402 CONFIG_MAC80211_LEDS=$(CONFIG_LEDS_TRIGGERS) \
403 CONFIG_MAC80211_DEBUGFS=$(CONFIG_DEBUG_FS) \
404 $(if $(CONFIG_PCI),CONFIG_B43_PCI_AUTOSELECT=y,CONFIG_B43_PCI_AUTOSELECT=n) \
405 $(if $(CONFIG_PCI),CONFIG_B43_PCICORE_AUTOSELECT=y,CONFIG_B43_PCICORE_AUTOSELECT=n) \
406 $(if $(CONFIG_PCI),CONFIG_SSB_DRIVER_PCICORE_POSSIBLE=y,CONFIG_SSB_DRIVER_PCICORE_POSSIBLE=n) \
407 $(if $(CONFIG_PCI),CONFIG_SSB_DRIVER_PCICORE=y,CONFIG_SSB_DRIVER_PCICORE=n) \
408 $(if $(CONFIG_PCI),CONFIG_SSB_PCIHOST_POSSIBLE=y,CONFIG_SSB_PCIHOST_POSSIBLE=n) \
409 $(if $(CONFIG_PCI),CONFIG_SSB_PCIHOST=y,CONFIG_SSB_PCIHOST=n) \
410 $(if $(CONFIG_PCMCIA),CONFIG_SSB_PCMCIAHOST_POSSIBLE=y,CONFIG_SSB_PCMCIAHOST_POSSIBLE=n) \
411 $(if $(CONFIG_PCMCIA),CONFIG_SSB_PCMCIAHOST=y,CONFIG_SSB_PCMCIAHOST=n) \
412 $(if $(CONFIG_PCMCIA),CONFIG_B43_PCMCIA=y,CONFIG_B43_PCMCIA=n) \
413 $(if $(CONFIG_PCMCIA),CONFIG_B43_PIO=y,CONFIG_B43_PIO=n) \
414 $(if $(CONFIG_RFKILL),CONFIG_B43_RFKILL=y,CONFIG_B43_RFKILL=n) \
415 $(if $(CONFIG_RFKILL),CONFIG_B43LEGACY_RFKILL=y,CONFIG_B43LEGACY_RFKILL=n) \
416 CONFIG_B43LEGACY_LEDS=$(CONFIG_LEDS_TRIGGERS) \
417 CONFIG_B43_LEDS=$(CONFIG_LEDS_TRIGGERS) \
418 $(if $(CONFIG_HW_RANDOM),CONFIG_B43_HWRNG=y,CONFIG_B43_HWRNG=n) \
419 $(if $(CONFIG_PACKAGE_kmod-b43),CONFIG_B43=m) \
420 $(if $(CONFIG_PACKAGE_kmod-b43legacy),CONFIG_B43LEGACY=m) \
421 KLIB_BUILD="$(LINUX_DIR)" \
422 MODPROBE=:
423
424 define Build/Prepare
425 rm -rf $(PKG_BUILD_DIR)
426 mkdir -p $(PKG_BUILD_DIR)
427 $(PKG_UNPACK)
428 $(Build/Patch)
429 unzip -jod $(PKG_BUILD_DIR) $(DL_DIR)/$(RT61FW)
430 unzip -jod $(PKG_BUILD_DIR) $(DL_DIR)/$(RT71FW)
431 -unzip -jod $(PKG_BUILD_DIR) $(DL_DIR)/$(RT2860FW)
432 $(TAR) -C $(PKG_BUILD_DIR) -xjf $(DL_DIR)/$(ZD1211FW_NAME)-$(ZD1211FW_VERSION).tar.bz2
433 rm -rf $(PKG_BUILD_DIR)/include/linux/ssb
434 rm -f $(PKG_BUILD_DIR)/include/net/ieee80211.h
435 rm $(PKG_BUILD_DIR)/include/linux/eeprom_93cx6.h
436 endef
437
438 ifneq ($(CONFIG_PACKAGE_kmod-mac80211),)
439 define Build/Compile/kmod
440 rm -rf $(PKG_BUILD_DIR)/modules
441 $(MAKE) -C "$(PKG_BUILD_DIR)" $(MAKE_OPTS) all
442 endef
443 endif
444
445 define Build/Compile
446 $(call Build/Compile/kmod)
447 endef
448
449 define Build/InstallDev
450 mkdir -p $(1)/usr/include/mac80211 $(1)/usr/include/net/mac80211
451 $(CP) $(PKG_BUILD_DIR)/net/mac80211/*.h $(PKG_BUILD_DIR)/include/* $(1)/usr/include/mac80211/
452 $(CP) $(PKG_BUILD_DIR)/net/mac80211/rate.h $(1)/usr/include/net/mac80211/
453 endef
454
455 define KernelPackage/mac80211/install
456 $(INSTALL_DIR) $(1)/lib/wifi
457 $(INSTALL_DATA) ./files/lib/wifi/mac80211.sh $(1)/lib/wifi
458 endef
459
460 define KernelPackage/p54-pci/install
461 $(INSTALL_DIR) $(1)/lib/firmware
462 $(INSTALL_DATA) $(DL_DIR)/$(P54PCIFW) $(1)/lib/firmware/isl3886pci
463 endef
464
465 define KernelPackage/p54-usb/install
466 $(INSTALL_DIR) $(1)/lib/firmware
467 $(INSTALL_DATA) $(DL_DIR)/$(P54USBFW) $(1)/lib/firmware/isl3886usb
468 endef
469
470 define KernelPackage/rt61-pci/install
471 $(INSTALL_DIR) $(1)/lib/firmware
472 $(INSTALL_DATA) $(PKG_BUILD_DIR)/rt2?61*.bin $(1)/lib/firmware/
473 endef
474
475 define KernelPackage/rt73-usb/install
476 $(INSTALL_DIR) $(1)/lib/firmware
477 $(INSTALL_DATA) $(PKG_BUILD_DIR)/rt73.bin $(1)/lib/firmware/
478 endef
479
480 define KernelPackage/rt2800-pci/install
481 $(INSTALL_DIR) $(1)/lib/firmware
482 $(INSTALL_DATA) $(PKG_BUILD_DIR)/rt2860.bin $(1)/lib/firmware/
483 endef
484
485 define KernelPackage/zd1211rw/install
486 $(INSTALL_DIR) $(1)/lib/firmware/zd1211
487 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(ZD1211FW_NAME)/zd1211* $(1)/lib/firmware/zd1211
488 endef
489
490 define Build/b43-common
491 tar xjf "$(DL_DIR)/$(PKG_B43_FWCUTTER_SOURCE)" -C "$(PKG_BUILD_DIR)"
492 $(MAKE) -C "$(PKG_BUILD_DIR)/$(PKG_B43_FWCUTTER_OBJECT)" \
493 CFLAGS="-I$(STAGING_DIR_HOST)/include -include endian.h"
494 $(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_B43_FWCUTTER_OBJECT)/b43-fwcutter $(STAGING_DIR_HOST)/bin/
495 ifneq ($(CONFIG_B43_OPENFIRMWARE),)
496 $(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/
497 $(MAKE) -C "$(PKG_BUILD_DIR)/$(PKG_B43_FWCUTTER_SUBDIR)/assembler/"
498 $(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_B43_FWCUTTER_SUBDIR)/assembler/b43-asm $(STAGING_DIR_HOST)/bin/
499 $(INSTALL_BIN) $(PKG_BUILD_DIR)/$(PKG_B43_FWCUTTER_SUBDIR)/assembler/b43-asm.bin $(STAGING_DIR_HOST)/bin/
500 endif
501 $(INSTALL_BIN) ./files/host_bin/b43-fwsquash.py $(STAGING_DIR_HOST)/bin/
502 endef
503
504 define KernelPackage/b43/install
505 rm -rf $(1)/lib/firmware/
506 $(call Build/b43-common)
507 ifneq ($(CONFIG_B43_OPENFIRMWARE),)
508 tar xzf "$(DL_DIR)/$(PKG_B43_FWV4_SOURCE)" -C "$(PKG_BUILD_DIR)"
509 else
510 tar xjf "$(DL_DIR)/$(PKG_B43_FWV4_SOURCE)" -C "$(PKG_BUILD_DIR)"
511 endif
512 $(INSTALL_DIR) $(1)/lib/firmware/
513 ifneq ($(CONFIG_B43_OPENFIRMWARE),)
514 $(MAKE) -C "$(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/"
515 $(INSTALL_DIR) $(1)/lib/firmware/b43-open/
516 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/ucode5.fw $(1)/lib/firmware/b43-open/ucode5.fw
517 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/b0g0bsinitvals5.fw $(1)/lib/firmware/b43-open/b0g0bsinitvals5.fw
518 $(INSTALL_DATA) $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)/b0g0initvals5.fw $(1)/lib/firmware/b43-open/b0g0initvals5.fw
519 else
520 b43-fwcutter --unsupported -w $(1)/lib/firmware/ $(PKG_BUILD_DIR)/$(PKG_B43_FWV4_OBJECT)
521 endif
522 ifneq ($(CONFIG_B43_FW_SQUASH),)
523 b43-fwsquash.py "$(CONFIG_B43_FW_SQUASH_PHYTYPES)" "$(CONFIG_B43_FW_SQUASH_COREREVS)" "$(1)/lib/firmware/b43"
524 endif
525 endef
526
527 define KernelPackage/b43legacy/install
528 $(call Build/b43-common)
529 $(INSTALL_DIR) $(1)/lib/firmware/
530
531 b43-fwcutter --unsupported -w $(1)/lib/firmware/ $(DL_DIR)/$(PKG_B43_FWV3_SOURCE)
532 endef
533
534 $(eval $(call KernelPackage,ath5k))
535 $(eval $(call KernelPackage,mac80211))
536 $(eval $(call KernelPackage,p54-common))
537 $(eval $(call KernelPackage,p54-pci))
538 $(eval $(call KernelPackage,p54-usb))
539 $(eval $(call KernelPackage,rt2x00-lib))
540 $(eval $(call KernelPackage,rt2x00-pci))
541 $(eval $(call KernelPackage,rt2x00-usb))
542 $(eval $(call KernelPackage,rt2400-pci))
543 $(eval $(call KernelPackage,rt2500-pci))
544 $(eval $(call KernelPackage,rt2500-usb))
545 $(eval $(call KernelPackage,rt61-pci))
546 $(eval $(call KernelPackage,rt73-usb))
547 $(eval $(call KernelPackage,rt2800-pci))
548 $(eval $(call KernelPackage,rt2800-usb))
549 $(eval $(call KernelPackage,zd1211rw))
550 $(eval $(call KernelPackage,mac80211-hwsim))
551 $(eval $(call KernelPackage,ath9k))
552 $(eval $(call KernelPackage,b43))
553 $(eval $(call KernelPackage,b43legacy))
This page took 0.065496 seconds and 5 git commands to generate.