Initial commit

This commit is contained in:
domenico
2025-06-24 16:03:39 +02:00
commit f3256cdaf2
6949 changed files with 1441681 additions and 0 deletions

View File

@@ -0,0 +1,130 @@
#
# Copyright (C) 2016 Jiang Yutang <jiangyutang1978@gmail.com>
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=uboot-layerscape
PKG_VERSION:=lsdk-1903
PKG_RELEASE:=1
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://source.codeaurora.org/external/qoriq/qoriq-components/u-boot
PKG_SOURCE_VERSION:=80b2d2bc4cab0a8363c9b7eba8064b1795f12670
PKG_MIRROR_HASH:=5c467af40b4479f0ea16697ab54602bed815a23212293184943dca8a3a406d5c
include $(INCLUDE_DIR)/u-boot.mk
include $(INCLUDE_DIR)/package.mk
define U-Boot/Default
BUILD_TARGET:=layerscape
BUILD_SUBTARGET:=armv8_64b
BUILD_DEVICES:=$(1)
UBOOT_IMAGE:=u-boot-dtb.bin
ENV_SIZE:=0x2000
endef
define U-Boot/ls1012ardb
NAME:=NXP LS1012ARDB
UBOOT_CONFIG:=ls1012ardb_tfa
ENV_SIZE:=0x40000
endef
define U-Boot/ls1012afrwy
NAME:=NXP LS1012AFRWY
UBOOT_CONFIG:=ls1012afrwy_tfa
ENV_SIZE:=0x10000
endef
define U-Boot/ls1043ardb
NAME:=NXP LS1043ARDB
UBOOT_CONFIG:=ls1043ardb_tfa
endef
define U-Boot/ls1043ardb-sdboot
NAME:=NXP LS1043ARDB SD Card Boot
UBOOT_CONFIG:=ls1043ardb_tfa
endef
define U-Boot/ls1046ardb
NAME:=NXP LS1046ARDB
UBOOT_CONFIG:=ls1046ardb_tfa
endef
define U-Boot/ls1046ardb-sdboot
NAME:=NXP LS1046ARDB SD Card Boot
UBOOT_CONFIG:=ls1046ardb_tfa
endef
define U-Boot/ls1088ardb
NAME:=NXP LS1088ARDB
UBOOT_CONFIG:=ls1088ardb_tfa
endef
define U-Boot/ls1088ardb-sdboot
NAME:=NXP LS1088ARDB SD Card Boot
UBOOT_CONFIG:=ls1088ardb_tfa
endef
define U-Boot/ls2088ardb
NAME:=NXP LS2088ARDB
UBOOT_CONFIG:=ls2088ardb_tfa
endef
define U-Boot/ls1021atwr
NAME:=NXP LS1021ATWR
BUILD_SUBTARGET:=armv7
UBOOT_CONFIG:=ls1021atwr_nor
ENV_SIZE:=0x20000
endef
define U-Boot/ls1021atwr-sdboot
NAME:=NXP LS1021ATWR SD Card Boot
BUILD_SUBTARGET:=armv7
UBOOT_CONFIG:=ls1021atwr_sdcard_ifc
UBOOT_IMAGE:=u-boot-with-spl-pbl.bin
ENV_SIZE:=0x20000
endef
define U-Boot/ls1021aiot-sdboot
NAME:=NXP LS1021AIOT SD Card Boot
BUILD_SUBTARGET:=armv7
UBOOT_CONFIG:=ls1021aiot_sdcard
UBOOT_IMAGE:=u-boot-with-spl-pbl.bin
ENV_SIZE:=0x2000
endef
UBOOT_TARGETS := \
ls1012ardb \
ls1012afrwy \
ls1043ardb \
ls1043ardb-sdboot \
ls1046ardb \
ls1046ardb-sdboot \
ls1088ardb \
ls1088ardb-sdboot \
ls2088ardb \
ls1021atwr \
ls1021atwr-sdboot \
ls1021aiot-sdboot
define Build/InstallDev
$(INSTALL_DIR) $(STAGING_DIR_IMAGE)
$(INSTALL_DATA) $(PKG_BUILD_DIR)/$(UBOOT_IMAGE) \
$(STAGING_DIR_IMAGE)/$(BUILD_VARIANT)-uboot.bin
$(PKG_BUILD_DIR)/tools/mkenvimage -s $(ENV_SIZE) \
-o $(STAGING_DIR_IMAGE)/$(BUILD_VARIANT)-uboot-env.bin \
files/$(BUILD_VARIANT)-uEnv.txt
endef
define Package/u-boot/install/default
endef
$(eval $(call BuildPackage/U-Boot))

View File

@@ -0,0 +1,8 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
sd_boot=mmc read $fdtaddr 7800 800;mmc read $loadaddr 8000 8000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;pfe stop;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,8 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
qspi_boot=sf probe 0:0;sf read $fdtaddr f00000 100000;sf read $loadaddr 1000000 1000000;bootm $loadaddr - $fdtaddr
bootargs=ubi.mtd=8 root=ubi0:rootfs rw rootfstype=ubifs noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200 mtdparts=1550000.quadspi:1m(bl2),4m(fip),1m(u-boot-env),4m(reserved-1),3m(pfe),2m(reserved-2),1m(dtb),16m(kernel),32m(ubifs)
bootcmd=echo starting openwrt ...;pfe stop;run qspi_boot
bootdelay=3

View File

@@ -0,0 +1,8 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffff
initrd_high=0xffffffff
sd_boot=mmc read ${fdtaddr} 7800 800;mmc read ${loadaddr} 8000 8000;bootm ${loadaddr} - ${fdtaddr}
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,8 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffff
initrd_high=0xffffffff
sd_boot=mmc read $fdtaddr 7800 800;mmc read $loadaddr 8000 8000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,8 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffff
initrd_high=0xffffffff
nor_boot=cp.b 60f00000 $fdtaddr 100000;cp.b 61000000 $loadaddr 1000000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mtdblock6 rootfstype=squashfs,jffs2 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200 mtdparts=60000000.nor:1m(rcw),2m(u-boot),1m(u-boot-env),11m(reserved-1),1m(dtb),16m(kernel),32m(rootfs)
bootcmd=echo starting openwrt ...;run nor_boot
bootdelay=3

View File

@@ -0,0 +1,9 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
sd_boot=mmc read $fdtaddr 7800 800;mmc read $loadaddr 8000 8000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,9 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
nor_boot=cp.b 60f00000 $fdtaddr 100000;cp.b 61000000 $loadaddr 1000000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mtdblock8 rootfstype=squashfs,jffs2 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200 mtdparts=60000000.nor:1m(bl2),4m(fip),1m(u-boot-env),3m(reserved-1),256k(fman),5888k(reserved-2),1m(dtb),16m(kernel),32m(rootfs)
bootcmd=echo starting openwrt ...;run nor_boot
bootdelay=3

View File

@@ -0,0 +1,9 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
sd_boot=mmc read $fdtaddr 7800 800;mmc read $loadaddr 8000 8000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,9 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xffffffffffffffff
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
qspi_boot=sf probe 0:0;sf read $fdtaddr f00000 100000;sf read $loadaddr 1000000 1000000;bootm $loadaddr - $fdtaddr
bootargs=ubi.mtd=9 root=ubi0:rootfs rw rootfstype=ubifs noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200 mtdparts=1550000.quadspi:1m(bl2),4m(fip),1m(u-boot-env),3m(reserved-1),256k(fman),5888k(reserved-2),1m(dtb),16m(kernel),32m(ubifs)
bootcmd=echo starting openwrt ...;run qspi_boot
bootdelay=3

View File

@@ -0,0 +1,10 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xa0000000
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
mc_init=mmc read 80000000 5000 1800;mmc read 80300000 7000 800;fsl_mc start mc 80000000 80300000;mmc read 80400000 6800 800;fsl_mc apply dpl 80400000
sd_boot=mmc read $fdtaddr 7800 800;mmc read $loadaddr 8000 8000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200
bootcmd=echo starting openwrt ...;run mc_init;run sd_boot
bootdelay=3

View File

@@ -0,0 +1,10 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xa0000000
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
mc_init=sf probe 0:0;sf read 80000000 a00000 300000;sf read 80300000 e00000 100000;fsl_mc start mc 80000000 80300000;sf read 80400000 d00000 100000;fsl_mc apply dpl 80400000
qspi_boot=sf probe 0:0;sf read $fdtaddr f00000 100000;sf read $loadaddr 1000000 1000000;bootm $loadaddr - $fdtaddr
bootargs=ubi.mtd=10 root=ubi0:rootfs rw rootfstype=ubifs noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS0,115200 mtdparts=20c0000.quadspi:1m(bl2),4m(fip),1m(u-boot-env),4m(reserved-1),3m(mc),1m(dpl),1m(dpc),1m(dtb),16m(kernel),32m(ubifs)
bootcmd=echo starting openwrt ...;run mc_init;run qspi_boot
bootdelay=3

View File

@@ -0,0 +1,10 @@
fdtaddr=0x8f000000
loadaddr=0x81000000
fdt_high=0xa0000000
initrd_high=0xffffffffffffffff
hwconfig=fsl_ddr:bank_intlv=auto
mc_init=fsl_mc start mc 580a00000 580e00000;fsl_mc apply dpl 580d00000
nor_boot=cp.b 580f00000 $fdtaddr 100000;cp.b 581000000 $loadaddr 1000000;bootm $loadaddr - $fdtaddr
bootargs=root=/dev/mtdblock9 rootfstype=squashfs,jffs2 noinitrd earlycon=uart8250,mmio,0x21c0500 console=ttyS1,115200 mtdparts=580000000.nor:1m(bl2),4m(fip),1m(u-boot-env),4m(reserved-1),3m(mc),1m(dpl),1m(dpc),1m(dtb),16m(kernel),32m(rootfs)
bootcmd=echo starting openwrt ...;run mc_init;run nor_boot
bootdelay=3

View File

@@ -0,0 +1,28 @@
From 51f860f8293d834497c6f7f810fa4650cd82f9ac Mon Sep 17 00:00:00 2001
From: Biwen Li <biwen.li@nxp.com>
Date: Sat, 13 Apr 2019 14:21:47 +0800
Subject: [PATCH] modify macro QSPI_NOR_BOOTCOMMAND of ls1046ardb for openwrt
Signed-off-by: Biwen Li <biwen.li@nxp.com>
---
include/configs/ls1046ardb.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/configs/ls1046ardb.h b/include/configs/ls1046ardb.h
index cc1f5f5f55..925e717e4b 100644
--- a/include/configs/ls1046ardb.h
+++ b/include/configs/ls1046ardb.h
@@ -217,8 +217,8 @@
#ifndef SPL_NO_MISC
#undef CONFIG_BOOTCOMMAND
#ifdef CONFIG_TFABOOT
-#define QSPI_NOR_BOOTCOMMAND "run distro_bootcmd; run qspi_bootcmd; " \
- "env exists secureboot && esbc_halt;;"
+#define QSPI_NOR_BOOTCOMMAND "echo (from QSPI_NOR_BOOTCOMMAND) starting openwrt; " \
+ "run qspi_boot;"
#define SD_BOOTCOMMAND "run distro_bootcmd;run sd_bootcmd; " \
"env exists secureboot && esbc_halt;"
#else
--
2.17.1

View File

@@ -0,0 +1,28 @@
From 2999d128bef554da5ca7a553dfe1c31061df9c5c Mon Sep 17 00:00:00 2001
From: Biwen Li <biwen.li@nxp.com>
Date: Sun, 14 Apr 2019 13:36:52 +0800
Subject: [PATCH] modify macro QSPI_NOR_BOOTCOMMAND of ls1012afrwy for openwrt
Signed-off-by: Biwen Li <biwen.li@nxp.com>
---
include/configs/ls1012afrwy.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/configs/ls1012afrwy.h b/include/configs/ls1012afrwy.h
index 12e6437a05..900752970e 100644
--- a/include/configs/ls1012afrwy.h
+++ b/include/configs/ls1012afrwy.h
@@ -122,8 +122,8 @@
#undef CONFIG_BOOTCOMMAND
#ifdef CONFIG_TFABOOT
#undef QSPI_NOR_BOOTCOMMAND
-#define QSPI_NOR_BOOTCOMMAND "pfe stop; run distro_bootcmd; run sd_bootcmd; "\
- "env exists secureboot && esbc_halt;"
+#define QSPI_NOR_BOOTCOMMAND "echo (from QSPI_NOR_BOOTCOMMAND) starting openwrt ...; "\
+ "pfe stop; run sd_boot;"
#else
#define CONFIG_BOOTCOMMAND "pfe stop; run distro_bootcmd; run sd_bootcmd; "\
"env exists secureboot && esbc_halt;"
--
2.17.1

View File

@@ -0,0 +1,28 @@
From 805c60e930a946560b52dfa83dd8e5fbdf2da15b Mon Sep 17 00:00:00 2001
From: Biwen Li <biwen.li@nxp.com>
Date: Sun, 14 Apr 2019 13:39:13 +0800
Subject: [PATCH] modify macro QSPI_NOR_BOOTCOMMAND of ls1012ardb for openwrt
Signed-off-by: Biwen Li <biwen.li@nxp.com>
---
include/configs/ls1012ardb.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/configs/ls1012ardb.h b/include/configs/ls1012ardb.h
index f6640fa499..51a2192c56 100644
--- a/include/configs/ls1012ardb.h
+++ b/include/configs/ls1012ardb.h
@@ -115,8 +115,8 @@
#undef CONFIG_BOOTCOMMAND
#ifdef CONFIG_TFABOOT
#undef QSPI_NOR_BOOTCOMMAND
-#define QSPI_NOR_BOOTCOMMAND "pfe stop; run distro_bootcmd; run qspi_bootcmd; "\
- "env exists secureboot && esbc_halt;"
+#define QSPI_NOR_BOOTCOMMAND "echo (from QSPI_NOR_BOOTCOMMAND) starting openwrt ...; "\
+ "pfe stop; run qspi_boot;"
#else
#define CONFIG_BOOTCOMMAND "pfe stop; run distro_bootcmd; run qspi_bootcmd; "\
"env exists secureboot && esbc_halt;"
--
2.17.1