aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/bcm4908/image/Makefile11
-rw-r--r--target/linux/bcm4908/image/bootfs-generic.its25
2 files changed, 36 insertions, 0 deletions
diff --git a/target/linux/bcm4908/image/Makefile b/target/linux/bcm4908/image/Makefile
index 426db4c5a6..929e626e0e 100644
--- a/target/linux/bcm4908/image/Makefile
+++ b/target/linux/bcm4908/image/Makefile
@@ -6,6 +6,17 @@ include $(INCLUDE_DIR)/image.mk
DEVICE_VARS += ASUS_PRODUCTID ASUS_BUILD_NO ASUS_FW_REV ASUS_EXT_NO
DEVICE_VARS += NETGEAR_BOARD_ID NETGEAR_REGION
+define Image/Prepare
+ cp bootfs-generic.its $(KDIR)/
+endef
+
+define Build/bootfs
+ cat $@ | $(STAGING_DIR_HOST)/bin/lzma e -eos -si -so > $@.tmp
+ mv $@.tmp $@
+ sed -i "s=\$${kernel}=$@=" $(KDIR)/bootfs-generic.its
+ PATH=$(LINUX_DIR)/scripts/dtc:$(PATH) mkimage -f $(KDIR)/bootfs-generic.its $(KDIR)/bootfs-generic.itb
+endef
+
define Build/bcm4908asus
$(STAGING_DIR_HOST)/bin/bcm4908asus create -i $@ \
-p $(ASUS_PRODUCTID) -b $(ASUS_BUILD_NO) -f $(ASUS_FW_REV) \
diff --git a/target/linux/bcm4908/image/bootfs-generic.its b/target/linux/bcm4908/image/bootfs-generic.its
new file mode 100644
index 0000000000..d2f19ed752
--- /dev/null
+++ b/target/linux/bcm4908/image/bootfs-generic.its
@@ -0,0 +1,25 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+
+/dts-v1/;
+
+/ {
+ description = "OpenWrt bootfs image";
+ #address-cells = <1>;
+
+ images {
+ kernel {
+ description = "Linux kernel";
+ data = /incbin/("${kernel}");
+ type = "kernel";
+ os = "linux";
+ arch = "arm64";
+ compression = "lzma";
+ load = <0x80000>;
+ entry = <0x80000>;
+
+ hash-1 {
+ algo = "sha256";
+ };
+ };
+ };
+};