mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
K3: Update to latest U-Boot v2025.01
Now that upstream U-Boot has support for building K3 boot artifacts we can drop using the ti-u-boot fork. Switch to v2025.01 and adjust file names and add new dependencies as needed.
This commit is contained in:
@@ -9,6 +9,8 @@ BOOT_FDT_FILE="ti/k3-j721e-sk.dts"
|
||||
TIBOOT3_BOOTCONFIG="j721e_evm_r5_defconfig"
|
||||
TIBOOT3_FILE="tiboot3-j721e-gp-evm.bin"
|
||||
SYSFW_FILE="sysfw-j721e-gp-evm.itb"
|
||||
TISPL_FILE="tispl.bin_unsigned"
|
||||
UBOOT_FILE="u-boot.img_unsigned"
|
||||
DEFAULT_CONSOLE="serial"
|
||||
KERNEL_TARGET="current,edge"
|
||||
KERNEL_TEST_TARGET="current"
|
||||
|
||||
@@ -4,4 +4,4 @@ finduuid=part uuid \${boot} 1:2 uuid
|
||||
name_rd=uInitrd
|
||||
get_rd_mmc=load mmc ${bootpart} ${rdaddr} ${bootdir}/${name_rd}
|
||||
|
||||
uenvcmd=run get_rd_${boot}; env set rd_spec ${rdaddr}:${filesize}
|
||||
uenvcmd=run get_rd_${boot}; env set rd_spec ${rdaddr}:${filesize}; setexpr fdtfile sub ti/ti ti; run bootcmd_ti_mmc
|
||||
|
||||
@@ -12,7 +12,7 @@ declare -g LINUXFAMILY="k3"
|
||||
declare -g OVERLAY_DIR="/boot/dtb/ti/overlay"
|
||||
declare -g ATFBRANCH="tag:v2.12.0"
|
||||
|
||||
declare -g BOOTBRANCH="tag:v2023.10-rc3"
|
||||
declare -g BOOTBRANCH="tag:v2025.01"
|
||||
declare -g BOOTSCRIPT="boot-k3.cmd:uEnv.txt"
|
||||
|
||||
case "${BRANCH}" in
|
||||
@@ -44,18 +44,17 @@ ROOT_FS_LABEL="root"
|
||||
|
||||
function add_host_dependencies__k3_python3_dep() {
|
||||
display_alert "Preparing K3 U-Boot host-side dependencies" "${EXTENSION}" "info"
|
||||
declare -g EXTRA_BUILD_DEPS="${EXTRA_BUILD_DEPS} python3-yaml python3-jsonschema"
|
||||
declare -g EXTRA_BUILD_DEPS="${EXTRA_BUILD_DEPS} python3-yaml python3-jsonschema yamllint"
|
||||
}
|
||||
|
||||
function compile_k3_bootgen() {
|
||||
# Source code checkout
|
||||
(fetch_from_repo "https://git.ti.com/cgit/processor-firmware/ti-linux-firmware" "ti-linux-firmware" "branch:ti-linux-firmware")
|
||||
(fetch_from_repo "https://git.ti.com/cgit/ti-u-boot/ti-u-boot" "ti-u-boot" "branch:ti-u-boot-2023.04")
|
||||
|
||||
pushd ${SRC}/cache/sources/ti-u-boot || exit
|
||||
pushd ${SRC}/cache/sources/u-boot-worktree/${BOOTDIR}/${BOOTBRANCH##*:} || exit
|
||||
|
||||
run_host_command_logged make -j$(nproc) CROSS_COMPILE=arm-linux-gnueabihf- ARCH=arm ${TIBOOT3_BOOTCONFIG}
|
||||
run_host_command_logged make -j$(nproc) CROSS_COMPILE=arm-linux-gnueabihf- ARCH=arm BINMAN_INDIRS=${SRC}/cache/sources/ti-linux-firmware
|
||||
run_host_command_logged make -j$(nproc) CROSS_COMPILE=arm-linux-gnueabihf- ARCH=arm O=build-r5 ${TIBOOT3_BOOTCONFIG}
|
||||
run_host_command_logged make -j$(nproc) CROSS_COMPILE=arm-linux-gnueabihf- ARCH=arm O=build-r5 BINMAN_INDIRS=${SRC}/cache/sources/ti-linux-firmware
|
||||
|
||||
popd
|
||||
}
|
||||
@@ -64,8 +63,13 @@ function pre_config_uboot_target__build_first_stage() {
|
||||
# Compile first stage bootloader
|
||||
compile_k3_bootgen
|
||||
|
||||
cp ${SRC}/cache/sources/ti-u-boot/${TIBOOT3_FILE} tiboot3.bin
|
||||
cp ${SRC}/cache/sources/ti-u-boot/${SYSFW_FILE} sysfw.itb || true
|
||||
cp ${SRC}/cache/sources/u-boot-worktree/${BOOTDIR}/${BOOTBRANCH##*:}/build-r5/${TIBOOT3_FILE} tiboot3.bin
|
||||
cp ${SRC}/cache/sources/u-boot-worktree/${BOOTDIR}/${BOOTBRANCH##*:}/build-r5/${SYSFW_FILE} sysfw.itb || true
|
||||
}
|
||||
|
||||
function post_uboot_custom_postprocess__update_uboot_names() {
|
||||
cp ${TISPL_FILE} tispl.bin || true
|
||||
cp ${UBOOT_FILE} u-boot.img || true
|
||||
}
|
||||
|
||||
function pre_prepare_partitions() {
|
||||
|
||||
Reference in New Issue
Block a user