]>
git.ipfire.org Git - people/ms/u-boot.git/blob - arch/arm/mach-rockchip/rk3368-board-spl.c
2 * (C) Copyright 2017 Theobroma Systems Design und Consulting GmbH
4 * SPDX-License-Identifier: GPL-2.0+
8 #include <debug_uart.h>
10 #include <dm/pinctrl.h>
14 #include <asm/arch/cru_rk3368.h>
15 #include <asm/arch/grf_rk3368.h>
16 #include <asm/arch/hardware.h>
17 #include <asm/arch/periph.h>
18 #include <asm/arch/timer.h>
20 DECLARE_GLOBAL_DATA_PTR
;
22 void board_debug_uart_init(void)
26 void board_init_f(ulong dummy
)
28 struct udevice
*pinctrl
;
32 ret
= spl_early_init();
34 debug("spl_early_init() failed: %d\n", ret
);
38 /* Set up our preloader console */
39 ret
= uclass_get_device(UCLASS_PINCTRL
, 0, &pinctrl
);
41 error("%s: pinctrl init failed: %d\n", __func__
, ret
);
45 ret
= pinctrl_request_noflags(pinctrl
, PERIPH_ID_UART0
);
47 error("%s: failed to set up console UART\n", __func__
);
51 preloader_console_init();
53 ret
= uclass_get_device(UCLASS_RAM
, 0, &dev
);
55 debug("DRAM init failed: %d\n", ret
);
60 u32
spl_boot_mode(const u32 boot_device
)
62 return MMCSD_MODE_RAW
;
65 u32
spl_boot_device(void)
67 return BOOT_DEVICE_MMC1
;
70 #ifdef CONFIG_SPL_LOAD_FIT
71 int board_fit_config_name_match(const char *name
)
73 /* Just empty function now - can't decide what to choose */
74 debug("%s: %s\n", __func__
, name
);