blob: f7d5b4870c428ac6fd044c761aea0383343a1708 [file] [log] [blame]
Masahiro Yamada019df872015-09-22 00:27:41 +09001/*
2 * Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
3 *
4 * SPDX-License-Identifier: GPL-2.0+
5 */
6
7#include <common.h>
8#include <spl.h>
Masahiro Yamada107b3fb2016-01-09 01:51:13 +09009
10#include "../init.h"
11#include "../micro-support-card.h"
Masahiro Yamada019df872015-09-22 00:27:41 +090012
Masahiro Yamada5b660062016-03-30 20:17:02 +090013int uniphier_pxs2_init(const struct uniphier_board_data *bd)
Masahiro Yamada019df872015-09-22 00:27:41 +090014{
Masahiro Yamada15607d02016-01-09 01:51:14 +090015 int ret;
16
Masahiro Yamada9e3bb842017-01-15 14:59:05 +090017 uniphier_pxs2_sbc_init();
Masahiro Yamada019df872015-09-22 00:27:41 +090018
Masahiro Yamada019df872015-09-22 00:27:41 +090019 support_card_init();
20
21 led_puts("L0");
22
Masahiro Yamada8d6c99c2017-01-15 14:59:04 +090023 uniphier_memconf_3ch_init(bd);
Masahiro Yamada019df872015-09-22 00:27:41 +090024
25 led_puts("L1");
26
Masahiro Yamada78c627c2017-01-15 14:59:03 +090027 uniphier_sld3_early_clk_init();
28 uniphier_pxs2_dram_clk_init();
Masahiro Yamada019df872015-09-22 00:27:41 +090029
30 led_puts("L2");
31
32 led_puts("L3");
33
34#ifdef CONFIG_SPL_SERIAL_SUPPORT
35 preloader_console_init();
36#endif
37
38 led_puts("L4");
39
Masahiro Yamada5b660062016-03-30 20:17:02 +090040 ret = uniphier_pxs2_umc_init(bd);
Masahiro Yamada15607d02016-01-09 01:51:14 +090041 if (ret)
42 return ret;
43
44 led_puts("L5");
45
Masahiro Yamada019df872015-09-22 00:27:41 +090046 return 0;
47}