summaryrefslogtreecommitdiff
path: root/board/freescale/imx8qm_mek
diff options
context:
space:
mode:
Diffstat (limited to 'board/freescale/imx8qm_mek')
-rw-r--r--board/freescale/imx8qm_mek/imx8qm_mek.c13
-rw-r--r--board/freescale/imx8qm_mek/spl.c6
2 files changed, 19 insertions, 0 deletions
diff --git a/board/freescale/imx8qm_mek/imx8qm_mek.c b/board/freescale/imx8qm_mek/imx8qm_mek.c
index c9b9b2547e..c0cae3540f 100644
--- a/board/freescale/imx8qm_mek/imx8qm_mek.c
+++ b/board/freescale/imx8qm_mek/imx8qm_mek.c
@@ -123,10 +123,23 @@ int board_mmc_get_env_dev(int devno)
int board_late_init(void)
{
+ char *fdt_file;
+ bool m4_booted;
+
#ifdef CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
env_set("board_name", "MEK");
env_set("board_rev", "iMX8QM");
#endif
+ fdt_file = env_get("fdt_file");
+ m4_booted = m4_parts_booted();
+
+ if (fdt_file && !strcmp(fdt_file, "undefined")) {
+ if (m4_booted)
+ env_set("fdt_file", "imx8qm-mek-rpmsg.dtb");
+ else
+ env_set("fdt_file", "imx8qm-mek.dtb");
+ }
+
return 0;
}
diff --git a/board/freescale/imx8qm_mek/spl.c b/board/freescale/imx8qm_mek/spl.c
index cb4006eb2a..ba99002cf2 100644
--- a/board/freescale/imx8qm_mek/spl.c
+++ b/board/freescale/imx8qm_mek/spl.c
@@ -12,6 +12,7 @@
#include <dm/uclass-internal.h>
#include <dm/device-internal.h>
#include <dm/lists.h>
+#include <asm/arch/sys_proto.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -37,6 +38,11 @@ void spl_board_init(void)
puts("Normal Boot\n");
}
+void spl_board_prepare_for_boot(void)
+{
+ imx8_power_off_pd_devices(NULL, 0);
+}
+
#ifdef CONFIG_SPL_LOAD_FIT
int board_fit_config_name_match(const char *name)
{