From: Andrew Davis <afd@ti.com>
Date: Fri, 7 Oct 2022 16:27:46 +0000 (-0500)
Subject: arm: mach-k3: common: Set boot_fit on non-GP devices
X-Git-Tag: v2025.01-rc5-pxa1908~1246^2~7
X-Git-Url: http://git.dujemihanovic.xyz/img/html/index.html?a=commitdiff_plain;h=fc95f83ec9543efb32774efda9e4352df49b1132;p=u-boot.git

arm: mach-k3: common: Set boot_fit on non-GP devices

This matches what we did for pre-K3 devices. This allows us to build
boot commands that can check for our device type at runtime.

Signed-off-by: Andrew Davis <afd@ti.com>
---

diff --git a/arch/arm/mach-k3/common.c b/arch/arm/mach-k3/common.c
index 14c37acbce..227706e8dc 100644
--- a/arch/arm/mach-k3/common.c
+++ b/arch/arm/mach-k3/common.c
@@ -606,5 +606,9 @@ int misc_init_r(void)
 			printf("Failed to probe am65_cpsw_nuss driver\n");
 	}
 
+	/* Default FIT boot on non-GP devices */
+	if (get_device_type() != K3_DEVICE_TYPE_GP)
+		env_set("boot_fit", "1");
+
 	return 0;
 }