]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
config_distro_bootcmd: make possible to substitute 'part list' in distro_bootcmd
authorPascal Zimmermann <pzimmermann@dh-electronics.com>
Thu, 27 Mar 2025 14:38:42 +0000 (15:38 +0100)
committerPatrice Chotard <patrice.chotard@foss.st.com>
Mon, 5 May 2025 13:51:46 +0000 (15:51 +0200)
Make it possible to substitute the 'part list' command inside
'scan_dev_for_boot_part' with a custom board specific implementation.

For this the new define 'SCAN_DEV_FOR_BOOT_PARTS' is introduced.

Signed-off-by: Pascal Zimmermann <pzimmermann@dh-electronics.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
include/config_distro_bootcmd.h

index 8ac3a4feeb88264eeb69f5fb1b6888cc335478d1..7b6ac6eed9dd43fa658310b88993a5cbe0d91004 100644 (file)
 #define SCAN_DEV_FOR_EFI
 #endif
 
+#ifndef SCAN_DEV_FOR_BOOT_PARTS
+#define SCAN_DEV_FOR_BOOT_PARTS \
+       "part list ${devtype} ${devnum} -bootable devplist; "
+#endif
+
 #ifdef CONFIG_SATA
 #define BOOTENV_SHARED_SATA    BOOTENV_SHARED_BLKDEV(sata)
 #define BOOTENV_DEV_SATA       BOOTENV_DEV_BLKDEV
                "\0"                                                      \
        \
        "scan_dev_for_boot_part="                                         \
-               "part list ${devtype} ${devnum} -bootable devplist; "     \
+               SCAN_DEV_FOR_BOOT_PARTS                                   \
                "env exists devplist || setenv devplist 1; "              \
                "for distro_bootpart in ${devplist}; do "                 \
                        "if fstype ${devtype} "                           \