From ce138d9742bfa15f48462c22f25424e0fcbfbb24 Mon Sep 17 00:00:00 2001 From: Mattijs Korpershoek Date: Fri, 11 Oct 2024 17:51:02 +0200 Subject: configs: khadas-vim3{l}: Increase boot/recovery partition size The Android Common Kernel is over 34MiB now [1]. This does not include any kernel modules nor the Android ramdisk. To make sure we are future proof, increase both recovery and boot partitions to 64 MiB. [1] https://source.android.com/docs/core/architecture/kernel/gki-android15-6_6-release-builds Signed-off-by: Mattijs Korpershoek Reviewed-by: Guillaume La Roque Reviewed-by: Neil Armstrong Link: https://lore.kernel.org/r/20241011-yukawa-aosp-parts-v1-1-7d74aa13ff8e@baylibre.com Signed-off-by: Neil Armstrong --- include/configs/khadas-vim3_android.h | 8 ++++---- include/configs/khadas-vim3l_android.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'include') diff --git a/include/configs/khadas-vim3_android.h b/include/configs/khadas-vim3_android.h index da6adf6c413..b76e049f09c 100644 --- a/include/configs/khadas-vim3_android.h +++ b/include/configs/khadas-vim3_android.h @@ -21,8 +21,8 @@ "name=dtbo_b,size=8M,uuid=${uuid_gpt_dtbo_b};" \ "name=vbmeta_a,size=512K,uuid=${uuid_gpt_vbmeta_a};" \ "name=vbmeta_b,size=512K,uuid=${uuid_gpt_vbmeta_b};" \ - "name=boot_a,size=32M,bootable,uuid=${uuid_gpt_boot_a};" \ - "name=boot_b,size=32M,bootable,uuid=${uuid_gpt_boot_b};" \ + "name=boot_a,size=64M,bootable,uuid=${uuid_gpt_boot_a};" \ + "name=boot_b,size=64M,bootable,uuid=${uuid_gpt_boot_b};" \ "name=super,size=3072M,uuid=${uuid_gpt_super};" \ "name=userdata,size=11282M,uuid=${uuid_gpt_userdata};" \ "name=rootfs,size=-,uuid=" ROOT_UUID @@ -33,8 +33,8 @@ "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ "name=dtbo,size=8M,uuid=${uuid_gpt_dtbo};" \ "name=vbmeta,size=512K,uuid=${uuid_gpt_vbmeta};" \ - "name=boot,size=32M,bootable,uuid=${uuid_gpt_boot};" \ - "name=recovery,size=32M,uuid=${uuid_gpt_recovery};" \ + "name=boot,size=64M,bootable,uuid=${uuid_gpt_boot};" \ + "name=recovery,size=64M,uuid=${uuid_gpt_recovery};" \ "name=cache,size=256M,uuid=${uuid_gpt_cache};" \ "name=super,size=1792M,uuid=${uuid_gpt_super};" \ "name=userdata,size=12786M,uuid=${uuid_gpt_userdata};" \ diff --git a/include/configs/khadas-vim3l_android.h b/include/configs/khadas-vim3l_android.h index b1768e2d821..0ab8ffd372a 100644 --- a/include/configs/khadas-vim3l_android.h +++ b/include/configs/khadas-vim3l_android.h @@ -21,8 +21,8 @@ "name=dtbo_b,size=8M,uuid=${uuid_gpt_dtbo_b};" \ "name=vbmeta_a,size=512K,uuid=${uuid_gpt_vbmeta_a};" \ "name=vbmeta_b,size=512K,uuid=${uuid_gpt_vbmeta_b};" \ - "name=boot_a,size=32M,bootable,uuid=${uuid_gpt_boot_a};" \ - "name=boot_b,size=32M,bootable,uuid=${uuid_gpt_boot_b};" \ + "name=boot_a,size=64M,bootable,uuid=${uuid_gpt_boot_a};" \ + "name=boot_b,size=64M,bootable,uuid=${uuid_gpt_boot_b};" \ "name=super,size=3072M,uuid=${uuid_gpt_super};" \ "name=userdata,size=11282M,uuid=${uuid_gpt_userdata};" \ "name=rootfs,size=-,uuid=" ROOT_UUID @@ -33,8 +33,8 @@ "name=misc,size=512K,uuid=${uuid_gpt_misc};" \ "name=dtbo,size=8M,uuid=${uuid_gpt_dtbo};" \ "name=vbmeta,size=512K,uuid=${uuid_gpt_vbmeta};" \ - "name=boot,size=32M,bootable,uuid=${uuid_gpt_boot};" \ - "name=recovery,size=32M,uuid=${uuid_gpt_recovery};" \ + "name=boot,size=64M,bootable,uuid=${uuid_gpt_boot};" \ + "name=recovery,size=64M,uuid=${uuid_gpt_recovery};" \ "name=cache,size=256M,uuid=${uuid_gpt_cache};" \ "name=super,size=1792M,uuid=${uuid_gpt_super};" \ "name=userdata,size=12786M,uuid=${uuid_gpt_userdata};" \ -- cgit v1.2.3 From 0b063d66406e5bc0f367dd735216abe6a6543271 Mon Sep 17 00:00:00 2001 From: Mattijs Korpershoek Date: Fri, 11 Oct 2024 17:51:03 +0200 Subject: configs: meson64_android: Remove dtbo support The device tree overlays are not part of the Android Common Kernel code [1] Historically, they existed to enable some Android specific features but they have been removed. Remove the dtbos logic since these files do no longer exist. [1] https://android.googlesource.com/kernel/common/+/ac2ea0bb91a3b5f5e71eba66c441e58beca6767e/arch/arm64/boot/dts/amlogic/ Signed-off-by: Mattijs Korpershoek Reviewed-by: Guillaume La Roque Reviewed-by: Neil Armstrong Link: https://lore.kernel.org/r/20241011-yukawa-aosp-parts-v1-2-7d74aa13ff8e@baylibre.com Signed-off-by: Neil Armstrong --- include/configs/meson64_android.h | 26 +------------------------- 1 file changed, 1 insertion(+), 25 deletions(-) (limited to 'include') diff --git a/include/configs/meson64_android.h b/include/configs/meson64_android.h index c0e977abb01..fa520265800 100644 --- a/include/configs/meson64_android.h +++ b/include/configs/meson64_android.h @@ -116,31 +116,7 @@ "fi; " \ "abootimg get dtb --index=$dtb_index dtb_start dtb_size; " \ "cp.b $dtb_start $fdt_addr_r $dtb_size; " \ - "fdt addr $fdt_addr_r 0x80000; " \ - "if test $board_name = sei510; then " \ - "echo \" Reading DTBO for sei510...\"; " \ - "setenv dtbo_index 0;" \ - "elif test $board_name = sei610; then " \ - "echo \" Reading DTBO for sei610...\"; " \ - "setenv dtbo_index 1;" \ - "elif test $board_name = vim3l; then " \ - "echo \" Reading DTBO for vim3l...\"; " \ - "setenv dtbo_index 2;" \ - "elif test $board_name = vim3; then " \ - "echo \" Reading DTBO for vim3...\"; " \ - "setenv dtbo_index 3;" \ - "else " \ - "echo Error: Android boot is not supported for $board_name; " \ - "exit; " \ - "fi; " \ - "part start mmc ${mmcdev} dtbo${slot_suffix} p_dtbo_start; " \ - "part size mmc ${mmcdev} dtbo${slot_suffix} p_dtbo_size; " \ - "mmc read ${dtboaddr} ${p_dtbo_start} ${p_dtbo_size}; " \ - "echo \" Applying DTBOs...\"; " \ - "adtimg addr $dtboaddr; " \ - "adtimg get dt --index=$dtbo_index dtbo0_addr; " \ - "fdt apply $dtbo0_addr;" \ - "setenv bootargs \"$bootargs androidboot.dtbo_idx=$dtbo_index \";"\ + "fdt addr $fdt_addr_r 0x80000; " #define BOOT_CMD "bootm ${loadaddr} ${loadaddr} ${fdt_addr_r};" -- cgit v1.2.3 From 315cad97a5ae09b1b975fff2413ce785b3b8592a Mon Sep 17 00:00:00 2001 From: Callum Parsey Date: Sat, 12 Oct 2024 08:03:51 +0000 Subject: configs: meson64: Ensure commands for boot targets are available When populating BOOT_TARGET_DEVICES on Amlogic Meson platforms, verify that the shell commands for accessing the relevant media have been enabled in the build configuration. This was already being done for USB, NVME and SCSI devices, but not for MMC devices or network boot. This meant that configuring U-Boot without the networking or MMC subsystems/drivers would cause an error to be thrown during preprocessing. Signed-off-by: Callum Parsey Reviewed-by: Neil Armstrong Link: https://lore.kernel.org/r/20241012080340.2596-1-callum@neoninteger.au Signed-off-by: Neil Armstrong --- include/configs/meson64.h | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/include/configs/meson64.h b/include/configs/meson64.h index ccb8ea2e716..f3275b37a51 100644 --- a/include/configs/meson64.h +++ b/include/configs/meson64.h @@ -77,6 +77,15 @@ #define BOOTENV_DEV_NAME_USB_DFU(devtypeu, devtypel, instance) #endif +#ifdef CONFIG_CMD_MMC + #define BOOT_TARGET_MMC(func) \ + func(MMC, mmc, 0) \ + func(MMC, mmc, 1) \ + func(MMC, mmc, 2) +#else + #define BOOT_TARGET_MMC(func) +#endif + #ifdef CONFIG_CMD_USB #define BOOT_TARGET_DEVICES_USB(func) func(USB, usb, 0) #else @@ -95,18 +104,27 @@ #define BOOT_TARGET_SCSI(func) #endif +#if defined(CONFIG_CMD_DHCP) && defined(CONFIG_CMD_PXE) + #define BOOT_TARGET_PXE(func) func(PXE, pxe, na) + #define BOOT_TARGET_DHCP(func) func(DHCP, dhcp, na) +#elif defined(CONFIG_CMD_DHCP) + #define BOOT_TARGET_PXE(func) + #define BOOT_TARGET_DHCP(func) func(DHCP, dhcp, na) +#else + #define BOOT_TARGET_PXE(func) + #define BOOT_TARGET_DHCP(func) +#endif + #ifndef BOOT_TARGET_DEVICES #define BOOT_TARGET_DEVICES(func) \ func(ROMUSB, romusb, na) \ func(USB_DFU, usbdfu, na) \ - func(MMC, mmc, 0) \ - func(MMC, mmc, 1) \ - func(MMC, mmc, 2) \ + BOOT_TARGET_MMC(func) \ BOOT_TARGET_DEVICES_USB(func) \ BOOT_TARGET_NVME(func) \ BOOT_TARGET_SCSI(func) \ - func(PXE, pxe, na) \ - func(DHCP, dhcp, na) + BOOT_TARGET_PXE(func) \ + BOOT_TARGET_DHCP(func) #endif #define BOOTM_SIZE __stringify(0x1700000) -- cgit v1.2.3