ARM: UniPhier: move UART pin settings to SPL
[oweals/u-boot.git] / arch / arm / mach-uniphier / spl.c
1 /*
2  * Copyright (C) 2013-2015 Panasonic Corporation
3  *   Author: Masahiro Yamada <yamada.m@jp.panasonic.com>
4  *
5  * SPDX-License-Identifier:     GPL-2.0+
6  */
7
8 #include <common.h>
9 #include <spl.h>
10 #include <linux/compiler.h>
11 #include <mach/led.h>
12 #include <mach/board.h>
13
14 void __weak bcu_init(void)
15 {
16 };
17 void sbc_init(void);
18 void sg_init(void);
19 void pll_init(void);
20 void pin_init(void);
21 void memconf_init(void);
22 void early_clkrst_init(void);
23 void early_pin_init(void);
24 int umc_init(void);
25 void enable_dpll_ssc(void);
26
27 void spl_board_init(void)
28 {
29         bcu_init();
30
31         sbc_init();
32
33         sg_init();
34
35         uniphier_board_reset();
36
37         pll_init();
38
39         uniphier_board_init();
40
41         led_write(L, 0, , );
42
43         memconf_init();
44
45         led_write(L, 1, , );
46
47         early_clkrst_init();
48
49         led_write(L, 2, , );
50
51         early_pin_init();
52
53         led_write(L, 3, , );
54
55         {
56                 int res;
57
58                 res = umc_init();
59                 if (res < 0) {
60                         while (1)
61                                 ;
62                 }
63         }
64         led_write(L, 4, , );
65
66         enable_dpll_ssc();
67
68         led_write(L, 5, , );
69 }