summaryrefslogtreecommitdiffstats
path: root/include/fdt_support.h
diff options
context:
space:
mode:
authorJ. German Rivera <German.Rivera@freescale.com>2014-06-23 15:15:55 -0700
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2014-07-03 08:40:58 +0200
commitb940ca64b22ba8980fd4ec8dda028f6b1a2ed79d (patch)
treeb10ed6b9111d3a6522957b1a85eed5492f09f65a /include/fdt_support.h
parent2f78eae5064728d6cd907148cfeaf8ba3e63b0ef (diff)
downloadblackbird-obmc-uboot-b940ca64b22ba8980fd4ec8dda028f6b1a2ed79d.tar.gz
blackbird-obmc-uboot-b940ca64b22ba8980fd4ec8dda028f6b1a2ed79d.zip
armv8/fsl-lsch3: Add support to load and start MC Firmware
Adding support to load and start the Layerscape Management Complex (MC) firmware. First, the MC GCR register is set to 0 to reset all cores. MC firmware and DPL images are copied from their location in NOR flash to DDR. MC registers are updated with the location of these images. Deasserting the reset bit of MC GCR register releases core 0 to run. Core 1 will be released by MC firmware. Stop bits are not touched for this step. U-boot waits for MC until it boots up. In case of a failure, device tree is updated accordingly. The MC firmware image uses FIT format. Signed-off-by: J. German Rivera <German.Rivera@freescale.com> Signed-off-by: York Sun <yorksun@freescale.com> Signed-off-by: Lijun Pan <Lijun.Pan@freescale.com> Signed-off-by: Shruti Kanetkar <Shruti@Freescale.com>
Diffstat (limited to 'include/fdt_support.h')
-rw-r--r--include/fdt_support.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/include/fdt_support.h b/include/fdt_support.h
index 21d7b44453..fd44d7e2f6 100644
--- a/include/fdt_support.h
+++ b/include/fdt_support.h
@@ -113,17 +113,25 @@ static inline int fdt_status_disabled(void *fdt, int nodeoffset)
{
return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_DISABLED, 0);
}
+static inline int fdt_status_fail(void *fdt, int nodeoffset)
+{
+ return fdt_set_node_status(fdt, nodeoffset, FDT_STATUS_FAIL, 0);
+}
-int fdt_set_status_by_alias(void *fdt, const char* alias,
+int fdt_set_status_by_alias(void *fdt, const char *alias,
enum fdt_status status, unsigned int error_code);
-static inline int fdt_status_okay_by_alias(void *fdt, const char* alias)
+static inline int fdt_status_okay_by_alias(void *fdt, const char *alias)
{
return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_OKAY, 0);
}
-static inline int fdt_status_disabled_by_alias(void *fdt, const char* alias)
+static inline int fdt_status_disabled_by_alias(void *fdt, const char *alias)
{
return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_DISABLED, 0);
}
+static inline int fdt_status_fail_by_alias(void *fdt, const char *alias)
+{
+ return fdt_set_status_by_alias(fdt, alias, FDT_STATUS_FAIL, 0);
+}
#endif /* ifdef CONFIG_OF_LIBFDT */
OpenPOWER on IntegriCloud