aboutsummaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2022-10-30 17:16:35 -0400
committerTom Rini <trini@konsulko.com>2022-10-30 17:16:35 -0400
commit218e2c45af83f2cb7b1374b9023b4ced6eb0bb77 (patch)
treee78dcbb902ebca32f6048b74e67414419dc4edab /board
parent6f02819cceb19c334f1dbd6eccefb4ccfae319f9 (diff)
parentb86986c7b314f1378ca5be8df49310a6ce7302f8 (diff)
downloadu-boot-218e2c45af83f2cb7b1374b9023b4ced6eb0bb77.zip
u-boot-218e2c45af83f2cb7b1374b9023b4ced6eb0bb77.tar.gz
u-boot-218e2c45af83f2cb7b1374b9023b4ced6eb0bb77.tar.bz2
Merge tag 'video-20221030' of https://source.denx.de/u-boot/custodians/u-boot-videoWIP/30Oct2022
- fix [hv]sync active vs back porch in dw_mipi_dsi - simplefb rotation support - support splash as raw image from MMC - enhancements to Truetype console (multiple fonts and sizes) - drop old LCD support
Diffstat (limited to 'board')
-rw-r--r--board/BuR/brxre1/board.c9
-rw-r--r--board/BuR/common/br_resetc.c6
-rw-r--r--board/BuR/common/bur_common.h6
-rw-r--r--board/BuR/common/common.c225
-rw-r--r--board/BuS/eb_cpu5282/eb_cpu5282.c82
-rw-r--r--board/aristainetos/aristainetos.c4
-rw-r--r--board/atmel/at91sam9261ek/at91sam9261ek.c95
-rw-r--r--board/atmel/at91sam9263ek/at91sam9263ek.c108
-rw-r--r--board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c103
-rw-r--r--board/atmel/at91sam9n12ek/at91sam9n12ek.c64
-rw-r--r--board/atmel/at91sam9rlek/at91sam9rlek.c88
-rw-r--r--board/atmel/at91sam9x5ek/at91sam9x5ek.c2
-rw-r--r--board/atmel/common/Makefile2
-rw-r--r--board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c2
-rw-r--r--board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c2
-rw-r--r--board/atmel/sama5d2_xplained/sama5d2_xplained.c2
-rw-r--r--board/atmel/sama5d3xek/sama5d3xek.c2
-rw-r--r--board/atmel/sama5d4_xplained/sama5d4_xplained.c2
-rw-r--r--board/atmel/sama5d4ek/sama5d4ek.c2
-rw-r--r--board/beckhoff/mx53cx9020/Makefile2
-rw-r--r--board/bluewater/gurnard/gurnard.c5
-rw-r--r--board/bosch/guardian/board.c70
-rw-r--r--board/compal/paz00/paz00.c2
-rw-r--r--board/compulab/common/Makefile1
-rw-r--r--board/compulab/common/omap3_display.c452
-rw-r--r--board/freescale/imx8ulp_evk/imx8ulp_evk.c2
-rw-r--r--board/freescale/mx6ul_14x14_evk/mx6ul_14x14_evk.c2
-rw-r--r--board/ge/mx53ppd/Makefile2
-rw-r--r--board/l+g/vinco/vinco.c1
-rw-r--r--board/menlo/m53menlo/m53menlo.c6
-rw-r--r--board/nvidia/harmony/harmony.c1
-rw-r--r--board/raspberrypi/rpi/rpi.c1
-rw-r--r--board/ronetix/pm9263/pm9263.c112
-rw-r--r--board/samsung/common/board.c5
-rw-r--r--board/samsung/common/misc.c340
-rw-r--r--board/samsung/trats/trats.c1
-rw-r--r--board/samsung/trats2/trats2.c22
-rw-r--r--board/samsung/universal_c210/universal.c2
-rw-r--r--board/st/stm32f746-disco/stm32f746-disco.c1
-rw-r--r--board/technexion/pico-imx7d/README1
-rw-r--r--board/technexion/pico-imx7d/pico-imx7d.c4
-rw-r--r--board/toradex/colibri-imx6ull/colibri-imx6ull.c4
-rw-r--r--board/toradex/colibri_imx7/colibri_imx7.c6
-rw-r--r--board/toradex/common/tdx-common.c2
44 files changed, 29 insertions, 1824 deletions
diff --git a/board/BuR/brxre1/board.c b/board/BuR/brxre1/board.c
index 544e09f..a909104 100644
--- a/board/BuR/brxre1/board.c
+++ b/board/BuR/brxre1/board.c
@@ -164,21 +164,12 @@ int board_late_init(void)
br_resetc_bmode();
/* setup othbootargs for bootvx-command (vxWorks bootline) */
-#ifdef CONFIG_LCD
- snprintf(othbootargs, sizeof(othbootargs),
- "u=vxWorksFTP pw=vxWorks o=0x%08x;0x%08x;0x%08x;0x%08x",
- (u32)gd->fb_base - 0x20,
- (u32)env_get_ulong("vx_memtop", 16, gd->fb_base - 0x20),
- (u32)env_get_ulong("vx_romfsbase", 16, 0),
- (u32)env_get_ulong("vx_romfssize", 16, 0));
-#else
snprintf(othbootargs, sizeof(othbootargs),
"u=vxWorksFTP pw=vxWorks o=0x%08x;0x%08x;0x%08x;0x%08x",
(u32)gd->relocaddr,
(u32)env_get_ulong("vx_memtop", 16, gd->relocaddr),
(u32)env_get_ulong("vx_romfsbase", 16, 0),
(u32)env_get_ulong("vx_romfssize", 16, 0));
-#endif
env_set("othbootargs", othbootargs);
/*
* reset VBAR registers to its reset location, VxWorks 6.9.3.2 does
diff --git a/board/BuR/common/br_resetc.c b/board/BuR/common/br_resetc.c
index 5006687..32f32b6 100644
--- a/board/BuR/common/br_resetc.c
+++ b/board/BuR/common/br_resetc.c
@@ -23,14 +23,8 @@
#define BMODE_PME 12
#define BMODE_DIAG 15
-#if CONFIG_IS_ENABLED(LCD) && !CONFIG_IS_ENABLED(DM_VIDEO)
-#include <lcd.h>
-#define LCD_SETCURSOR(x, y) lcd_position_cursor(x, y)
-#define LCD_PUTS(x) lcd_puts(x)
-#else
#define LCD_SETCURSOR(x, y)
#define LCD_PUTS(x)
-#endif /* CONFIG_LCD */
static const char *bootmodeascii[16] = {
"BOOT", "reserved", "reserved", "reserved",
diff --git a/board/BuR/common/bur_common.h b/board/BuR/common/bur_common.h
index 79c9af1..55d14c2 100644
--- a/board/BuR/common/bur_common.h
+++ b/board/BuR/common/bur_common.h
@@ -11,12 +11,6 @@
#ifndef _BUR_COMMON_H_
#define _BUR_COMMON_H_
-#if !CONFIG_IS_ENABLED(DM_VIDEO)
-#include <../../../drivers/video/ti/am335x-fb.h>
-
-int load_lcdtiming(struct am335x_lcdpanel *panel);
-#endif
-
void br_summaryscreen(void);
void pmicsetup(u32 mpupll, unsigned int bus);
void enable_uart0_pin_mux(void);
diff --git a/board/BuR/common/common.c b/board/BuR/common/common.c
index 78bf7d6..3c78020 100644
--- a/board/BuR/common/common.c
+++ b/board/BuR/common/common.c
@@ -14,7 +14,6 @@
#include <env.h>
#include <fdtdec.h>
#include <i2c.h>
-#include <lcd.h>
#include <asm/global_data.h>
#include <linux/delay.h>
#include "bur_common.h"
@@ -22,230 +21,6 @@
DECLARE_GLOBAL_DATA_PTR;
/* --------------------------------------------------------------------------*/
-#if defined(CONFIG_LCD) && defined(CONFIG_AM335X_LCD) && \
- !defined(CONFIG_DM_VIDEO) && !defined(CONFIG_SPL_BUILD)
-#include <asm/arch/hardware.h>
-#include <asm/arch/cpu.h>
-#include <asm/gpio.h>
-#include <power/tps65217.h>
-#include "../../../drivers/video/ti/am335x-fb.h"
-
-void lcdbacklight(int on)
-{
- unsigned int driver = env_get_ulong("ds1_bright_drv", 16, 0UL);
- unsigned int bright = env_get_ulong("ds1_bright_def", 10, 50);
- unsigned int pwmfrq = env_get_ulong("ds1_pwmfreq", 10, ~0UL);
- unsigned int tmp;
- struct gptimer *timerhw;
-
- if (on)
- bright = bright != ~0UL ? bright : 50;
- else
- bright = 0;
-
- switch (driver) {
- case 2:
- timerhw = (struct gptimer *)DM_TIMER5_BASE;
- break;
- default:
- timerhw = (struct gptimer *)DM_TIMER6_BASE;
- }
-
- switch (driver) {
- case 0: /* PMIC LED-Driver */
- /* brightness level */
- tps65217_reg_write(TPS65217_PROT_LEVEL_NONE,
- TPS65217_WLEDCTRL2, bright, 0xFF);
- /* current sink */
- tps65217_reg_write(TPS65217_PROT_LEVEL_NONE,
- TPS65217_WLEDCTRL1,
- bright != 0 ? 0x0A : 0x02,
- 0xFF);
- break;
- case 1:
- case 2: /* PWM using timer */
- if (pwmfrq != ~0UL) {
- timerhw->tiocp_cfg = TCFG_RESET;
- udelay(10);
- while (timerhw->tiocp_cfg & TCFG_RESET)
- ;
- tmp = ~0UL-(V_OSCK/pwmfrq); /* bottom value */
- timerhw->tldr = tmp;
- timerhw->tcrr = tmp;
- tmp = tmp + ((V_OSCK/pwmfrq)/100) * bright;
- timerhw->tmar = tmp;
- timerhw->tclr = (TCLR_PT | (2 << TCLR_TRG_SHIFT) |
- TCLR_CE | TCLR_AR | TCLR_ST);
- } else {
- puts("invalid pwmfrq in env/dtb! skip PWM-setup.\n");
- }
- break;
- default:
- puts("no suitable backlightdriver in env/dtb!\n");
- break;
- }
-}
-
-int load_lcdtiming(struct am335x_lcdpanel *panel)
-{
- struct am335x_lcdpanel pnltmp;
-
- pnltmp.hactive = env_get_ulong("ds1_hactive", 10, ~0UL);
- pnltmp.vactive = env_get_ulong("ds1_vactive", 10, ~0UL);
- pnltmp.bpp = env_get_ulong("ds1_bpp", 10, ~0UL);
- pnltmp.hfp = env_get_ulong("ds1_hfp", 10, ~0UL);
- pnltmp.hbp = env_get_ulong("ds1_hbp", 10, ~0UL);
- pnltmp.hsw = env_get_ulong("ds1_hsw", 10, ~0UL);
- pnltmp.vfp = env_get_ulong("ds1_vfp", 10, ~0UL);
- pnltmp.vbp = env_get_ulong("ds1_vbp", 10, ~0UL);
- pnltmp.vsw = env_get_ulong("ds1_vsw", 10, ~0UL);
- pnltmp.pxl_clk = env_get_ulong("ds1_pxlclk", 10, ~0UL);
- pnltmp.pol = env_get_ulong("ds1_pol", 16, ~0UL);
- pnltmp.pup_delay = env_get_ulong("ds1_pupdelay", 10, ~0UL);
- pnltmp.pon_delay = env_get_ulong("ds1_tondelay", 10, ~0UL);
- panel_info.vl_rot = env_get_ulong("ds1_rotation", 10, 0);
-
- if (
- ~0UL == (pnltmp.hactive) ||
- ~0UL == (pnltmp.vactive) ||
- ~0UL == (pnltmp.bpp) ||
- ~0UL == (pnltmp.hfp) ||
- ~0UL == (pnltmp.hbp) ||
- ~0UL == (pnltmp.hsw) ||
- ~0UL == (pnltmp.vfp) ||
- ~0UL == (pnltmp.vbp) ||
- ~0UL == (pnltmp.vsw) ||
- ~0UL == (pnltmp.pxl_clk) ||
- ~0UL == (pnltmp.pol) ||
- ~0UL == (pnltmp.pup_delay) ||
- ~0UL == (pnltmp.pon_delay)
- ) {
- puts("lcd-settings in env/dtb incomplete!\n");
- printf("display-timings:\n"
- "================\n"
- "hactive: %d\n"
- "vactive: %d\n"
- "bpp : %d\n"
- "hfp : %d\n"
- "hbp : %d\n"
- "hsw : %d\n"
- "vfp : %d\n"
- "vbp : %d\n"
- "vsw : %d\n"
- "pxlclk : %d\n"
- "pol : 0x%08x\n"
- "pondly : %d\n",
- pnltmp.hactive, pnltmp.vactive, pnltmp.bpp,
- pnltmp.hfp, pnltmp.hbp, pnltmp.hsw,
- pnltmp.vfp, pnltmp.vbp, pnltmp.vsw,
- pnltmp.pxl_clk, pnltmp.pol, pnltmp.pon_delay);
-
- return -1;
- }
- debug("lcd-settings in env complete, taking over.\n");
- memcpy((void *)panel,
- (void *)&pnltmp,
- sizeof(struct am335x_lcdpanel));
-
- return 0;
-}
-
-static void br_summaryscreen_printenv(char *prefix,
- char *name, char *altname,
- char *suffix)
-{
- char *envval = env_get(name);
- if (0 != envval) {
- lcd_printf("%s %s %s", prefix, envval, suffix);
- } else if (0 != altname) {
- envval = env_get(altname);
- if (0 != envval)
- lcd_printf("%s %s %s", prefix, envval, suffix);
- } else {
- lcd_printf("\n");
- }
-}
-
-void br_summaryscreen(void)
-{
- br_summaryscreen_printenv(" - B&R -", "br_orderno", 0, "-\n");
- br_summaryscreen_printenv(" Serial/Rev :", "br_serial", 0, "\n");
- br_summaryscreen_printenv(" MAC1 :", "br_mac1", "ethaddr", "\n");
- br_summaryscreen_printenv(" MAC2 :", "br_mac2", 0, "\n");
- lcd_puts(" Bootloader : " PLAIN_VERSION "\n");
- lcd_puts("\n");
-}
-
-void lcdpower(int on)
-{
- u32 pin, swval, i;
- char buf[16] = { 0 };
-
- pin = env_get_ulong("ds1_pwr", 16, ~0UL);
-
- if (pin == ~0UL) {
- puts("no pwrpin in dtb/env, cannot powerup display!\n");
- return;
- }
-
- for (i = 0; i < 3; i++) {
- if (pin != 0) {
- snprintf(buf, sizeof(buf), "ds1_pwr#%d", i);
- if (gpio_request(pin & 0x7F, buf) != 0) {
- printf("%s: not able to request gpio %s",
- __func__, buf);
- continue;
- }
- swval = pin & 0x80 ? 0 : 1;
- if (on)
- gpio_direction_output(pin & 0x7F, swval);
- else
- gpio_direction_output(pin & 0x7F, !swval);
-
- debug("switched pin %d to %d\n", pin & 0x7F, swval);
- }
- pin >>= 8;
- }
-}
-
-vidinfo_t panel_info = {
- .vl_col = 1366, /*
- * give full resolution for allocating enough
- * memory
- */
- .vl_row = 768,
- .vl_bpix = 5,
- .priv = 0
-};
-
-void lcd_ctrl_init(void *lcdbase)
-{
- struct am335x_lcdpanel lcd_panel;
-
- memset(&lcd_panel, 0, sizeof(struct am335x_lcdpanel));
- if (load_lcdtiming(&lcd_panel) != 0)
- return;
-
- lcd_panel.panel_power_ctrl = &lcdpower;
-
- if (0 != am335xfb_init(&lcd_panel))
- printf("ERROR: failed to initialize video!");
- /*
- * modifiy panel info to 'real' resolution, to operate correct with
- * lcd-framework.
- */
- panel_info.vl_col = lcd_panel.hactive;
- panel_info.vl_row = lcd_panel.vactive;
-
- lcd_set_flush_dcache(1);
-}
-
-void lcd_enable(void)
-{
- br_summaryscreen();
- lcdbacklight(1);
-}
-#endif /* CONFIG_LCD */
int ft_board_setup(void *blob, struct bd_info *bd)
{
diff --git a/board/BuS/eb_cpu5282/eb_cpu5282.c b/board/BuS/eb_cpu5282/eb_cpu5282.c
index b739bc3..173350b 100644
--- a/board/BuS/eb_cpu5282/eb_cpu5282.c
+++ b/board/BuS/eb_cpu5282/eb_cpu5282.c
@@ -21,11 +21,6 @@
DECLARE_GLOBAL_DATA_PTR;
-#if IS_ENABLED(CONFIG_VIDEO_VCXK)
-extern unsigned long display_width;
-extern unsigned long display_height;
-#endif
-
/*---------------------------------------------------------------------------*/
int checkboard (void)
@@ -184,84 +179,7 @@ void __led_set(led_id_t mask, int state)
MCFGPTA_GPTPORT &= ~(1 << 3);
}
-#if IS_ENABLED(CONFIG_VIDEO_VCXK)
-int drv_video_init(void)
-{
- char *s;
-#ifdef CONFIG_SPLASH_SCREEN
- unsigned long splash;
-#endif
- printf("Init Video as ");
- s = env_get("displaywidth");
- if (s != NULL)
- display_width = dectoul(s, NULL);
- else
- display_width = 256;
-
- s = env_get("displayheight");
- if (s != NULL)
- display_height = dectoul(s, NULL);
- else
- display_height = 256;
-
- printf("%lu x %lu pixel matrix\n", display_width, display_height);
-
- MCFCCM_CCR &= ~MCFCCM_CCR_SZEN;
- MCFGPIO_PEPAR &= ~MCFGPIO_PEPAR_PEPA2;
-
- vcxk_init(display_width, display_height);
-
-#ifdef CONFIG_SPLASH_SCREEN
- s = env_get("splashimage");
- if (s != NULL) {
- splash = hextoul(s, NULL);
- vcxk_acknowledge_wait();
- video_display_bitmap(splash, 0, 0);
- }
-#endif
- return 0;
-}
-#endif
-
-/*---------------------------------------------------------------------------*/
-
-#if IS_ENABLED(CONFIG_VIDEO_VCXK)
-int do_brightness(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
-{
- int rcode = 0;
- ulong side;
- ulong bright;
-
- switch (argc) {
- case 3:
- side = dectoul(argv[1], NULL);
- bright = dectoul(argv[2], NULL);
- if ((side >= 0) && (side <= 3) &&
- (bright >= 0) && (bright <= 1000)) {
- vcxk_setbrightness(side, bright);
- rcode = 0;
- } else {
- printf("parameters out of range\n");
- printf("Usage:\n%s\n", cmdtp->usage);
- rcode = 1;
- }
- break;
- default:
- printf("Usage:\n%s\n", cmdtp->usage);
- rcode = 1;
- break;
- }
- return rcode;
-}
-
/*---------------------------------------------------------------------------*/
-U_BOOT_CMD(
- bright, 3, 0, do_brightness,
- "sets the display brightness\n",
- " <side> <0..1000>\n side: 0/3=both; 1=first; 2=second\n"
-);
-
-#endif
/* EOF EB+MCF-EV123.c */
diff --git a/board/aristainetos/aristainetos.c b/board/aristainetos/aristainetos.c
index 514cb60..770f3d7 100644
--- a/board/aristainetos/aristainetos.c
+++ b/board/aristainetos/aristainetos.c
@@ -9,6 +9,8 @@
* Author: Fabio Estevam <fabio.estevam@freescale.com>
*/
+#include <common.h>
+#include <bmp_layout.h>
#include <command.h>
#include <image.h>
#include <init.h>
@@ -33,12 +35,12 @@
#include <i2c.h>
#include <micrel.h>
#include <miiphy.h>
-#include <lcd.h>
#include <led.h>
#include <power/pmic.h>
#include <power/regulator.h>
#include <power/da9063_pmic.h>
#include <splash.h>
+#include <video.h>
DECLARE_GLOBAL_DATA_PTR;
diff --git a/board/atmel/at91sam9261ek/at91sam9261ek.c b/board/atmel/at91sam9261ek/at91sam9261ek.c
index 8a7a960..0c53325 100644
--- a/board/atmel/at91sam9261ek/at91sam9261ek.c
+++ b/board/atmel/at91sam9261ek/at91sam9261ek.c
@@ -18,7 +18,6 @@
#include <asm/arch/at91_rstc.h>
#include <asm/arch/clk.h>
#include <asm/arch/gpio.h>
-#include <lcd.h>
#include <atmel_lcdc.h>
#if defined(CONFIG_RESET_PHY_R) && defined(CONFIG_DRIVER_DM9000)
#include <net.h>
@@ -133,97 +132,6 @@ static void at91sam9261ek_dm9000_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-vidinfo_t panel_info = {
- .vl_col = 240,
- .vl_row = 320,
- .vl_clk = 4965000,
- .vl_sync = ATMEL_LCDC_INVLINE_INVERTED |
- ATMEL_LCDC_INVFRAME_INVERTED,
- .vl_bpix = 3,
- .vl_tft = 1,
- .vl_hsync_len = 5,
- .vl_left_margin = 1,
- .vl_right_margin = 33,
- .vl_vsync_len = 1,
- .vl_upper_margin = 1,
- .vl_lower_margin = 0,
- .mmio = ATMEL_BASE_LCDC,
-};
-
-void lcd_enable(void)
-{
- at91_set_gpio_value(AT91_PIN_PA12, 0); /* power up */
-}
-
-void lcd_disable(void)
-{
- at91_set_gpio_value(AT91_PIN_PA12, 1); /* power down */
-}
-
-static void at91sam9261ek_lcd_hw_init(void)
-{
- at91_set_A_periph(AT91_PIN_PB1, 0); /* LCDHSYNC */
- at91_set_A_periph(AT91_PIN_PB2, 0); /* LCDDOTCK */
- at91_set_A_periph(AT91_PIN_PB3, 0); /* LCDDEN */
- at91_set_A_periph(AT91_PIN_PB4, 0); /* LCDCC */
- at91_set_A_periph(AT91_PIN_PB7, 0); /* LCDD2 */
- at91_set_A_periph(AT91_PIN_PB8, 0); /* LCDD3 */
- at91_set_A_periph(AT91_PIN_PB9, 0); /* LCDD4 */
- at91_set_A_periph(AT91_PIN_PB10, 0); /* LCDD5 */
- at91_set_A_periph(AT91_PIN_PB11, 0); /* LCDD6 */
- at91_set_A_periph(AT91_PIN_PB12, 0); /* LCDD7 */
- at91_set_A_periph(AT91_PIN_PB15, 0); /* LCDD10 */
- at91_set_A_periph(AT91_PIN_PB16, 0); /* LCDD11 */
- at91_set_A_periph(AT91_PIN_PB17, 0); /* LCDD12 */
- at91_set_A_periph(AT91_PIN_PB18, 0); /* LCDD13 */
- at91_set_A_periph(AT91_PIN_PB19, 0); /* LCDD14 */
- at91_set_A_periph(AT91_PIN_PB20, 0); /* LCDD15 */
- at91_set_B_periph(AT91_PIN_PB23, 0); /* LCDD18 */
- at91_set_B_periph(AT91_PIN_PB24, 0); /* LCDD19 */
- at91_set_B_periph(AT91_PIN_PB25, 0); /* LCDD20 */
- at91_set_B_periph(AT91_PIN_PB26, 0); /* LCDD21 */
- at91_set_B_periph(AT91_PIN_PB27, 0); /* LCDD22 */
- at91_set_B_periph(AT91_PIN_PB28, 0); /* LCDD23 */
-
- at91_system_clk_enable(AT91_PMC_HCK1);
-
- /* For 9G10EK, let U-Boot allocate the framebuffer in SDRAM */
-#ifdef CONFIG_AT91SAM9261EK
- gd->fb_base = ATMEL_BASE_SRAM;
-#endif
-}
-
-#ifdef CONFIG_LCD_INFO
-#include <nand.h>
-#include <version.h>
-
-void lcd_show_board_info(void)
-{
- ulong dram_size, nand_size;
- int i;
- char temp[32];
-
- lcd_printf ("%s\n", U_BOOT_VERSION);
- lcd_printf ("(C) 2008 ATMEL Corp\n");
- lcd_printf ("at91support@atmel.com\n");
- lcd_printf ("%s CPU at %s MHz\n",
- ATMEL_CPU_NAME,
- strmhz(temp, get_cpu_clk_rate()));
-
- dram_size = 0;
- for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++)
- dram_size += gd->bd->bi_dram[i].size;
- nand_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_NAND_DEVICE; i++)
- nand_size += get_nand_dev_by_index(i)->size;
- lcd_printf (" %ld MB SDRAM, %ld MB NAND\n",
- dram_size >> 20,
- nand_size >> 20 );
-}
-#endif /* CONFIG_LCD_INFO */
-#endif
-
#ifdef CONFIG_DEBUG_UART_BOARD_INIT
void board_debug_uart_init(void)
{
@@ -256,9 +164,6 @@ int board_init(void)
#ifdef CONFIG_DRIVER_DM9000
at91sam9261ek_dm9000_hw_init();
#endif
-#ifdef CONFIG_LCD
- at91sam9261ek_lcd_hw_init();
-#endif
return 0;
}
diff --git a/board/atmel/at91sam9263ek/at91sam9263ek.c b/board/atmel/at91sam9263ek/at91sam9263ek.c
index 86b4050..3e232aa 100644
--- a/board/atmel/at91sam9263ek/at91sam9263ek.c
+++ b/board/atmel/at91sam9263ek/at91sam9263ek.c
@@ -21,7 +21,6 @@
#include <asm/io.h>
#include <asm/arch/gpio.h>
#include <asm/arch/hardware.h>
-#include <lcd.h>
#include <atmel_lcdc.h>
#include <asm/mach-types.h>
@@ -77,110 +76,6 @@ static void at91sam9263ek_nand_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-vidinfo_t panel_info = {
- .vl_col = 240,
- .vl_row = 320,
- .vl_clk = 4965000,
- .vl_sync = ATMEL_LCDC_INVLINE_INVERTED |
- ATMEL_LCDC_INVFRAME_INVERTED,
- .vl_bpix = 3,
- .vl_tft = 1,
- .vl_hsync_len = 5,
- .vl_left_margin = 1,
- .vl_right_margin = 33,
- .vl_vsync_len = 1,
- .vl_upper_margin = 1,
- .vl_lower_margin = 0,
- .mmio = ATMEL_BASE_LCDC,
-};
-
-void lcd_enable(void)
-{
- at91_set_pio_value(AT91_PIO_PORTA, 30, 1); /* power up */
-}
-
-void lcd_disable(void)
-{
- at91_set_pio_value(AT91_PIO_PORTA, 30, 0); /* power down */
-}
-
-static void at91sam9263ek_lcd_hw_init(void)
-{
- at91_set_a_periph(AT91_PIO_PORTC, 1, 0); /* LCDHSYNC */
- at91_set_a_periph(AT91_PIO_PORTC, 2, 0); /* LCDDOTCK */
- at91_set_a_periph(AT91_PIO_PORTC, 3, 0); /* LCDDEN */
- at91_set_b_periph(AT91_PIO_PORTB, 9, 0); /* LCDCC */
- at91_set_a_periph(AT91_PIO_PORTC, 6, 0); /* LCDD2 */
- at91_set_a_periph(AT91_PIO_PORTC, 7, 0); /* LCDD3 */
- at91_set_a_periph(AT91_PIO_PORTC, 8, 0); /* LCDD4 */
- at91_set_a_periph(AT91_PIO_PORTC, 9, 0); /* LCDD5 */
- at91_set_a_periph(AT91_PIO_PORTC, 10, 0); /* LCDD6 */
- at91_set_a_periph(AT91_PIO_PORTC, 11, 0); /* LCDD7 */
- at91_set_a_periph(AT91_PIO_PORTC, 14, 0); /* LCDD10 */
- at91_set_a_periph(AT91_PIO_PORTC, 15, 0); /* LCDD11 */
- at91_set_a_periph(AT91_PIO_PORTC, 16, 0); /* LCDD12 */
- at91_set_b_periph(AT91_PIO_PORTC, 12, 0); /* LCDD13 */
- at91_set_a_periph(AT91_PIO_PORTC, 18, 0); /* LCDD14 */
- at91_set_a_periph(AT91_PIO_PORTC, 19, 0); /* LCDD15 */
- at91_set_a_periph(AT91_PIO_PORTC, 22, 0); /* LCDD18 */
- at91_set_a_periph(AT91_PIO_PORTC, 23, 0); /* LCDD19 */
- at91_set_a_periph(AT91_PIO_PORTC, 24, 0); /* LCDD20 */
- at91_set_b_periph(AT91_PIO_PORTC, 17, 0); /* LCDD21 */
- at91_set_a_periph(AT91_PIO_PORTC, 26, 0); /* LCDD22 */
- at91_set_a_periph(AT91_PIO_PORTC, 27, 0); /* LCDD23 */
-
- at91_periph_clk_enable(ATMEL_ID_LCDC);
- gd->fb_base = ATMEL_BASE_SRAM0;
-}
-
-#ifdef CONFIG_LCD_INFO
-#include <nand.h>
-#include <version.h>
-
-#ifdef CONFIG_MTD_NOR_FLASH
-#include <flash.h>
-#endif
-
-void lcd_show_board_info(void)
-{
- ulong dram_size, nand_size;
-#ifdef CONFIG_MTD_NOR_FLASH
- ulong flash_size;
-#endif
- int i;
- char temp[32];
-
- lcd_printf ("%s\n", U_BOOT_VERSION);
- lcd_printf ("(C) 2008 ATMEL Corp\n");
- lcd_printf ("at91support@atmel.com\n");
- lcd_printf ("%s CPU at %s MHz\n",
- ATMEL_CPU_NAME,
- strmhz(temp, get_cpu_clk_rate()));
-
- dram_size = 0;
- for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++)
- dram_size += gd->bd->bi_dram[i].size;
- nand_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_NAND_DEVICE; i++)
- nand_size += get_nand_dev_by_index(i)->size;
-#ifdef CONFIG_MTD_NOR_FLASH
- flash_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_FLASH_BANKS; i++)
- flash_size += flash_info[i].size;
-#endif
- lcd_printf (" %ld MB SDRAM, %ld MB NAND",
- dram_size >> 20,
- nand_size >> 20 );
-#ifdef CONFIG_MTD_NOR_FLASH
- lcd_printf (",\n %ld MB NOR",
- flash_size >> 20);
-#endif
- lcd_puts ("\n");
-}
-#endif /* CONFIG_LCD_INFO */
-#endif
-
#ifdef CONFIG_DEBUG_UART_BOARD_INIT
void board_debug_uart_init(void)
{
@@ -208,9 +103,6 @@ int board_init(void)
#ifdef CONFIG_USB_OHCI_NEW
at91_uhp_hw_init();
#endif
-#ifdef CONFIG_LCD
- at91sam9263ek_lcd_hw_init();
-#endif
return 0;
}
diff --git a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c
index 347197a..3af7097 100644
--- a/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c
+++ b/board/atmel/at91sam9m10g45ek/at91sam9m10g45ek.c
@@ -18,7 +18,6 @@
#include <asm/arch/at91_common.h>
#include <asm/arch/gpio.h>
#include <asm/arch/clk.h>
-#include <lcd.h>
#include <linux/mtd/rawnand.h>
#include <atmel_lcdc.h>
#include <asm/mach-types.h>
@@ -149,105 +148,6 @@ static void at91sam9m10g45ek_usb_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-
-vidinfo_t panel_info = {
- .vl_col = 480,
- .vl_row = 272,
- .vl_clk = 9000000,
- .vl_sync = ATMEL_LCDC_INVLINE_NORMAL |
- ATMEL_LCDC_INVFRAME_NORMAL,
- .vl_bpix = 3,
- .vl_tft = 1,
- .vl_hsync_len = 45,
- .vl_left_margin = 1,
- .vl_right_margin = 1,
- .vl_vsync_len = 1,
- .vl_upper_margin = 40,
- .vl_lower_margin = 1,
- .mmio = ATMEL_BASE_LCDC,
-};
-
-
-void lcd_enable(void)
-{
- at91_set_A_periph(AT91_PIN_PE6, 1); /* power up */
-}
-
-void lcd_disable(void)
-{
- at91_set_A_periph(AT91_PIN_PE6, 0); /* power down */
-}
-
-static void at91sam9m10g45ek_lcd_hw_init(void)
-{
- at91_set_A_periph(AT91_PIN_PE0, 0); /* LCDDPWR */
- at91_set_A_periph(AT91_PIN_PE2, 0); /* LCDCC */
- at91_set_A_periph(AT91_PIN_PE3, 0); /* LCDVSYNC */
- at91_set_A_periph(AT91_PIN_PE4, 0); /* LCDHSYNC */
- at91_set_A_periph(AT91_PIN_PE5, 0); /* LCDDOTCK */
-
- at91_set_A_periph(AT91_PIN_PE7, 0); /* LCDD0 */
- at91_set_A_periph(AT91_PIN_PE8, 0); /* LCDD1 */
- at91_set_A_periph(AT91_PIN_PE9, 0); /* LCDD2 */
- at91_set_A_periph(AT91_PIN_PE10, 0); /* LCDD3 */
- at91_set_A_periph(AT91_PIN_PE11, 0); /* LCDD4 */
- at91_set_A_periph(AT91_PIN_PE12, 0); /* LCDD5 */
- at91_set_A_periph(AT91_PIN_PE13, 0); /* LCDD6 */
- at91_set_A_periph(AT91_PIN_PE14, 0); /* LCDD7 */
- at91_set_A_periph(AT91_PIN_PE15, 0); /* LCDD8 */
- at91_set_A_periph(AT91_PIN_PE16, 0); /* LCDD9 */
- at91_set_A_periph(AT91_PIN_PE17, 0); /* LCDD10 */
- at91_set_A_periph(AT91_PIN_PE18, 0); /* LCDD11 */
- at91_set_A_periph(AT91_PIN_PE19, 0); /* LCDD12 */
- at91_set_B_periph(AT91_PIN_PE20, 0); /* LCDD13 */
- at91_set_A_periph(AT91_PIN_PE21, 0); /* LCDD14 */
- at91_set_A_periph(AT91_PIN_PE22, 0); /* LCDD15 */
- at91_set_A_periph(AT91_PIN_PE23, 0); /* LCDD16 */
- at91_set_A_periph(AT91_PIN_PE24, 0); /* LCDD17 */
- at91_set_A_periph(AT91_PIN_PE25, 0); /* LCDD18 */
- at91_set_A_periph(AT91_PIN_PE26, 0); /* LCDD19 */
- at91_set_A_periph(AT91_PIN_PE27, 0); /* LCDD20 */
- at91_set_B_periph(AT91_PIN_PE28, 0); /* LCDD21 */
- at91_set_A_periph(AT91_PIN_PE29, 0); /* LCDD22 */
- at91_set_A_periph(AT91_PIN_PE30, 0); /* LCDD23 */
-
- at91_periph_clk_enable(ATMEL_ID_LCDC);
-
- /* board specific(not enough SRAM) */
- gd->fb_base = 0x73E00000;
-}
-
-#ifdef CONFIG_LCD_INFO
-#include <nand.h>
-#include <version.h>
-
-void lcd_show_board_info(void)
-{
- ulong dram_size, nand_size;
- int i;
- char temp[32];
-
- lcd_printf ("%s\n", U_BOOT_VERSION);
- lcd_printf ("(C) 2008 ATMEL Corp\n");
- lcd_printf ("at91support@atmel.com\n");
- lcd_printf ("%s CPU at %s MHz\n",
- ATMEL_CPU_NAME,
- strmhz(temp, get_cpu_clk_rate()));
-
- dram_size = 0;
- for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++)
- dram_size += gd->bd->bi_dram[i].size;
- nand_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_NAND_DEVICE; i++)
- nand_size += get_nand_dev_by_index(i)->size;
- lcd_printf (" %ld MB SDRAM, %ld MB NAND\n",
- dram_size >> 20,
- nand_size >> 20 );
-}
-#endif /* CONFIG_LCD_INFO */
-#endif
-
#ifdef CONFIG_DEBUG_UART_BOARD_INIT
void board_debug_uart_init(void)
{
@@ -276,9 +176,6 @@ int board_init(void)
#ifdef CONFIG_CMD_USB
at91sam9m10g45ek_usb_hw_init();
#endif
-#ifdef CONFIG_LCD
- at91sam9m10g45ek_lcd_hw_init();
-#endif
return 0;
}
diff --git a/board/atmel/at91sam9n12ek/at91sam9n12ek.c b/board/atmel/at91sam9n12ek/at91sam9n12ek.c
index a337db4..5468519 100644
--- a/board/atmel/at91sam9n12ek/at91sam9n12ek.c
+++ b/board/atmel/at91sam9n12ek/at91sam9n12ek.c
@@ -17,15 +17,9 @@
#include <asm/arch/at91_pio.h>
#include <asm/arch/clk.h>
#include <debug_uart.h>
-#include <lcd.h>
#include <atmel_hlcdc.h>
#include <netdev.h>
-#ifdef CONFIG_LCD_INFO
-#include <nand.h>
-#include <version.h>
-#endif
-
DECLARE_GLOBAL_DATA_PTR;
/* ------------------------------------------------------------------------- */
@@ -81,60 +75,6 @@ static void at91sam9n12ek_nand_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-vidinfo_t panel_info = {
- .vl_col = 480,
- .vl_row = 272,
- .vl_clk = 9000000,
- .vl_bpix = LCD_BPP,
- .vl_sync = 0,
- .vl_tft = 1,
- .vl_hsync_len = 5,
- .vl_left_margin = 8,
- .vl_right_margin = 43,
- .vl_vsync_len = 10,
- .vl_upper_margin = 4,
- .vl_lower_margin = 12,
- .mmio = ATMEL_BASE_LCDC,
-};
-
-void lcd_enable(void)
-{
- at91_set_pio_output(AT91_PIO_PORTC, 25, 0); /* power up */
-}
-
-void lcd_disable(void)
-{
- at91_set_pio_output(AT91_PIO_PORTC, 25, 1); /* power down */
-}
-
-#ifdef CONFIG_LCD_INFO
-void lcd_show_board_info(void)
-{
- ulong dram_size, nand_size;
- int i;
- char temp[32];
-
- lcd_printf("%s\n", U_BOOT_VERSION);
- lcd_printf("ATMEL Corp\n");
- lcd_printf("at91@atmel.com\n");
- lcd_printf("%s CPU at %s MHz\n",
- ATMEL_CPU_NAME,
- strmhz(temp, get_cpu_clk_rate()));
-
- dram_size = 0;
- for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++)
- dram_size += gd->bd->bi_dram[i].size;
- nand_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_NAND_DEVICE; i++)
- nand_size += get_nand_dev_by_index(i)->size;
- lcd_printf(" %ld MB SDRAM, %ld MB NAND\n",
- dram_size >> 20,
- nand_size >> 20);
-}
-#endif /* CONFIG_LCD_INFO */
-#endif /* CONFIG_LCD */
-
#ifdef CONFIG_USB_ATMEL
void at91sam9n12ek_usb_hw_init(void)
{
@@ -165,10 +105,6 @@ int board_init(void)
at91sam9n12ek_nand_hw_init();
#endif
-#ifdef CONFIG_LCD
- at91_lcd_hw_init();
-#endif
-
#ifdef CONFIG_USB_ATMEL
at91sam9n12ek_usb_hw_init();
#endif
diff --git a/board/atmel/at91sam9rlek/at91sam9rlek.c b/board/atmel/at91sam9rlek/at91sam9rlek.c
index af59620..f05ee322 100644
--- a/board/atmel/at91sam9rlek/at91sam9rlek.c
+++ b/board/atmel/at91sam9rlek/at91sam9rlek.c
@@ -20,7 +20,6 @@
#include <asm/arch/clk.h>
#include <asm/arch/gpio.h>
-#include <lcd.h>
#include <atmel_lcdc.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -75,90 +74,6 @@ static void at91sam9rlek_nand_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-vidinfo_t panel_info = {
- .vl_col = 240,
- .vl_row = 320,
- .vl_clk = 4965000,
- .vl_sync = ATMEL_LCDC_INVLINE_INVERTED |
- ATMEL_LCDC_INVFRAME_INVERTED,
- .vl_bpix = 3,
- .vl_tft = 1,
- .vl_hsync_len = 5,
- .vl_left_margin = 1,
- .vl_right_margin = 33,
- .vl_vsync_len = 1,
- .vl_upper_margin = 1,
- .vl_lower_margin = 0,
- .mmio = ATMEL_BASE_LCDC,
-};
-
-void lcd_enable(void)
-{
- at91_set_gpio_value(AT91_PIN_PA30, 0); /* power up */
-}
-
-void lcd_disable(void)
-{
- at91_set_gpio_value(AT91_PIN_PA30, 1); /* power down */
-}
-static void at91sam9rlek_lcd_hw_init(void)
-{
- at91_set_B_periph(AT91_PIN_PC1, 0); /* LCDPWR */
- at91_set_A_periph(AT91_PIN_PC5, 0); /* LCDHSYNC */
- at91_set_A_periph(AT91_PIN_PC6, 0); /* LCDDOTCK */
- at91_set_A_periph(AT91_PIN_PC7, 0); /* LCDDEN */
- at91_set_A_periph(AT91_PIN_PC3, 0); /* LCDCC */
- at91_set_B_periph(AT91_PIN_PC9, 0); /* LCDD3 */
- at91_set_B_periph(AT91_PIN_PC10, 0); /* LCDD4 */
- at91_set_B_periph(AT91_PIN_PC11, 0); /* LCDD5 */
- at91_set_B_periph(AT91_PIN_PC12, 0); /* LCDD6 */
- at91_set_B_periph(AT91_PIN_PC13, 0); /* LCDD7 */
- at91_set_B_periph(AT91_PIN_PC15, 0); /* LCDD11 */
- at91_set_B_periph(AT91_PIN_PC16, 0); /* LCDD12 */
- at91_set_B_periph(AT91_PIN_PC17, 0); /* LCDD13 */
- at91_set_B_periph(AT91_PIN_PC18, 0); /* LCDD14 */
- at91_set_B_periph(AT91_PIN_PC19, 0); /* LCDD15 */
- at91_set_B_periph(AT91_PIN_PC20, 0); /* LCDD18 */
- at91_set_B_periph(AT91_PIN_PC21, 0); /* LCDD19 */
- at91_set_B_periph(AT91_PIN_PC22, 0); /* LCDD20 */
- at91_set_B_periph(AT91_PIN_PC23, 0); /* LCDD21 */
- at91_set_B_periph(AT91_PIN_PC24, 0); /* LCDD22 */
- at91_set_B_periph(AT91_PIN_PC25, 0); /* LCDD23 */
-
- at91_periph_clk_enable(ATMEL_ID_LCDC);
-}
-
-#ifdef CONFIG_LCD_INFO
-#include <nand.h>
-#include <version.h>
-
-void lcd_show_board_info(void)
-{
- ulong dram_size, nand_size;
- int i;
- char temp[32];
-
- lcd_printf ("%s\n", U_BOOT_VERSION);
- lcd_printf ("(C) 2008 ATMEL Corp\n");
- lcd_printf ("at91support@atmel.com\n");
- lcd_printf ("%s CPU at %s MHz\n",
- ATMEL_CPU_NAME,
- strmhz(temp, get_cpu_clk_rate()));
-
- dram_size = 0;
- for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++)
- dram_size += gd->bd->bi_dram[i].size;
- nand_size = 0;
- for (i = 0; i < CONFIG_SYS_MAX_NAND_DEVICE; i++)
- nand_size += get_nand_dev_by_index(i)->size;
- lcd_printf (" %ld MB SDRAM, %ld MB NAND\n",
- dram_size >> 20,
- nand_size >> 20 );
-}
-#endif /* CONFIG_LCD_INFO */
-#endif
-
#ifdef CONFIG_DEBUG_UART_BOARD_INIT
void board_debug_uart_init(void)
{
@@ -183,9 +98,6 @@ int board_init(void)
#ifdef CONFIG_CMD_NAND
at91sam9rlek_nand_hw_init();
#endif
-#ifdef CONFIG_LCD
- at91sam9rlek_lcd_hw_init();
-#endif
return 0;
}
diff --git a/board/atmel/at91sam9x5ek/at91sam9x5ek.c b/board/atmel/at91sam9x5ek/at91sam9x5ek.c
index 8192824..b5af35b 100644
--- a/board/atmel/at91sam9x5ek/at91sam9x5ek.c
+++ b/board/atmel/at91sam9x5ek/at91sam9x5ek.c
@@ -87,7 +87,7 @@ static void at91sam9x5ek_nand_hw_init(void)
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
at91_prepare_cpu_var();
diff --git a/board/atmel/common/Makefile b/board/atmel/common/Makefile
index 6bc8cab..c046da7 100644
--- a/board/atmel/common/Makefile
+++ b/board/atmel/common/Makefile
@@ -6,4 +6,4 @@
obj-y += board.o
obj-$(CONFIG_I2C_EEPROM) += mac_eeprom.o
obj-$(CONFIG_SPI_FLASH_SFDP_SUPPORT) += mac-spi-nor.o
-obj-$(CONFIG_DM_VIDEO) += video_display.o
+obj-$(CONFIG_VIDEO) += video_display.o
diff --git a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
index 65d0a75..329eac7 100644
--- a/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
+++ b/board/atmel/sama5d27_som1_ek/sama5d27_som1_ek.c
@@ -39,7 +39,7 @@ static void board_usb_hw_init(void)
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
at91_pda_detect();
diff --git a/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c b/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c
index c38585c..6524867 100644
--- a/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c
+++ b/board/atmel/sama5d27_wlsom1_ek/sama5d27_wlsom1_ek.c
@@ -32,7 +32,7 @@ static void rgb_leds_init(void)
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
at91_pda_detect();
diff --git a/board/atmel/sama5d2_xplained/sama5d2_xplained.c b/board/atmel/sama5d2_xplained/sama5d2_xplained.c
index 9e0f9c3..aa52207 100644
--- a/board/atmel/sama5d2_xplained/sama5d2_xplained.c
+++ b/board/atmel/sama5d2_xplained/sama5d2_xplained.c
@@ -38,7 +38,7 @@ static void board_usb_hw_init(void)
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
at91_pda_detect();
diff --git a/board/atmel/sama5d3xek/sama5d3xek.c b/board/atmel/sama5d3xek/sama5d3xek.c
index 132e7fa..008f1db 100644
--- a/board/atmel/sama5d3xek/sama5d3xek.c
+++ b/board/atmel/sama5d3xek/sama5d3xek.c
@@ -186,7 +186,7 @@ int board_late_init(void)
strcat(name, "ek.dtb");
env_set("dtb_name", name);
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
return 0;
diff --git a/board/atmel/sama5d4_xplained/sama5d4_xplained.c b/board/atmel/sama5d4_xplained/sama5d4_xplained.c
index 9fb7e6f..4058594 100644
--- a/board/atmel/sama5d4_xplained/sama5d4_xplained.c
+++ b/board/atmel/sama5d4_xplained/sama5d4_xplained.c
@@ -76,7 +76,7 @@ static void sama5d4_xplained_usb_hw_init(void)
int board_late_init(void)
{
at91_pda_detect();
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
return 0;
diff --git a/board/atmel/sama5d4ek/sama5d4ek.c b/board/atmel/sama5d4ek/sama5d4ek.c
index ba38533..ef5a8a0 100644
--- a/board/atmel/sama5d4ek/sama5d4ek.c
+++ b/board/atmel/sama5d4ek/sama5d4ek.c
@@ -74,7 +74,7 @@ static void sama5d4ek_usb_hw_init(void)
#ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91_video_show_board_info();
#endif
return 0;
diff --git a/board/beckhoff/mx53cx9020/Makefile b/board/beckhoff/mx53cx9020/Makefile
index 7f15fc5..423a553 100644
--- a/board/beckhoff/mx53cx9020/Makefile
+++ b/board/beckhoff/mx53cx9020/Makefile
@@ -4,4 +4,4 @@
# Patrick Bruenn <p.bruenn@beckhoff.com>
obj-y += mx53cx9020.o
-obj-$(CONFIG_DM_VIDEO) += mx53cx9020_video.o
+obj-$(CONFIG_VIDEO) += mx53cx9020_video.o
diff --git a/board/bluewater/gurnard/gurnard.c b/board/bluewater/gurnard/gurnard.c
index 35c8985..f547ce3 100644
--- a/board/bluewater/gurnard/gurnard.c
+++ b/board/bluewater/gurnard/gurnard.c
@@ -14,7 +14,6 @@
#include <dm.h>
#include <env.h>
#include <init.h>
-#include <lcd.h>
#include <net.h>
#ifndef CONFIG_DM_ETH
#include <netdev.h>
@@ -140,7 +139,7 @@ static void lcd_splash(int width, int height)
}
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
static void at91sam9g45_lcd_hw_init(void)
{
at91_set_A_periph(AT91_PIN_PE0, 0); /* LCDDPWR */
@@ -338,7 +337,7 @@ int board_init(void)
at91_mci_hw_init();
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
at91sam9g45_lcd_hw_init();
at91_set_A_periph(AT91_PIN_PE6, 1); /* power up */
diff --git a/board/bosch/guardian/board.c b/board/bosch/guardian/board.c
index 7d1064a..bdf8d06 100644
--- a/board/bosch/guardian/board.c
+++ b/board/bosch/guardian/board.c
@@ -254,74 +254,6 @@ void lcdbacklight_en(void)
brightness != 0 ? 0x0A : 0x02, 0xFF);
}
-#if IS_ENABLED(CONFIG_AM335X_LCD)
-static void splash_screen(void)
-{
- struct udevice *video_dev;
- struct udevice *console_dev;
- struct video_priv *vid_priv;
- struct mtd_info *mtd;
- size_t len;
- int ret;
-
- struct mtd_device *mtd_dev;
- struct part_info *part;
- u8 pnum;
-
- ret = uclass_get_device(UCLASS_VIDEO, 0, &video_dev);
- if (ret != 0) {
- debug("video device not found\n");
- goto exit;
- }
-
- vid_priv = dev_get_uclass_priv(video_dev);
- mtdparts_init();
-
- if (find_dev_and_part(SPLASH_SCREEN_NAND_PART, &mtd_dev, &pnum, &part)) {
- debug("Could not find nand partition\n");
- goto splash_screen_text;
- }
-
- mtd = get_nand_dev_by_index(mtd_dev->id->num);
- if (!mtd) {
- debug("MTD partition is not valid\n");
- goto splash_screen_text;
- }
-
- len = SPLASH_SCREEN_BMP_FILE_SIZE;
- ret = nand_read_skip_bad(mtd, part->offset, &len, NULL,
- SPLASH_SCREEN_BMP_FILE_SIZE,
- (u_char *)SPLASH_SCREEN_BMP_LOAD_ADDR);
- if (ret != 0) {
- debug("Reading NAND partition failed\n");
- goto splash_screen_text;
- }
-
- ret = video_bmp_display(video_dev, SPLASH_SCREEN_BMP_LOAD_ADDR, 0, 0, false);
- if (ret != 0) {
- debug("No valid bmp image found!!\n");
- goto splash_screen_text;
- } else {
- goto exit;
- }
-
-splash_screen_text:
- vid_priv->colour_fg = CONSOLE_COLOR_RED;
- vid_priv->colour_bg = CONSOLE_COLOR_BLACK;
-
- if (!uclass_first_device_err(UCLASS_VIDEO_CONSOLE, &console_dev)) {
- debug("Found console\n");
- vidconsole_position_cursor(console_dev, 17, 7);
- vidconsole_put_string(console_dev, SPLASH_SCREEN_TEXT);
- } else {
- debug("No console device found\n");
- }
-
-exit:
- return;
-}
-#endif /* CONFIG_AM335X_LCD */
-
int board_late_init(void)
{
int ret;
@@ -340,8 +272,6 @@ int board_late_init(void)
return 0;
lcdbacklight_en();
- if (IS_ENABLED(CONFIG_AM335X_LCD))
- splash_screen();
return 0;
}
diff --git a/board/compal/paz00/paz00.c b/board/compal/paz00/paz00.c
index 64d0860..d92eb16 100644
--- a/board/compal/paz00/paz00.c
+++ b/board/compal/paz00/paz00.c
@@ -41,7 +41,7 @@ void pin_mux_mmc(void)
}
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
/* this is a weak define that we are overriding */
void pin_mux_display(void)
{
diff --git a/board/compulab/common/Makefile b/board/compulab/common/Makefile
index 25dad49..7c8226e 100644
--- a/board/compulab/common/Makefile
+++ b/board/compulab/common/Makefile
@@ -6,5 +6,4 @@
obj-y += common.o
obj-$(CONFIG_$(SPL_)SYS_I2C_LEGACY) += eeprom.o
-obj-$(CONFIG_LCD) += omap3_display.o
obj-$(CONFIG_SMC911X) += omap3_smc911x.o
diff --git a/board/compulab/common/omap3_display.c b/board/compulab/common/omap3_display.c
deleted file mode 100644
index 4ed3b9c..0000000
--- a/board/compulab/common/omap3_display.c
+++ /dev/null
@@ -1,452 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * (C) Copyright 2012 - 2013 CompuLab, Ltd. <www.compulab.co.il>
- *
- * Authors: Nikita Kiryanov <nikita@compulab.co.il>
- *
- * Parsing code based on linux/drivers/video/pxafb.c
- */
-
-#include <common.h>
-#include <asm/gpio.h>
-#include <asm/io.h>
-#include <env.h>
-#include <stdio_dev.h>
-#include <asm/arch/dss.h>
-#include <lcd.h>
-#include <scf0403_lcd.h>
-#include <asm/arch-omap3/dss.h>
-
-enum display_type {
- NONE,
- DVI,
- DVI_CUSTOM,
- DATA_IMAGE, /* #define CONFIG_SCF0403_LCD to use */
-};
-
-#define CMAP_ADDR 0x80100000
-
-/*
- * The frame buffer is allocated before we have the chance to parse user input.
- * To make sure enough memory is allocated for all resolutions, we define
- * vl_{col | row} to the maximal resolution supported by OMAP3.
- */
-vidinfo_t panel_info = {
- .vl_col = 1400,
- .vl_row = 1050,
- .vl_bpix = LCD_BPP,
- .cmap = (ushort *)CMAP_ADDR,
-};
-
-static struct panel_config panel_cfg;
-static enum display_type lcd_def;
-
-/*
- * A note on DVI presets;
- * U-Boot can convert 8 bit BMP data to 16 bit BMP data, and OMAP DSS can
- * convert 16 bit data into 24 bit data. Thus, GFXFORMAT_RGB16 allows us to
- * support two BMP types with one setting.
- */
-static const struct panel_config preset_dvi_640X480 = {
- .lcd_size = PANEL_LCD_SIZE(640, 480),
- .timing_h = DSS_HBP(48) | DSS_HFP(16) | DSS_HSW(96),
- .timing_v = DSS_VBP(33) | DSS_VFP(10) | DSS_VSW(2),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 12 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dvi_800X600 = {
- .lcd_size = PANEL_LCD_SIZE(800, 600),
- .timing_h = DSS_HBP(88) | DSS_HFP(40) | DSS_HSW(128),
- .timing_v = DSS_VBP(23) | DSS_VFP(1) | DSS_VSW(4),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 8 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dvi_1024X768 = {
- .lcd_size = PANEL_LCD_SIZE(1024, 768),
- .timing_h = DSS_HBP(160) | DSS_HFP(24) | DSS_HSW(136),
- .timing_v = DSS_VBP(29) | DSS_VFP(3) | DSS_VSW(6),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 5 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dvi_1152X864 = {
- .lcd_size = PANEL_LCD_SIZE(1152, 864),
- .timing_h = DSS_HBP(256) | DSS_HFP(64) | DSS_HSW(128),
- .timing_v = DSS_VBP(32) | DSS_VFP(1) | DSS_VSW(3),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 4 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dvi_1280X960 = {
- .lcd_size = PANEL_LCD_SIZE(1280, 960),
- .timing_h = DSS_HBP(312) | DSS_HFP(96) | DSS_HSW(112),
- .timing_v = DSS_VBP(36) | DSS_VFP(1) | DSS_VSW(3),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 3 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dvi_1280X1024 = {
- .lcd_size = PANEL_LCD_SIZE(1280, 1024),
- .timing_h = DSS_HBP(248) | DSS_HFP(48) | DSS_HSW(112),
- .timing_v = DSS_VBP(38) | DSS_VFP(1) | DSS_VSW(3),
- .pol_freq = DSS_IHS | DSS_IVS | DSS_IPC,
- .divisor = 3 | (1 << 16),
- .data_lines = LCD_INTERFACE_24_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-static const struct panel_config preset_dataimage_480X800 = {
- .lcd_size = PANEL_LCD_SIZE(480, 800),
- .timing_h = DSS_HBP(2) | DSS_HFP(2) | DSS_HSW(2),
- .timing_v = DSS_VBP(17) | DSS_VFP(20) | DSS_VSW(3),
- .pol_freq = DSS_IVS | DSS_IHS | DSS_IPC | DSS_ONOFF,
- .divisor = 10 | (1 << 10),
- .data_lines = LCD_INTERFACE_18_BIT,
- .panel_type = ACTIVE_DISPLAY,
- .load_mode = 2,
- .gfx_format = GFXFORMAT_RGB16,
-};
-
-/*
- * set_resolution_params()
- *
- * Due to usage of multiple display related APIs resolution data is located in
- * more than one place. This function updates them all.
- */
-static void set_resolution_params(int x, int y)
-{
- panel_cfg.lcd_size = PANEL_LCD_SIZE(x, y);
- panel_info.vl_col = x;
- panel_info.vl_row = y;
- lcd_line_length = (panel_info.vl_col * NBITS(panel_info.vl_bpix)) / 8;
-}
-
-static void set_preset(const struct panel_config preset, int x_res, int y_res)
-{
- panel_cfg = preset;
- set_resolution_params(x_res, y_res);
-}
-
-static enum display_type set_dvi_preset(const struct panel_config preset,
- int x_res, int y_res)
-{
- set_preset(preset, x_res, y_res);
- return DVI;
-}
-
-static enum display_type set_dataimage_preset(const struct panel_config preset,
- int x_res, int y_res)
-{
- set_preset(preset, x_res, y_res);
- return DATA_IMAGE;
-}
-
-/*
- * parse_mode() - parse the mode parameter of custom lcd settings
- *
- * @mode: <res_x>x<res_y>
- *
- * Returns -1 on error, 0 on success.
- */
-static int parse_mode(const char *mode)
-{
- unsigned int modelen = strlen(mode);
- int res_specified = 0;
- unsigned int xres = 0, yres = 0;
- int yres_specified = 0;
- int i;
-
- for (i = modelen - 1; i >= 0; i--) {
- switch (mode[i]) {
- case 'x':
- if (!yres_specified) {
- yres = simple_strtoul(&mode[i + 1], NULL, 0);
- yres_specified = 1;
- } else {
- goto done_parsing;
- }
-
- break;
- case '0' ... '9':
- break;
- default:
- goto done_parsing;
- }
- }
-
- if (i < 0 && yres_specified) {
- xres = simple_strtoul(mode, NULL, 0);
- res_specified = 1;
- }
-
-done_parsing:
- if (res_specified) {
- set_resolution_params(xres, yres);
- } else {
- printf("LCD: invalid mode: %s\n", mode);
- return -1;
- }
-
- return 0;
-}
-
-#define PIXEL_CLK_NUMERATOR (26 * 432 / 39)
-/*
- * parse_pixclock() - Parse the pixclock parameter of custom lcd settings
- *
- * @pixclock: the desired pixel clock
- *
- * Returns -1 on error, 0 on success.
- *
- * Handling the pixel_clock:
- *
- * Pixel clock is defined in the OMAP35x TRM as follows:
- * pixel_clock =
- * (SYS_CLK * 2 * PRCM.CM_CLKSEL2_PLL[18:8]) /
- * (DSS.DISPC_DIVISOR[23:16] * DSS.DISPC_DIVISOR[6:0] *
- * PRCM.CM_CLKSEL_DSS[4:0] * (PRCM.CM_CLKSEL2_PLL[6:0] + 1))
- *
- * In practice, this means that in order to set the
- * divisor for the desired pixel clock one needs to
- * solve the following equation:
- *
- * 26 * 432 / (39 * <pixel_clock>) = DSS.DISPC_DIVISOR[6:0]
- *
- * NOTE: the explicit equation above is reduced. Do not
- * try to infer anything from these numbers.
- */
-static int parse_pixclock(char *pixclock)
-{
- int divisor, pixclock_val;
- char *pixclk_start = pixclock;
-
- pixclock_val = dectoul(pixclock, &pixclock);
- divisor = DIV_ROUND_UP(PIXEL_CLK_NUMERATOR, pixclock_val);
- /* 0 and 1 are illegal values for PCD */
- if (divisor <= 1)
- divisor = 2;
-
- panel_cfg.divisor = divisor | (1 << 16);
- if (pixclock[0] != '\0') {
- printf("LCD: invalid value for pixclock:%s\n", pixclk_start);
- return -1;
- }
-
- return 0;
-}
-
-/*
- * parse_setting() - parse a single setting of custom lcd parameters
- *
- * @setting: The custom lcd setting <name>:<value>
- *
- * Returns -1 on failure, 0 on success.
- */
-static int parse_setting(char *setting)
-{
- int num_val;
- char *setting_start = setting;
-
- if (!strncmp(setting, "mode:", 5)) {
- return parse_mode(setting + 5);
- } else if (!strncmp(setting, "pixclock:", 9)) {
- return parse_pixclock(setting + 9);
- } else if (!strncmp(setting, "left:", 5)) {
- num_val = simple_strtoul(setting + 5, &setting, 0);
- panel_cfg.timing_h |= DSS_HBP(num_val);
- } else if (!strncmp(setting, "right:", 6)) {
- num_val = simple_strtoul(setting + 6, &setting, 0);
- panel_cfg.timing_h |= DSS_HFP(num_val);
- } else if (!strncmp(setting, "upper:", 6)) {
- num_val = simple_strtoul(setting + 6, &setting, 0);
- panel_cfg.timing_v |= DSS_VBP(num_val);
- } else if (!strncmp(setting, "lower:", 6)) {
- num_val = simple_strtoul(setting + 6, &setting, 0);
- panel_cfg.timing_v |= DSS_VFP(num_val);
- } else if (!strncmp(setting, "hsynclen:", 9)) {
- num_val = simple_strtoul(setting + 9, &setting, 0);
- panel_cfg.timing_h |= DSS_HSW(num_val);
- } else if (!strncmp(setting, "vsynclen:", 9)) {
- num_val = simple_strtoul(setting + 9, &setting, 0);
- panel_cfg.timing_v |= DSS_VSW(num_val);
- } else if (!strncmp(setting, "hsync:", 6)) {
- if (simple_strtoul(setting + 6, &setting, 0) == 0)
- panel_cfg.pol_freq |= DSS_IHS;
- else
- panel_cfg.pol_freq &= ~DSS_IHS;
- } else if (!strncmp(setting, "vsync:", 6)) {
- if (simple_strtoul(setting + 6, &setting, 0) == 0)
- panel_cfg.pol_freq |= DSS_IVS;
- else
- panel_cfg.pol_freq &= ~DSS_IVS;
- } else if (!strncmp(setting, "outputen:", 9)) {
- if (simple_strtoul(setting + 9, &setting, 0) == 0)
- panel_cfg.pol_freq |= DSS_IEO;
- else
- panel_cfg.pol_freq &= ~DSS_IEO;
- } else if (!strncmp(setting, "pixclockpol:", 12)) {
- if (simple_strtoul(setting + 12, &setting, 0) == 0)
- panel_cfg.pol_freq |= DSS_IPC;
- else
- panel_cfg.pol_freq &= ~DSS_IPC;
- } else if (!strncmp(setting, "active", 6)) {
- panel_cfg.panel_type = ACTIVE_DISPLAY;
- return 0; /* Avoid sanity check below */
- } else if (!strncmp(setting, "passive", 7)) {
- panel_cfg.panel_type = PASSIVE_DISPLAY;
- return 0; /* Avoid sanity check below */
- } else if (!strncmp(setting, "display:", 8)) {
- if (!strncmp(setting + 8, "dvi", 3)) {
- lcd_def = DVI_CUSTOM;
- return 0; /* Avoid sanity check below */
- }
- } else {
- printf("LCD: unknown option %s\n", setting_start);
- return -1;
- }
-
- if (setting[0] != '\0') {
- printf("LCD: invalid value for %s\n", setting_start);
- return -1;
- }
-
- return 0;
-}
-
-/*
- * env_parse_customlcd() - parse custom lcd params from an environment variable.
- *
- * @custom_lcd_params: The environment variable containing the lcd params.
- *
- * Returns -1 on failure, 0 on success.
- */
-static int parse_customlcd(char *custom_lcd_params)
-{
- char params_cpy[160];
- char *setting;
-
- strncpy(params_cpy, custom_lcd_params, 160);
- setting = strtok(params_cpy, ",");
- while (setting) {
- if (parse_setting(setting) < 0)
- return -1;
-
- setting = strtok(NULL, ",");
- }
-
- /* Currently we don't support changing this via custom lcd params */
- panel_cfg.data_lines = LCD_INTERFACE_24_BIT;
- panel_cfg.gfx_format = GFXFORMAT_RGB16; /* See dvi predefines note */
-
- return 0;
-}
-
-/*
- * env_parse_displaytype() - parse display type.
- *
- * Parses the environment variable "displaytype", which contains the
- * name of the display type or preset, in which case it applies its
- * configurations.
- *
- * Returns the type of display that was specified.
- */
-static enum display_type env_parse_displaytype(char *displaytype)
-{
- if (!strncmp(displaytype, "dvi640x480", 10))
- return set_dvi_preset(preset_dvi_640X480, 640, 480);
- else if (!strncmp(displaytype, "dvi800x600", 10))
- return set_dvi_preset(preset_dvi_800X600, 800, 600);
- else if (!strncmp(displaytype, "dvi1024x768", 11))
- return set_dvi_preset(preset_dvi_1024X768, 1024, 768);
- else if (!strncmp(displaytype, "dvi1152x864", 11))
- return set_dvi_preset(preset_dvi_1152X864, 1152, 864);
- else if (!strncmp(displaytype, "dvi1280x960", 11))
- return set_dvi_preset(preset_dvi_1280X960, 1280, 960);
- else if (!strncmp(displaytype, "dvi1280x1024", 12))
- return set_dvi_preset(preset_dvi_1280X1024, 1280, 1024);
- else if (!strncmp(displaytype, "dataimage480x800", 16))
- return set_dataimage_preset(preset_dataimage_480X800, 480, 800);
-
- return NONE;
-}
-
-void lcd_ctrl_init(void *lcdbase)
-{
- struct prcm *prcm = (struct prcm *)PRCM_BASE;
- char *custom_lcd;
- char *displaytype = env_get("displaytype");
-
- if (displaytype == NULL)
- return;
-
- lcd_def = env_parse_displaytype(displaytype);
- /* If we did not recognize the preset, check if it's an env variable */
- if (lcd_def == NONE) {
- custom_lcd = env_get(displaytype);
- if (custom_lcd == NULL || parse_customlcd(custom_lcd) < 0)
- return;
- }
-
- panel_cfg.frame_buffer = lcdbase;
- omap3_dss_panel_config(&panel_cfg);
- /*
- * Pixel clock is defined with many divisions and only few
- * multiplications of the system clock. Since DSS FCLK divisor is set
- * to 16 by default, we need to set it to a smaller value, like 3
- * (chosen via trial and error).
- */
- clrsetbits_le32(&prcm->clksel_dss, 0xF, 3);
-}
-
-#ifdef CONFIG_SCF0403_LCD
-static void scf0403_enable(void)
-{
- gpio_direction_output(58, 1);
- scf0403_init(157);
-}
-#else
-static inline void scf0403_enable(void) {}
-#endif
-
-void lcd_enable(void)
-{
- switch (lcd_def) {
- case NONE:
- return;
- case DVI:
- case DVI_CUSTOM:
- gpio_direction_output(54, 0); /* Turn on DVI */
- break;
- case DATA_IMAGE:
- scf0403_enable();
- break;
- }
-
- omap3_dss_enable();
-}
-
-void lcd_setcolreg(ushort regno, ushort red, ushort green, ushort blue) {}
diff --git a/board/freescale/imx8ulp_evk/imx8ulp_evk.c b/board/freescale/imx8ulp_evk/imx8ulp_evk.c
index 1fd338c..5aad107 100644
--- a/board/freescale/imx8ulp_evk/imx8ulp_evk.c
+++ b/board/freescale/imx8ulp_evk/imx8ulp_evk.c
@@ -112,7 +112,7 @@ int board_init(void)
}
/* When sync with M33 is failed, use local driver to set for video */
- if (sync != 0 && IS_ENABLED(CONFIG_DM_VIDEO)) {
+ if (sync != 0 && IS_ENABLED(CONFIG_VIDEO)) {
mipi_dsi_mux_panel();
mipi_dsi_panel_backlight();
}
diff --git a/board/freescale/mx6ul_14x14_evk/mx6ul_14x14_evk.c b/board/freescale/mx6ul_14x14_evk/mx6ul_14x14_evk.c
index b916ea0..1eec048 100644
--- a/board/freescale/mx6ul_14x14_evk/mx6ul_14x14_evk.c
+++ b/board/freescale/mx6ul_14x14_evk/mx6ul_14x14_evk.c
@@ -240,7 +240,7 @@ int board_phy_config(struct phy_device *phydev)
}
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
static iomux_v3_cfg_t const lcd_pads[] = {
/* Use GPIO for Brightness adjustment, duty cycle = period. */
MX6_PAD_GPIO1_IO08__GPIO1_IO08 | MUX_PAD_CTRL(NO_PAD_CTRL),
diff --git a/board/ge/mx53ppd/Makefile b/board/ge/mx53ppd/Makefile
index f423e80..9fae414 100644
--- a/board/ge/mx53ppd/Makefile
+++ b/board/ge/mx53ppd/Makefile
@@ -7,4 +7,4 @@
# Jason Liu <r64343@freescale.com>
obj-y += mx53ppd.o
-obj-$(CONFIG_DM_VIDEO) += mx53ppd_video.o
+obj-$(CONFIG_VIDEO) += mx53ppd_video.o
diff --git a/board/l+g/vinco/vinco.c b/board/l+g/vinco/vinco.c
index db1075a..d47c7b5 100644
--- a/board/l+g/vinco/vinco.c
+++ b/board/l+g/vinco/vinco.c
@@ -24,7 +24,6 @@
#include <asm/arch/sama5d4.h>
#include <atmel_hlcdc.h>
#include <atmel_mci.h>
-#include <lcd.h>
#include <mmc.h>
#include <net.h>
#include <netdev.h>
diff --git a/board/menlo/m53menlo/m53menlo.c b/board/menlo/m53menlo/m53menlo.c
index 4afc5aa..14324c7 100644
--- a/board/menlo/m53menlo/m53menlo.c
+++ b/board/menlo/m53menlo/m53menlo.c
@@ -358,7 +358,7 @@ int board_late_init(void)
return 0;
addr = hextoul(s, NULL);
- dst = malloc(CONFIG_SYS_VIDEO_LOGO_MAX_SIZE);
+ dst = malloc(CONFIG_VIDEO_LOGO_MAX_SIZE);
if (!dst)
return -ENOMEM;
@@ -366,8 +366,8 @@ int board_late_init(void)
if (ret < 0)
goto splasherr;
- len = CONFIG_SYS_VIDEO_LOGO_MAX_SIZE;
- ret = gunzip(dst + 2, CONFIG_SYS_VIDEO_LOGO_MAX_SIZE - 2,
+ len = CONFIG_VIDEO_LOGO_MAX_SIZE;
+ ret = gunzip(dst + 2, CONFIG_VIDEO_LOGO_MAX_SIZE - 2,
(uchar *)addr, &len);
if (ret) {
printf("Error: no valid bmp or bmp.gz image at %lx\n", addr);
diff --git a/board/nvidia/harmony/harmony.c b/board/nvidia/harmony/harmony.c
index dd56a39..5223679 100644
--- a/board/nvidia/harmony/harmony.c
+++ b/board/nvidia/harmony/harmony.c
@@ -5,7 +5,6 @@
*/
#include <common.h>
-#include <lcd.h>
#include <asm/io.h>
#include <asm/arch/clock.h>
#include <asm/arch/funcmux.h>
diff --git a/board/raspberrypi/rpi/rpi.c b/board/raspberrypi/rpi/rpi.c
index 00afb35..8603c93 100644
--- a/board/raspberrypi/rpi/rpi.c
+++ b/board/raspberrypi/rpi/rpi.c
@@ -11,7 +11,6 @@
#include <fdt_support.h>
#include <fdt_simplefb.h>
#include <init.h>
-#include <lcd.h>
#include <memalign.h>
#include <mmc.h>
#include <asm/gpio.h>
diff --git a/board/ronetix/pm9263/pm9263.c b/board/ronetix/pm9263/pm9263.c
index 6dc080a..84926cd 100644
--- a/board/ronetix/pm9263/pm9263.c
+++ b/board/ronetix/pm9263/pm9263.c
@@ -69,115 +69,6 @@ static void pm9263_nand_hw_init(void)
}
#endif
-#ifdef CONFIG_LCD
-
-#ifdef CONFIG_LCD_IN_PSRAM
-
-#define PSRAM_CRE_PIN AT91_PIO_PORTB, 29
-#define PSRAM_CTRL_REG (PHYS_PSRAM + PHYS_PSRAM_SIZE - 2)
-
-/* Initialize the PSRAM memory */
-static int pm9263_lcd_hw_psram_init(void)
-{
- unsigned long csa;
- struct at91_smc *smc = (struct at91_smc *)ATMEL_BASE_SMC1;
- struct at91_matrix *matrix = (struct at91_matrix *)ATMEL_BASE_MATRIX;
-
- /* Enable CS3 3.3v, no pull-ups */
- csa = readl(&matrix->csa[1]) | AT91_MATRIX_CSA_DBPUC |
- AT91_MATRIX_CSA_VDDIOMSEL_3_3V;
-
- writel(csa, &matrix->csa[1]);
-
- /* Configure SMC1 CS0 for PSRAM - 16-bit */
- writel(AT91_SMC_SETUP_NWE(0) | AT91_SMC_SETUP_NCS_WR(0) |
- AT91_SMC_SETUP_NRD(0) | AT91_SMC_SETUP_NCS_RD(0),
- &smc->cs[0].setup);
-
- writel(AT91_SMC_PULSE_NWE(7) | AT91_SMC_PULSE_NCS_WR(7) |
- AT91_SMC_PULSE_NRD(2) | AT91_SMC_PULSE_NCS_RD(7),
- &smc->cs[0].pulse);
-
- writel(AT91_SMC_CYCLE_NWE(8) | AT91_SMC_CYCLE_NRD(8),
- &smc->cs[0].cycle);
-
- writel(AT91_SMC_MODE_DBW_16 | AT91_SMC_MODE_PMEN | AT91_SMC_MODE_PS_32,
- &smc->cs[0].mode);
-
- /* setup PB29 as output */
- at91_set_pio_output(PSRAM_CRE_PIN, 1);
-
- at91_set_pio_value(PSRAM_CRE_PIN, 0); /* set PSRAM_CRE_PIN to '0' */
-
- /* PSRAM: write BCR */
- readw(PSRAM_CTRL_REG);
- readw(PSRAM_CTRL_REG);
- writew(1, PSRAM_CTRL_REG); /* 0 - RCR,1 - BCR */
- writew(0x9d4f, PSRAM_CTRL_REG); /* write the BCR */
-
- /* write RCR of the PSRAM */
- readw(PSRAM_CTRL_REG);
- readw(PSRAM_CTRL_REG);
- writew(0, PSRAM_CTRL_REG); /* 0 - RCR,1 - BCR */
- /* set RCR; 0x10-async mode,0x90-page mode */
- writew(0x90, PSRAM_CTRL_REG);
-
- /*
- * test to see if the PSRAM is MT45W2M16A or MT45W2M16B
- * MT45W2M16B - CRE must be 0
- * MT45W2M16A - CRE must be 1
- */
- writew(0x1234, PHYS_PSRAM);
- writew(0x5678, PHYS_PSRAM + 2);
-
- /* test if the chip is MT45W2M16B */
- if ((readw(PHYS_PSRAM) != 0x1234) || (readw(PHYS_PSRAM+2) != 0x5678)) {
- /* try with CRE=1 (MT45W2M16A) */
- at91_set_pio_value(PSRAM_CRE_PIN, 1); /* set PSRAM_CRE_PIN to '1' */
-
- /* write RCR of the PSRAM */
- readw(PSRAM_CTRL_REG);
- readw(PSRAM_CTRL_REG);
- writew(0, PSRAM_CTRL_REG); /* 0 - RCR,1 - BCR */
- /* set RCR;0x10-async mode,0x90-page mode */
- writew(0x90, PSRAM_CTRL_REG);
-
-
- writew(0x1234, PHYS_PSRAM);
- writew(0x5678, PHYS_PSRAM+2);
- if ((readw(PHYS_PSRAM) != 0x1234)
- || (readw(PHYS_PSRAM + 2) != 0x5678))
- return 1;
-
- }
-
- /* Bus matrix */
- writel(AT91_MATRIX_PRA_M5(3), &matrix->pr[5].a);
- writel(CONFIG_PSRAM_SCFG, &matrix->scfg[5]);
-
- return 0;
-}
-#endif
-
-static void pm9263_lcd_hw_init(void)
-{
- /* Power Control */
- at91_set_pio_output(AT91_PIO_PORTA, 22, 1);
- at91_set_pio_value(AT91_PIO_PORTA, 22, 0); /* power down */
-
-#ifdef CONFIG_LCD_IN_PSRAM
- /* initialize the PSRAM */
- int stat = pm9263_lcd_hw_psram_init();
-
- gd->fb_base = (stat == 0) ? PHYS_PSRAM : ATMEL_BASE_SRAM0;
-#else
- gd->fb_base = ATMEL_BASE_SRAM0;
-#endif
-
-}
-
-#endif /* CONFIG_LCD */
-
int board_early_init_f(void)
{
return 0;
@@ -197,9 +88,6 @@ int board_init(void)
#ifdef CONFIG_USB_OHCI_NEW
at91_uhp_hw_init();
#endif
-#ifdef CONFIG_LCD
- pm9263_lcd_hw_init();
-#endif
return 0;
}
diff --git a/board/samsung/common/board.c b/board/samsung/common/board.c
index ff178b7..49d4024 100644
--- a/board/samsung/common/board.c
+++ b/board/samsung/common/board.c
@@ -26,7 +26,6 @@
#include <asm/arch/pinmux.h>
#include <asm/arch/power.h>
#include <asm/arch/system.h>
-#include <lcd.h>
#include <i2c.h>
#include <mmc.h>
#include <stdio_dev.h>
@@ -262,10 +261,6 @@ int misc_init_r(void)
#ifdef CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
set_board_info();
#endif
-#ifdef CONFIG_LCD_MENU
- keys_init();
- check_boot_mode();
-#endif
#ifdef CONFIG_CMD_BMP
if (panel_info.logo_on)
draw_logo();
diff --git a/board/samsung/common/misc.c b/board/samsung/common/misc.c
index b3b1bbc..9c0ec29 100644
--- a/board/samsung/common/misc.c
+++ b/board/samsung/common/misc.c
@@ -7,7 +7,6 @@
#include <common.h>
#include <command.h>
#include <env.h>
-#include <lcd.h>
#include <libtizen.h>
#include <asm/global_data.h>
#include <linux/delay.h>
@@ -114,345 +113,6 @@ void set_board_info(void)
}
#endif /* CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG */
-#ifdef CONFIG_LCD_MENU
-static int power_key_pressed(u32 reg)
-{
- struct udevice *dev;
- int ret;
- u32 status;
- u32 mask;
-
- if (IS_ENABLED(CONFIG_TARGET_TRATS))
- ret = pmic_get("max8997-pmic", &dev);
- else if (IS_ENABLED(CONFIG_TARGET_TRATS2))
- ret = pmic_get("max77686-pmic", &dev);
- else if (IS_ENABLED(CONFIG_TARGET_S5PC210_UNIVERSAL))
- ret = pmic_get("max8998-pmic", &dev);
- else
- return 0;
-
- if (ret)
- return ret;
-
- if (reg == KEY_PWR_STATUS_REG)
- mask = KEY_PWR_STATUS_MASK;
- else
- mask = KEY_PWR_INTERRUPT_MASK;
-
- status = pmic_reg_read(dev, reg);
- if (status < 0)
- return status;
-
- return !!(status & mask);
-}
-
-static int key_pressed(int key)
-{
- int value;
-
- switch (key) {
- case KEY_POWER:
- value = power_key_pressed(KEY_PWR_INTERRUPT_REG);
- break;
- case KEY_VOLUMEUP:
- value = !gpio_get_value(KEY_VOL_UP_GPIO);
- break;
- case KEY_VOLUMEDOWN:
- value = !gpio_get_value(KEY_VOL_DOWN_GPIO);
- break;
- default:
- value = 0;
- break;
- }
-
- return value;
-}
-
-#ifdef CONFIG_LCD
-static int check_keys(void)
-{
- int keys = 0;
-
- if (key_pressed(KEY_POWER))
- keys += KEY_POWER;
- if (key_pressed(KEY_VOLUMEUP))
- keys += KEY_VOLUMEUP;
- if (key_pressed(KEY_VOLUMEDOWN))
- keys += KEY_VOLUMEDOWN;
-
- return keys;
-}
-
-/*
- * 0 BOOT_MODE_INFO
- * 1 BOOT_MODE_THOR
- * 2 BOOT_MODE_UMS
- * 3 BOOT_MODE_DFU
- * 4 BOOT_MODE_EXIT
- */
-static char *
-mode_name[BOOT_MODE_EXIT + 1][2] = {
- {"DEVICE", ""},
- {"THOR", "thor"},
- {"UMS", "ums"},
- {"DFU", "dfu"},
- {"GPT", "gpt"},
- {"ENV", "env"},
- {"EXIT", ""},
-};
-
-static char *
-mode_info[BOOT_MODE_EXIT + 1] = {
- "info",
- "downloader",
- "mass storage",
- "firmware update",
- "restore",
- "default",
- "and run normal boot"
-};
-
-static char *
-mode_cmd[BOOT_MODE_EXIT + 1] = {
- "",
- "thor 0 mmc 0",
- "ums 0 mmc 0",
- "dfu 0 mmc 0",
- "gpt write mmc 0 $partitions",
- "env default -a; saveenv",
- "",
-};
-
-static void display_board_info(void)
-{
-#ifdef CONFIG_MMC
- struct mmc *mmc = find_mmc_device(0);
-#endif
- vidinfo_t *vid = &panel_info;
-
- lcd_position_cursor(4, 4);
-
- lcd_printf("%s\n\t", U_BOOT_VERSION);
- lcd_puts("\n\t\tBoard Info:\n");
-#ifdef CONFIG_SYS_BOARD
- lcd_printf("\tBoard name: %s\n", CONFIG_SYS_BOARD);
-#endif
-#ifdef CONFIG_REVISION_TAG
- lcd_printf("\tBoard rev: %u\n", get_board_rev());
-#endif
- lcd_printf("\tDRAM banks: %u\n", CONFIG_NR_DRAM_BANKS);
- lcd_printf("\tDRAM size: %u MB\n", gd->ram_size / SZ_1M);
-
-#ifdef CONFIG_MMC
- if (mmc) {
- if (!mmc->capacity)
- mmc_init(mmc);
-
- lcd_printf("\teMMC size: %llu MB\n", mmc->capacity / SZ_1M);
- }
-#endif
- if (vid)
- lcd_printf("\tDisplay resolution: %u x % u\n",
- vid->vl_col, vid->vl_row);
-
- lcd_printf("\tDisplay BPP: %u\n", 1 << vid->vl_bpix);
-}
-#endif
-
-static int mode_leave_menu(int mode)
-{
-#ifdef CONFIG_LCD
- char *exit_option;
- char *exit_reset = "reset";
- char *exit_back = "back";
- struct cmd_tbl *cmd;
- int cmd_result;
- int leave;
-
- lcd_clear();
-
- switch (mode) {
- case BOOT_MODE_EXIT:
- return 1;
- case BOOT_MODE_INFO:
- display_board_info();
- exit_option = exit_back;
- leave = 0;
- break;
- default:
- cmd = find_cmd(mode_name[mode][1]);
- if (cmd) {
- printf("Enter: %s %s\n", mode_name[mode][0],
- mode_info[mode]);
- lcd_printf("\n\n\t%s %s\n", mode_name[mode][0],
- mode_info[mode]);
- lcd_puts("\n\tDo not turn off device before finish!\n");
-
- cmd_result = run_command(mode_cmd[mode], 0);
-
- if (cmd_result == CMD_RET_SUCCESS) {
- printf("Command finished\n");
- lcd_clear();
- lcd_printf("\n\n\t%s finished\n",
- mode_name[mode][0]);
-
- exit_option = exit_reset;
- leave = 1;
- } else {
- printf("Command error\n");
- lcd_clear();
- lcd_printf("\n\n\t%s command error\n",
- mode_name[mode][0]);
-
- exit_option = exit_back;
- leave = 0;
- }
- } else {
- lcd_puts("\n\n\tThis mode is not supported.\n");
- exit_option = exit_back;
- leave = 0;
- }
- }
-
- lcd_printf("\n\n\tPress POWER KEY to %s\n", exit_option);
-
- /* Clear PWR button Rising edge interrupt status flag */
- power_key_pressed(KEY_PWR_INTERRUPT_REG);
-
- /* Wait for PWR key */
- while (!key_pressed(KEY_POWER))
- mdelay(1);
-
- lcd_clear();
- return leave;
-#else
- return 0;
-#endif
-}
-
-#ifdef CONFIG_LCD
-static void display_download_menu(int mode)
-{
- char *selection[BOOT_MODE_EXIT + 1];
- int i;
-
- for (i = 0; i <= BOOT_MODE_EXIT; i++)
- selection[i] = "[ ]";
-
- selection[mode] = "[=>]";
-
- lcd_clear();
- lcd_printf("\n\n\t\tDownload Mode Menu\n\n");
-
- for (i = 0; i <= BOOT_MODE_EXIT; i++)
- lcd_printf("\t%s %s - %s\n\n", selection[i],
- mode_name[i][0], mode_info[i]);
-}
-#endif
-
-static void download_menu(void)
-{
-#ifdef CONFIG_LCD
- int mode = 0;
- int last_mode = 0;
- int run;
- int key = 0;
- int timeout = 15; /* sec */
- int i;
-
- display_download_menu(mode);
-
- lcd_puts("\n");
-
- /* Start count if no key is pressed */
- while (check_keys())
- continue;
-
- while (timeout--) {
- lcd_printf("\r\tNormal boot will start in: %2.d seconds.",
- timeout);
-
- /* about 1000 ms in for loop */
- for (i = 0; i < 10; i++) {
- mdelay(100);
- key = check_keys();
- if (key)
- break;
- }
- if (key)
- break;
- }
-
- if (!key) {
- lcd_clear();
- return;
- }
-
- while (1) {
- run = 0;
-
- if (mode != last_mode)
- display_download_menu(mode);
-
- last_mode = mode;
- mdelay(200);
-
- key = check_keys();
- switch (key) {
- case KEY_POWER:
- run = 1;
- break;
- case KEY_VOLUMEUP:
- if (mode > 0)
- mode--;
- break;
- case KEY_VOLUMEDOWN:
- if (mode < BOOT_MODE_EXIT)
- mode++;
- break;
- default:
- break;
- }
-
- if (run) {
- if (mode_leave_menu(mode))
- run_command("reset", 0);
-
- display_download_menu(mode);
- }
- }
-
- lcd_clear();
-#endif
-}
-
-void check_boot_mode(void)
-{
- int pwr_key;
-
- pwr_key = power_key_pressed(KEY_PWR_STATUS_REG);
- if (!pwr_key)
- return;
-
- /* Clear PWR button Rising edge interrupt status flag */
- power_key_pressed(KEY_PWR_INTERRUPT_REG);
-
- if (key_pressed(KEY_VOLUMEUP))
- download_menu();
- else if (key_pressed(KEY_VOLUMEDOWN))
- mode_leave_menu(BOOT_MODE_THOR);
-}
-
-void keys_init(void)
-{
- /* Set direction to input */
- gpio_request(KEY_VOL_UP_GPIO, "volume-up");
- gpio_request(KEY_VOL_DOWN_GPIO, "volume-down");
- gpio_direction_input(KEY_VOL_UP_GPIO);
- gpio_direction_input(KEY_VOL_DOWN_GPIO);
-}
-#endif /* CONFIG_LCD_MENU */
-
#ifdef CONFIG_CMD_BMP
void draw_logo(void)
{
diff --git a/board/samsung/trats/trats.c b/board/samsung/trats/trats.c
index 24bf355..1608d60 100644
--- a/board/samsung/trats/trats.c
+++ b/board/samsung/trats/trats.c
@@ -8,7 +8,6 @@
#include <common.h>
#include <env.h>
-#include <lcd.h>
#include <log.h>
#include <asm/io.h>
#include <asm/gpio.h>
diff --git a/board/samsung/trats2/trats2.c b/board/samsung/trats2/trats2.c
index da7f0dc..93c9714 100644
--- a/board/samsung/trats2/trats2.c
+++ b/board/samsung/trats2/trats2.c
@@ -6,7 +6,6 @@
*/
#include <common.h>
-#include <lcd.h>
#include <log.h>
#include <asm/gpio.h>
#include <asm/arch/pinmux.h>
@@ -282,24 +281,3 @@ int g_dnl_board_usb_cable_connected(void)
#endif
}
#endif
-
-/*
- * LCD
- */
-
-#ifdef CONFIG_LCD
-int mipi_power(void)
-{
-#if !CONFIG_IS_ENABLED(DM_I2C) /* TODO(maintainer): Convert to driver model */
- struct pmic *p = pmic_get("MAX77686_PMIC");
-
- /* LDO8 VMIPI_1.0V_AP */
- max77686_set_ldo_mode(p, 8, OPMODE_ON);
- /* LDO10 VMIPI_1.8V_AP */
- max77686_set_ldo_mode(p, 10, OPMODE_ON);
-#endif
-
- return 0;
-}
-
-#endif /* LCD */
diff --git a/board/samsung/universal_c210/universal.c b/board/samsung/universal_c210/universal.c
index 1dde2f7..37c9d7f 100644
--- a/board/samsung/universal_c210/universal.c
+++ b/board/samsung/universal_c210/universal.c
@@ -9,14 +9,12 @@
#include <env.h>
#include <log.h>
#include <spi.h>
-#include <lcd.h>
#include <asm/global_data.h>
#include <asm/io.h>
#include <asm/gpio.h>
#include <asm/arch/adc.h>
#include <asm/arch/pinmux.h>
#include <asm/arch/watchdog.h>
-#include <ld9040.h>
#include <linux/delay.h>
#include <power/pmic.h>
#include <usb.h>
diff --git a/board/st/stm32f746-disco/stm32f746-disco.c b/board/st/stm32f746-disco/stm32f746-disco.c
index 2ab23f2..4cfb29e 100644
--- a/board/st/stm32f746-disco/stm32f746-disco.c
+++ b/board/st/stm32f746-disco/stm32f746-disco.c
@@ -7,7 +7,6 @@
#include <common.h>
#include <dm.h>
#include <init.h>
-#include <lcd.h>
#include <log.h>
#include <miiphy.h>
#include <phy_interface.h>
diff --git a/board/technexion/pico-imx7d/README b/board/technexion/pico-imx7d/README
index 4d57cdb..e8f5082 100644
--- a/board/technexion/pico-imx7d/README
+++ b/board/technexion/pico-imx7d/README
@@ -130,7 +130,6 @@ option in the defconfig
@@ -67,3 +67,4 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525
CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
CONFIG_CI_UDC=y
- CONFIG_VIDEO=y
+CONFIG_SPL_OS_BOOT=y
Then rebuild U-Boot:
diff --git a/board/technexion/pico-imx7d/pico-imx7d.c b/board/technexion/pico-imx7d/pico-imx7d.c
index 1c0cc23..7db34ab 100644
--- a/board/technexion/pico-imx7d/pico-imx7d.c
+++ b/board/technexion/pico-imx7d/pico-imx7d.c
@@ -175,7 +175,7 @@ int board_early_init_f(void)
return 0;
}
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
void setup_lcd(void)
{
gpio_request(IMX_GPIO_NR(1, 11), "lcd_brightness");
@@ -192,7 +192,7 @@ int board_init(void)
/* address of boot parameters */
gd->bd->bi_boot_params = PHYS_SDRAM + 0x100;
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
setup_lcd();
#endif
#ifdef CONFIG_FEC_MXC
diff --git a/board/toradex/colibri-imx6ull/colibri-imx6ull.c b/board/toradex/colibri-imx6ull/colibri-imx6ull.c
index ba4e0df..6007f110 100644
--- a/board/toradex/colibri-imx6ull/colibri-imx6ull.c
+++ b/board/toradex/colibri-imx6ull/colibri-imx6ull.c
@@ -67,7 +67,7 @@ static void setup_gpmi_nand(void)
}
#endif /* CONFIG_NAND_MXS */
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
static const iomux_v3_cfg_t backlight_pads[] = {
/* Backlight On */
MX6_PAD_JTAG_TMS__GPIO1_IO11 | MUX_PAD_CTRL(NO_PAD_CTRL),
@@ -195,7 +195,7 @@ int board_late_init(void)
}
#endif /* CONFIG_CMD_USB_SDP */
-#if defined(CONFIG_DM_VIDEO)
+#if defined(CONFIG_VIDEO)
setup_lcd();
#endif
diff --git a/board/toradex/colibri_imx7/colibri_imx7.c b/board/toradex/colibri_imx7/colibri_imx7.c
index 4f04543..6ce4fa3 100644
--- a/board/toradex/colibri_imx7/colibri_imx7.c
+++ b/board/toradex/colibri_imx7/colibri_imx7.c
@@ -101,7 +101,7 @@ static void setup_gpmi_nand(void)
}
#endif
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
static iomux_v3_cfg_t const backlight_pads[] = {
/* Backlight On */
MX7D_PAD_SD1_WP__GPIO5_IO1 | MUX_PAD_CTRL(NO_PAD_CTRL),
@@ -134,7 +134,7 @@ static int setup_lcd(void)
*/
void board_preboot_os(void)
{
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
gpio_direction_output(GPIO_PWM_A, 1);
gpio_direction_output(GPIO_BL_ON, 0);
#endif
@@ -334,7 +334,7 @@ int board_fix_fdt(void *rw_fdt_blob)
#if defined(CONFIG_BOARD_LATE_INIT)
int board_late_init(void)
{
-#if defined(CONFIG_DM_VIDEO)
+#if defined(CONFIG_VIDEO)
setup_lcd();
#endif
diff --git a/board/toradex/common/tdx-common.c b/board/toradex/common/tdx-common.c
index fadbe45..071961f 100644
--- a/board/toradex/common/tdx-common.c
+++ b/board/toradex/common/tdx-common.c
@@ -9,7 +9,7 @@
#include <init.h>
#include <linux/libfdt.h>
-#ifdef CONFIG_DM_VIDEO
+#ifdef CONFIG_VIDEO
#include <bmp_logo.h>
#include <dm.h>
#include <splash.h>