summaryrefslogtreecommitdiff
path: root/common/fdt_support.c
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2021-05-27 11:40:09 +0200
committerMichal Simek <michal.simek@xilinx.com>2021-06-23 09:48:36 +0200
commitbe2d1a87c73b3f722fc5b0438d780014579a43de (patch)
treeb4cc0298b7829ebe80ee01e9400613393bf17893 /common/fdt_support.c
parent3972ae65e43ad3a2a4f4c96cdaab5ca1863fe234 (diff)
spl: fit: Also record architecture in /fit-images
On ARM64 secure OS can run as 64bit or 32bit that's why it is necessary to record information about architecture that other code can read it and properly pass it to TF-A and start in 64bit or 32bit mode. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common/fdt_support.c')
-rw-r--r--common/fdt_support.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/common/fdt_support.c b/common/fdt_support.c
index a9a32df1e7..240f1e57d1 100644
--- a/common/fdt_support.c
+++ b/common/fdt_support.c
@@ -594,7 +594,7 @@ void fdt_fixup_ethernet(void *fdt)
int fdt_record_loadable(void *blob, u32 index, const char *name,
uintptr_t load_addr, u32 size, uintptr_t entry_point,
- const char *type, const char *os)
+ const char *type, const char *os, const char *arch)
{
int err, node;
@@ -622,6 +622,8 @@ int fdt_record_loadable(void *blob, u32 index, const char *name,
fdt_setprop_string(blob, node, "type", type);
if (os)
fdt_setprop_string(blob, node, "os", os);
+ if (arch)
+ fdt_setprop_string(blob, node, "arch", arch);
return node;
}