From b1200eb220e35d9f53adbb5feb1dc4d381d4f616 Mon Sep 17 00:00:00 2001 From: Ye Li Date: Thu, 10 Mar 2016 17:18:57 +0800 Subject: MLK-12531 mx6sxsabresd: Add CM4 fast boot up demo This is a demo that CM4 will boot up by u-boot without typing any command. It boots up at u-boot early init, try to minimize the time from power up to the CM4 running. Since CM4 runs on QSPI NOR XIP, we have to disable the QSPI driver in u-boot to avoid conflict. RDC for shared GPIO1 is added, but not enabled, because the kernel is not ready for shared GPIO1. Users can uncomment the CONFIG_IMX_RDC to enable it. Some legacy codes in mx6sxsabreauto are removed. We only need this work on mx6sxsabresd as a demo. Signed-off-by: Ye Li (cherry picked from commit f66842f79d4e33ace45762466eed23a86d367642) --- board/freescale/mx6sxsabresd/mx6sxsabresd.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'board/freescale') diff --git a/board/freescale/mx6sxsabresd/mx6sxsabresd.c b/board/freescale/mx6sxsabresd/mx6sxsabresd.c index ebb837b..1f47c5d 100644 --- a/board/freescale/mx6sxsabresd/mx6sxsabresd.c +++ b/board/freescale/mx6sxsabresd/mx6sxsabresd.c @@ -31,6 +31,11 @@ #include #include +#ifdef CONFIG_IMX_RDC +#include +#include +#endif + DECLARE_GLOBAL_DATA_PTR; #define UART_PAD_CTRL (PAD_CTL_PKE | PAD_CTL_PUE | \ @@ -442,8 +447,22 @@ int board_phy_config(struct phy_device *phydev) return 0; } +#ifdef CONFIG_IMX_RDC +static rdc_peri_cfg_t const shared_resources[] = { + (RDC_PER_GPIO1 | RDC_DOMAIN(0) | RDC_DOMAIN(1)), +}; +#endif + int board_early_init_f(void) { +#ifdef CONFIG_IMX_RDC + imx_rdc_setup_peripherals(shared_resources, ARRAY_SIZE(shared_resources)); +#endif + +#ifdef CONFIG_SYS_AUXCORE_FASTUP + arch_auxiliary_core_up(0, CONFIG_SYS_AUXCORE_BOOTDATA); +#endif + setup_iomux_uart(); return 0; -- cgit v1.1