Patchwork [U-Boot,2/2] MX5: Switch vision2 to CONFIG_VIDEO

login
register
mail settings
Submitter Stefano Babic
Date Sept. 26, 2011, 8:15 a.m.
Message ID <1317024949-4514-2-git-send-email-sbabic@denx.de>
Download mbox | patch
Permalink /patch/116381/
State Superseded
Delegated to: Anatolij Gustschin
Headers show

Comments

Stefano Babic - Sept. 26, 2011, 8:15 a.m.
Signed-off-by: Stefano Babic <sbabic@denx.de>
CC: Anatolij Gustschin <agust@denx.de>
---
 board/ttcontrol/vision2/vision2.c |   36 +++++++++++++++++++++---------------
 include/configs/vision2.h         |   11 +++++------
 2 files changed, 26 insertions(+), 21 deletions(-)

Patch

diff --git a/board/ttcontrol/vision2/vision2.c b/board/ttcontrol/vision2/vision2.c
index ebca7b6..ca0c100 100644
--- a/board/ttcontrol/vision2/vision2.c
+++ b/board/ttcontrol/vision2/vision2.c
@@ -600,6 +600,21 @@  int board_mmc_init(bd_t *bis)
 }
 #endif
 
+void lcd_enable(void)
+{
+	int ret;
+
+	mxc_request_iomux(MX51_PIN_DI1_PIN2, IOMUX_CONFIG_ALT0);
+	mxc_request_iomux(MX51_PIN_DI1_PIN3, IOMUX_CONFIG_ALT0);
+
+	gpio_set_value(2, 1);
+	mxc_request_iomux(MX51_PIN_GPIO1_2, IOMUX_CONFIG_ALT0);
+
+	ret = mx51_fb_init(&nec_nl6448bc26_09c);
+	if (ret)
+		puts("LCD cannot be configured\n");
+}
+
 int board_early_init_f(void)
 {
 
@@ -636,26 +651,15 @@  static void backlight(int on)
 	}
 }
 
-void lcd_enable(void)
-{
-	int ret;
-
-	mxc_request_iomux(MX51_PIN_DI1_PIN2, IOMUX_CONFIG_ALT0);
-	mxc_request_iomux(MX51_PIN_DI1_PIN3, IOMUX_CONFIG_ALT0);
-
-	gpio_set_value(2, 1);
-	mxc_request_iomux(MX51_PIN_GPIO1_2, IOMUX_CONFIG_ALT0);
-
-	ret = mx51_fb_init(&nec_nl6448bc26_09c);
-	if (ret)
-		puts("LCD cannot be configured\n");
-}
-
 int board_init(void)
 {
 	/* address of boot parameters */
 	gd->bd->bi_boot_params = PHYS_SDRAM_1 + 0x100;
 
+	lcd_enable();
+
+	backlight(1);
+
 	return 0;
 }
 
@@ -676,6 +680,8 @@  int board_late_init(void)
 	udelay(2000);
 #endif
 
+	setenv("stdout", "serial");
+
 	return 0;
 }
 
diff --git a/include/configs/vision2.h b/include/configs/vision2.h
index c07cee4..5f7f8c1 100644
--- a/include/configs/vision2.h
+++ b/include/configs/vision2.h
@@ -47,7 +47,7 @@ 
 /*
  * Size of malloc() pool
  */
-#define CONFIG_SYS_MALLOC_LEN		(2048 * 1024)
+#define CONFIG_SYS_MALLOC_LEN		(10 * 1024 * 1024)
 
 /*
  * Hardware drivers
@@ -234,12 +234,11 @@ 
  * Framebuffer and LCD
  */
 #define CONFIG_PREBOOT
-#define CONFIG_LCD
+#define CONFIG_VIDEO
 #define CONFIG_VIDEO_MX5
-#define CONFIG_SYS_CONSOLE_ENV_OVERWRITE
-#define CONFIG_SYS_CONSOLE_OVERWRITE_ROUTINE
-#define CONFIG_SYS_CONSOLE_IS_IN_ENV
-#define LCD_BPP		LCD_COLOR16
+#define CONFIG_CFB_CONSOLE
+#define CONFIG_VGA_AS_SINGLE_DEVICE
+#define CONFIG_VIDEO_BMP_RLE8
 #define CONFIG_SPLASH_SCREEN
 #define CONFIG_CMD_BMP
 #define CONFIG_BMP_16BPP