From d73db3042734f8077a5866d9d60d2eeda685b2ec Mon Sep 17 00:00:00 2001
From: =?utf8?q?Pali=20Roh=C3=A1r?= <pali@kernel.org>
Date: Fri, 29 Oct 2021 14:09:48 +0200
Subject: [PATCH] arm: mvebu: Fix booting from SATA
MIME-Version: 1.0
Content-Type: text/plain; charset=utf8
Content-Transfer-Encoding: 8bit

Use proper SATA macro for boot_device switch in spl_boot_device() function.

Signed-off-by: Pali Rohár <pali@kernel.org>
Fixes: 2226ca173486 ("arm: mvebu: Load U-Boot proper binary in SPL code based on kwbimage header")
---
 arch/arm/mach-mvebu/spl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-mvebu/spl.c b/arch/arm/mach-mvebu/spl.c
index cad3f0a488..73c4b9af3e 100644
--- a/arch/arm/mach-mvebu/spl.c
+++ b/arch/arm/mach-mvebu/spl.c
@@ -199,8 +199,8 @@ u32 spl_boot_device(void)
 		return BOOT_DEVICE_MMC1;
 #endif
 #ifdef CONFIG_SPL_SATA
-	case BOOT_FROM_SATA:
-		return BOOT_FROM_SATA;
+	case BOOT_DEVICE_SATA:
+		return BOOT_DEVICE_SATA;
 #endif
 #ifdef CONFIG_SPL_SPI_FLASH_SUPPORT
 	case BOOT_DEVICE_SPI:
-- 
2.39.5