1 // SPDX-License-Identifier: GPL-2.0+
3 * Freescale MX23EVK board
5 * (C) Copyright 2013 O.S. Systems Software LTDA.
7 * Author: Otavio Salvador <otavio@ossystems.com.br>
10 * Copyright (C) 2011 Marek Vasut <marek.vasut@gmail.com>
11 * on behalf of DENX Software Engineering GmbH
16 #include <asm/global_data.h>
18 #include <asm/arch/imx-regs.h>
19 #include <asm/arch/clock.h>
20 #include <asm/arch/iomux-mx23.h>
21 #include <asm/arch/sys_proto.h>
23 DECLARE_GLOBAL_DATA_PTR;
28 int board_early_init_f(void)
30 /* IO0 clock at 480MHz */
31 mxs_set_ioclk(MXC_IOCLK0, 480000);
33 /* SSP0 clock at 96MHz */
34 mxs_set_sspclk(MXC_SSPCLK0, 96000, 0);
37 gpio_direction_output(MX23_PAD_LCD_RESET__GPIO_1_18, 1);
39 /* Set contrast to maximum */
40 gpio_direction_output(MX23_PAD_PWM2__GPIO_1_28, 1);
47 return mxs_dram_init();
52 /* Adress of boot parameters */
53 gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;