[PATCH 11/17] spl: Migrate SYS_SATA_FAT_BOOT_PARTITION to Kconfig
Tom Rini
trini at konsulko.com
Wed Nov 16 19:10:35 CET 2022
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 at konsulko.com>
---
common/spl/Kconfig | 5 +++++
common/spl/spl_sata.c | 4 ----
include/configs/imx6_spl.h | 5 -----
3 files changed, 5 insertions(+), 9 deletions(-)
diff --git a/common/spl/Kconfig b/common/spl/Kconfig
index 05181bdba3e1..512c1bc721ac 100644
--- a/common/spl/Kconfig
+++ b/common/spl/Kconfig
@@ -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
diff --git a/common/spl/spl_sata.c b/common/spl/spl_sata.c
index 9ae02730685a..12397f0ae17e 100644
--- a/common/spl/spl_sata.c
+++ b/common/spl/spl_sata.c
@@ -17,10 +17,6 @@
#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
diff --git a/include/configs/imx6_spl.h b/include/configs/imx6_spl.h
index 3afe418b67dc..f34988fdd74c 100644
--- a/include/configs/imx6_spl.h
+++ b/include/configs/imx6_spl.h
@@ -10,11 +10,6 @@
/* MMC support */
-/* SATA support */
-#if defined(CONFIG_SPL_SATA)
-#define CONFIG_SYS_SATA_FAT_BOOT_PARTITION 1
-#endif
-
#endif
#endif
--
2.25.1
More information about the U-Boot
mailing list