Commit 3b0609ca authored by Ye Li's avatar Ye Li
Browse files

MLK-14418-12 imx: mx7dsabresd: Update LCD splash screen codes



Update LCD setup codes to use the parameters structure used for all
i.mx platforms, discard to use videmode environment variable.
Signed-off-by: default avatarYe Li <ye.li@nxp.com>
parent 8ee2d221
......@@ -26,6 +26,7 @@
#include <lcd.h>
#include <mxc_epdc_fb.h>
#endif
#include <asm/imx-common/video.h>
DECLARE_GLOBAL_DATA_PTR;
......@@ -185,27 +186,47 @@ static iomux_v3_cfg_t const pwm_pads[] = {
MX7D_PAD_GPIO1_IO01__GPIO1_IO1 | MUX_PAD_CTRL(NO_PAD_CTRL),
};
static int setup_lcd(void)
void do_enable_parallel_lcd(struct display_info_t const *dev)
{
imx_iomux_v3_setup_multiple_pads(lcd_pads, ARRAY_SIZE(lcd_pads));
imx_iomux_v3_setup_multiple_pads(pwm_pads, ARRAY_SIZE(pwm_pads));
gpio_request(IMX_GPIO_NR(3, 4), "lcd-reset");
/* Reset LCD */
gpio_request(IMX_GPIO_NR(3, 4), "lcd reset");
gpio_direction_output(IMX_GPIO_NR(3, 4) , 0);
udelay(500);
gpio_direction_output(IMX_GPIO_NR(3, 4) , 1);
gpio_request(IMX_GPIO_NR(1, 1), "lcd-pwm");
/* Set Brightness to high */
gpio_request(IMX_GPIO_NR(1, 1), "lcd backlight");
gpio_direction_output(IMX_GPIO_NR(1, 1) , 1);
return 0;
}
struct display_info_t const displays[] = {{
.bus = ELCDIF1_IPS_BASE_ADDR,
.addr = 0,
.pixfmt = 24,
.detect = NULL,
.enable = do_enable_parallel_lcd,
.mode = {
.name = "TFT43AB",
.xres = 480,
.yres = 272,
.pixclock = 108695,
.left_margin = 8,
.right_margin = 4,
.upper_margin = 2,
.lower_margin = 4,
.hsync_len = 41,
.vsync_len = 10,
.sync = 0,
.vmode = FB_VMODE_NONINTERLACED
} } };
size_t display_count = ARRAY_SIZE(displays);
#endif
static void setup_iomux_uart(void)
{
imx_iomux_v3_setup_multiple_pads(uart1_pads, ARRAY_SIZE(uart1_pads));
......@@ -551,10 +572,6 @@ int board_init(void)
setup_gpmi_nand();
#endif
#ifdef CONFIG_VIDEO_MXS
setup_lcd();
#endif
#ifdef CONFIG_FSL_QSPI
board_qspi_init();
#endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment