Full working uboot+linux
This commit is contained in:
parent
233b7f2936
commit
f7690e653f
@ -30,6 +30,10 @@ cp -R conf/* target/overlay # copy target system config files
|
||||
cp -R webpanel/* target/overlay/var/www/html # copy the webpanel
|
||||
cp -R update/update.sh target/overlay #copy the update script and certificate
|
||||
|
||||
echo "[+] Adding firmware"
|
||||
mkdir -p target/overlay/lib
|
||||
cp -R firmware target/overlay/lib/ # adding binary firmware for wifi driver
|
||||
|
||||
echo "[+] Writing flags"
|
||||
sed -i "s/##FLAG1##/$flag1/g" target/overlay/var/www/html/includes/config.php
|
||||
echo $flag2 > target/overlay/flag
|
||||
@ -42,7 +46,7 @@ chmod 400 target/overlay/root/flag
|
||||
echo "[+] Building the keygen"
|
||||
mkdir -p target/overlay/usr/sbin
|
||||
aarch64-linux-gnu-gcc -o target/overlay/usr/sbin/cfgbin keygen/keygen.c -static -lm
|
||||
strip target/overlay/usr/sbin/cfgbin
|
||||
aarch64-linux-gnu-strip target/overlay/usr/sbin/cfgbin
|
||||
|
||||
echo "[+] Generating Update Key"
|
||||
mkdir -p target/keys
|
||||
|
@ -4503,7 +4503,7 @@ Index: u-boot-imx/include/configs/tgr.h
|
||||
===================================================================
|
||||
--- /dev/null
|
||||
+++ u-boot-imx/include/configs/tgr.h
|
||||
@@ -0,0 +1,361 @@
|
||||
@@ -0,0 +1,357 @@
|
||||
+/*
|
||||
+ * Copyright 2018 NXP
|
||||
+ *
|
||||
@ -4657,8 +4657,8 @@ Index: u-boot-imx/include/configs/tgr.h
|
||||
+ "root=ubi0:nandrootfs rootfstype=ubifs " \
|
||||
+ MFG_NAND_PARTITION \
|
||||
+ "\0" \
|
||||
+ "bootcmd=nand read ${loadaddr} 0x5000000 0x2000000;"\
|
||||
+ "nand read ${fdt_addr} 0x7000000 0x100000;"\
|
||||
+ "bootcmd=fatload mmc 1:1 ${fdt_addr} fsl-imx8mm-tgr.dtb;"\
|
||||
+ "fatload mmc 1:1 ${loadaddr} Image;"\
|
||||
+ "booti ${loadaddr} - ${fdt_addr}"
|
||||
+
|
||||
+#else
|
||||
@ -4681,13 +4681,9 @@ Index: u-boot-imx/include/configs/tgr.h
|
||||
+ "mmcautodetect=yes\0"
|
||||
+
|
||||
+#define CONFIG_BOOTCOMMAND \
|
||||
+ "mmc dev ${mmcdev}; " \
|
||||
+ "if mmc rescan; then " \
|
||||
+ "ext4load mmc 1:2 ${loadaddr} boot/Image; " \
|
||||
+ "ext4load mmc 1:2 ${fdt_addr} usr/lib/linux-image-4.14.98-tgr/freescale/fsl-imx8mm-tgr.dtb; " \
|
||||
+ "ext4load mmc 1:2 ${initrd_addr} boot/initramfs.uImage; " \
|
||||
+ "booti ${loadaddr} ${initrd_addr} ${fdt_addr}; " \
|
||||
+ "else echo Cannot boot from emmc; fi"
|
||||
+ "fatload mmc 1:1 ${fdt_addr} fsl-imx8mm-tgr.dtb;" \
|
||||
+ "fatload mmc 1:1 ${loadaddr} Image;" \
|
||||
+ "booti ${loadaddr} - ${fdt_addr}; "
|
||||
+#endif
|
||||
+
|
||||
+/* Link Definitions */
|
||||
|
Loading…
Reference in New Issue
Block a user