mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-06-09 23:36:03 +09:00
dm: arm: imx: cx9020: migrate to dm_video
Enable DM_VIDEO in config and don't overwrite console so it can be set from environment Acked-by: Patrick Bruenn <p.bruenn@beckhoff.com> Signed-off-by: Steffen Dirkwinkel <s.dirkwinkel@beckhoff.com>
This commit is contained in:
parent
c11599b473
commit
29771c2c39
|
@ -4,4 +4,4 @@
|
||||||
# Patrick Bruenn <p.bruenn@beckhoff.com>
|
# Patrick Bruenn <p.bruenn@beckhoff.com>
|
||||||
|
|
||||||
obj-y += mx53cx9020.o
|
obj-y += mx53cx9020.o
|
||||||
obj-$(CONFIG_VIDEO) += mx53cx9020_video.o
|
obj-$(CONFIG_DM_VIDEO) += mx53cx9020_video.o
|
||||||
|
|
|
@ -23,8 +23,6 @@
|
||||||
#include <mmc.h>
|
#include <mmc.h>
|
||||||
#include <fsl_esdhc.h>
|
#include <fsl_esdhc.h>
|
||||||
#include <asm/gpio.h>
|
#include <asm/gpio.h>
|
||||||
#include <linux/fb.h>
|
|
||||||
#include <ipu_pixfmt.h>
|
|
||||||
#include <input.h>
|
#include <input.h>
|
||||||
#include <fs.h>
|
#include <fs.h>
|
||||||
#include <dm/platform_data/serial_mxc.h>
|
#include <dm/platform_data/serial_mxc.h>
|
||||||
|
@ -232,15 +230,6 @@ int board_early_init_f(void)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Do not overwrite the console
|
|
||||||
* Use always serial for U-Boot console
|
|
||||||
*/
|
|
||||||
int overwrite_console(void)
|
|
||||||
{
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
int board_init(void)
|
int board_init(void)
|
||||||
{
|
{
|
||||||
gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
|
gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
|
||||||
|
|
|
@ -8,29 +8,34 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <common.h>
|
#include <common.h>
|
||||||
#include <linux/list.h>
|
|
||||||
#include <asm/gpio.h>
|
|
||||||
#include <asm/arch/iomux-mx53.h>
|
#include <asm/arch/iomux-mx53.h>
|
||||||
#include <linux/fb.h>
|
#include <asm/gpio.h>
|
||||||
#include <ipu_pixfmt.h>
|
#include <asm/mach-imx/video.h>
|
||||||
|
|
||||||
#define CX9020_DVI_PWD IMX_GPIO_NR(6, 1)
|
#define CX9020_DVI_PWD IMX_GPIO_NR(6, 1)
|
||||||
|
|
||||||
static struct fb_videomode const vga_640x480 = {
|
struct display_info_t const displays[] = {{
|
||||||
.name = "VESA_VGA_640x480",
|
.bus = -1,
|
||||||
.refresh = 60,
|
.addr = 0,
|
||||||
.xres = 640,
|
.pixfmt = IPU_PIX_FMT_RGB24,
|
||||||
.yres = 480,
|
.detect = NULL,
|
||||||
.pixclock = 39721, /* picosecond (25.175 MHz) */
|
.enable = NULL,
|
||||||
.left_margin = 40,
|
.mode = {
|
||||||
.right_margin = 60,
|
.name = "DVI",
|
||||||
.upper_margin = 10,
|
.refresh = 60,
|
||||||
.lower_margin = 10,
|
.xres = 640,
|
||||||
.hsync_len = 20,
|
.yres = 480,
|
||||||
.vsync_len = 10,
|
.pixclock = 39721, /* picosecond (25.175 MHz) */
|
||||||
.sync = 0,
|
.left_margin = 40,
|
||||||
.vmode = FB_VMODE_NONINTERLACED
|
.right_margin = 60,
|
||||||
};
|
.upper_margin = 10,
|
||||||
|
.lower_margin = 10,
|
||||||
|
.hsync_len = 20,
|
||||||
|
.vsync_len = 10,
|
||||||
|
.sync = 0,
|
||||||
|
.vmode = FB_VMODE_NONINTERLACED
|
||||||
|
} } };
|
||||||
|
size_t display_count = ARRAY_SIZE(displays);
|
||||||
|
|
||||||
void setup_iomux_lcd(void)
|
void setup_iomux_lcd(void)
|
||||||
{
|
{
|
||||||
|
@ -39,11 +44,3 @@ void setup_iomux_lcd(void)
|
||||||
gpio_request(CX9020_DVI_PWD, "CX9020_DVI_PWD");
|
gpio_request(CX9020_DVI_PWD, "CX9020_DVI_PWD");
|
||||||
gpio_direction_output(CX9020_DVI_PWD, 1);
|
gpio_direction_output(CX9020_DVI_PWD, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
int board_video_skip(void)
|
|
||||||
{
|
|
||||||
const int ret = ipuv3_fb_init(&vga_640x480, 0, IPU_PIX_FMT_RGB24);
|
|
||||||
if (ret)
|
|
||||||
printf("VESA VG 640x480 cannot be configured: %d\n", ret);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
|
@ -33,6 +33,5 @@ CONFIG_MII=y
|
||||||
CONFIG_PINCTRL=y
|
CONFIG_PINCTRL=y
|
||||||
CONFIG_PINCTRL_IMX5=y
|
CONFIG_PINCTRL_IMX5=y
|
||||||
CONFIG_MXC_UART=y
|
CONFIG_MXC_UART=y
|
||||||
|
CONFIG_DM_VIDEO=y
|
||||||
CONFIG_VIDEO_IPUV3=y
|
CONFIG_VIDEO_IPUV3=y
|
||||||
CONFIG_VIDEO=y
|
|
||||||
# CONFIG_VIDEO_SW_CURSOR is not set
|
|
||||||
|
|
|
@ -159,11 +159,7 @@
|
||||||
#define CONFIG_SYS_MMC_ENV_DEV 0
|
#define CONFIG_SYS_MMC_ENV_DEV 0
|
||||||
|
|
||||||
/* Framebuffer and LCD */
|
/* Framebuffer and LCD */
|
||||||
|
#define CONFIG_IMX_VIDEO_SKIP
|
||||||
#define CONFIG_PREBOOT
|
#define CONFIG_PREBOOT
|
||||||
#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE
|
|
||||||
#define CONFIG_VIDEO_BMP_RLE8
|
|
||||||
#define CONFIG_SPLASH_SCREEN
|
|
||||||
#define CONFIG_BMP_16BPP
|
|
||||||
#define CONFIG_VIDEO_LOGO
|
|
||||||
|
|
||||||
#endif /* __CONFIG_H */
|
#endif /* __CONFIG_H */
|
||||||
|
|
Loading…
Reference in New Issue
Block a user