summaryrefslogtreecommitdiff
path: root/package/mac80211
diff options
context:
space:
mode:
authorHauke Mehrtens <hauke@hauke-m.de>2009-12-26 23:15:16 +0000
committerHauke Mehrtens <hauke@hauke-m.de>2009-12-26 23:15:16 +0000
commitabade416d152b1c48cc711b0d994e9cdd279da4e (patch)
treef66345d5cf61823f1fddd0d589fc5707842dd0fe /package/mac80211
parent3c175fb47c2667394119e720b14f8d202f53d3c7 (diff)
downloadmtk-20170518-abade416d152b1c48cc711b0d994e9cdd279da4e.zip
mtk-20170518-abade416d152b1c48cc711b0d994e9cdd279da4e.tar.gz
mtk-20170518-abade416d152b1c48cc711b0d994e9cdd279da4e.tar.bz2
b43 and b43legacy: squash firmware
Only G and L-PHY are supportted by b43 driver Add squash firmware for b43legacy SVN-Revision: 18947
Diffstat (limited to 'package/mac80211')
-rw-r--r--package/mac80211/Config.in.b437
-rw-r--r--package/mac80211/Config.in.b43legacy24
-rw-r--r--package/mac80211/Makefile7
-rwxr-xr-xpackage/mac80211/files/host_bin/b43-fwsquash.py4
4 files changed, 37 insertions, 5 deletions
diff --git a/package/mac80211/Config.in.b43 b/package/mac80211/Config.in.b43
index 04576a8..e1f4d37 100644
--- a/package/mac80211/Config.in.b43
+++ b/package/mac80211/Config.in.b43
@@ -47,10 +47,7 @@ config B43_FW_SQUASH
from the final rootfs image. This can reduce the rootfs size by
up to 200k.
- Do _NOT_ use this option, if you don't know the core revision
- and/or PHY type of your wireless chip.
-
- If unsure, say N.
+ If unsure, say Y.
config B43_FW_SQUASH_COREREVS
string "Core revisions to include"
@@ -66,7 +63,7 @@ config B43_FW_SQUASH_COREREVS
config B43_FW_SQUASH_PHYTYPES
string "PHY types to include"
depends on PACKAGE_kmod-b43 && B43_FW_SQUASH
- default "A,AG,G,LP"
+ default "G,LP"
help
This is a comma seperated list of PHY types:
A => A-PHY
diff --git a/package/mac80211/Config.in.b43legacy b/package/mac80211/Config.in.b43legacy
new file mode 100644
index 0000000..2e2f06e
--- /dev/null
+++ b/package/mac80211/Config.in.b43legacy
@@ -0,0 +1,24 @@
+# B43 configuration
+
+config B43LEGACY_FW_SQUASH
+ bool "Remove unnecessary firmware files"
+ depends on PACKAGE_kmod-b43legacy
+ default y
+ help
+ This options allows you to remove unnecessary b43legacy firmware files
+ from the final rootfs image. This can reduce the rootfs size by
+ up to 50k.
+
+ If unsure, say Y.
+
+config B43LEGACY_FW_SQUASH_COREREVS
+ string "Core revisions to include"
+ depends on PACKAGE_kmod-b43legacy && B43LEGACY_FW_SQUASH
+ default "1,2,3,4"
+ help
+ This is a comma seperated list of core revision numbers.
+ Example (keep files for rev4 only):
+ 4
+ Example (keep files for rev2 and rev4):
+ 2,4
+
diff --git a/package/mac80211/Makefile b/package/mac80211/Makefile
index 4cef285..d500ed9 100644
--- a/package/mac80211/Makefile
+++ b/package/mac80211/Makefile
@@ -489,6 +489,10 @@ $(call KernelPackage/b43-common)
AUTOLOAD:=$(call AutoLoad,30,b43legacy)
endef
+define KernelPackage/b43legacy/config
+ source "$(SOURCE)/Config.in.b43legacy"
+endef
+
define KernelPackage/b43legacy/description
Kernel module for Broadcom 43xx-legacy wireless support (mac80211 stack) new
endef
@@ -712,6 +716,9 @@ define KernelPackage/b43legacy/install
$(INSTALL_DIR) $(1)/lib/firmware/
b43-fwcutter --unsupported -w $(1)/lib/firmware/ $(DL_DIR)/$(PKG_B43_FWV3_SOURCE)
+ifneq ($(CONFIG_B43LEGACY_FW_SQUASH),)
+ b43-fwsquash.py "G" "$(CONFIG_B43LEGACY_FW_SQUASH_COREREVS)" "$(1)/lib/firmware/b43legacy"
+endif
endef
$(eval $(call KernelPackage,ath5k))
diff --git a/package/mac80211/files/host_bin/b43-fwsquash.py b/package/mac80211/files/host_bin/b43-fwsquash.py
index 088ed48..34e6ed3 100755
--- a/package/mac80211/files/host_bin/b43-fwsquash.py
+++ b/package/mac80211/files/host_bin/b43-fwsquash.py
@@ -62,17 +62,21 @@ def phytypes_match(types_a, types_b):
return False
revmapping = {
+ "ucode2.fw" : (2,),
+ "ucode4.fw" : (4,),
"ucode5.fw" : (5,6,7,8,9,10,),
"ucode11.fw" : (11,12,),
"ucode13.fw" : (13,),
"ucode14.fw" : (14,),
"ucode15.fw" : (15,),
+ "pcm4.fw" : (1,2,3,4,),
"pcm5.fw" : (5,6,7,8,9,10,),
}
initvalmapping = {
"a0g1initvals5.fw" : ( (5,6,7,8,9,10,), ("AG",), ),
"a0g0initvals5.fw" : ( (5,6,7,8,9,10,), ("A", "AG",), ),
+ "b0g0initvals2.fw" : ( (2,4,), ("G",), ),
"b0g0initvals5.fw" : ( (5,6,7,8,9,10,), ("G",), ),
"b0g0initvals13.fw" : ( (13,), ("G",), ),
"n0initvals11.fw" : ( (11,12,), ("N",), ),