]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
spl: Migrate SYS_SATA_FAT_BOOT_PARTITION to Kconfig
authorTom Rini <trini@konsulko.com>
Wed, 16 Nov 2022 18:10:35 +0000 (13:10 -0500)
committerTom Rini <trini@konsulko.com>
Mon, 5 Dec 2022 21:06:07 +0000 (16:06 -0500)
This moves SYS_SATA_FAT_BOOT_PARTITION to Kconfig and enforces the
current default via Kconfig rather than C code.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
common/spl/Kconfig
common/spl/spl_sata.c
include/configs/imx6_spl.h

index fef01bdd7daa838f9ed2f393e98737ee47d76e02..c6da4a403e984685a3d2517042485ff4fb325a21 100644 (file)
@@ -1232,6 +1232,11 @@ config SPL_SATA
          expense and power consumption. This enables loading from SATA
          using a configured device.
 
+config SYS_SATA_FAT_BOOT_PARTITION
+       int "Partition on the SATA disk to load U-Boot from"
+       depends on SPL_SATA && SPL_FS_FAT
+       default 1
+
 config SPL_SATA_RAW_U_BOOT_USE_SECTOR
        bool "SATA raw mode: by sector"
        depends on SPL_SATA
index 9ae02730685aa0e4edf7db664b6f9589514c0786..12397f0ae17e8cae86b1d3deb28a99050cecba1d 100644 (file)
 #include <fat.h>
 #include <image.h>
 
-#ifndef CONFIG_SYS_SATA_FAT_BOOT_PARTITION
-#define CONFIG_SYS_SATA_FAT_BOOT_PARTITION     1
-#endif
-
 #ifndef CONFIG_SPL_SATA_RAW_U_BOOT_SECTOR
 /* Dummy value to make the compiler happy */
 #define CONFIG_SPL_SATA_RAW_U_BOOT_SECTOR 0x100
index 3afe418b67dc92b35e2a8ff36ec65e070d02f8fe..f34988fdd74ced5abfe34a31a582d29a855a9dd5 100644 (file)
 
 /* MMC support */
 
-/* SATA support */
-#if defined(CONFIG_SPL_SATA)
-#define CONFIG_SYS_SATA_FAT_BOOT_PARTITION     1
-#endif
-
 #endif
 
 #endif