blob: 8645bdc795be6e09d4ec1865bee1f38c5c4c2920 [file] [log] [blame]
Stefan Roeseb1ad6c62016-08-15 13:50:49 +02001/*
2 * Copyright (C) 2016 Stefan Roese <sr@denx.de>
3 *
4 * SPDX-License-Identifier: GPL-2.0+
5 */
6
7#include <common.h>
8#include <nuvoton_nct6102d.h>
9#include <asm/gpio.h>
10#include <asm/ibmpc.h>
11#include <asm/pnp_def.h>
12
13int board_early_init_f(void)
14{
15#ifdef CONFIG_INTERNAL_UART
16 /* Disable the legacy UART which is enabled per default */
17 nct6102d_uarta_disable();
18#else
19 /*
20 * The FSP enables the BayTrail internal legacy UART (again).
21 * Disable it again, so that the Nuvoton one can be used.
22 */
23 setup_internal_uart(0);
24#endif
25
26 /* Disable the watchdog which is enabled per default */
27 nct6102d_wdt_disable();
28
29 return 0;
30}