mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-08 20:07:46 +09:00
lcd: add lcd tv driver when the panel disable in uboot [1/1]
PD#SWPL-5937 Problem: need screen initialization moved from uboot to kernel Solution: 1, add lcd tv driver when the panel disable in uboot Verify: t962x2-x301 Change-Id: Ia7837db5f6581543b2a093357a264ee63dbd33a9 Signed-off-by: shaochan.liu <shaochan.liu@amlogic.com>
This commit is contained in:
@@ -44,6 +44,7 @@
|
||||
|
||||
static unsigned int lcd_output_vmode;
|
||||
static char lcd_output_name[30];
|
||||
static int lcd_init_on_flag;
|
||||
|
||||
/* ************************************************** *
|
||||
* lcd mode function
|
||||
@@ -331,7 +332,19 @@ static int lcd_set_current_vmode(enum vmode_e mode)
|
||||
if (VMODE_LCD == (mode & VMODE_MODE_BIT_MASK)) {
|
||||
if (mode & VMODE_INIT_BIT_MASK) {
|
||||
lcd_clk_gate_switch(1);
|
||||
} else {
|
||||
} else if (lcd_init_on_flag == 0) {
|
||||
lcd_init_on_flag = 1;
|
||||
if ((lcd_drv->lcd_key_valid == 0)
|
||||
&& !(lcd_drv->lcd_status & LCD_STATUS_ENCL_ON)) {
|
||||
aml_lcd_notifier_call_chain
|
||||
(LCD_EVENT_POWER_ON, NULL);
|
||||
lcd_if_enable_retry(lcd_drv->lcd_config);
|
||||
} else if (lcd_drv->driver_change != NULL) {
|
||||
mutex_lock(&lcd_vout_mutex);
|
||||
ret = lcd_drv->driver_change();
|
||||
mutex_unlock(&lcd_vout_mutex);
|
||||
}
|
||||
} else if (lcd_init_on_flag == 1) {
|
||||
mutex_lock(&lcd_vout_mutex);
|
||||
ret = lcd_drv->driver_change();
|
||||
mutex_unlock(&lcd_vout_mutex);
|
||||
|
||||
@@ -1026,6 +1026,13 @@ static void lcd_config_probe_delayed(struct work_struct *work)
|
||||
lcd_driver = NULL;
|
||||
LCDERR("probe exit\n");
|
||||
}
|
||||
|
||||
if ((lcd_driver->lcd_status & LCD_STATUS_VMODE_ACTIVE)
|
||||
&& !(lcd_driver->lcd_status & LCD_STATUS_ENCL_ON)) {
|
||||
LCDPR("%s: lcd_enable in kernel\n", __func__);
|
||||
aml_lcd_notifier_call_chain(LCD_EVENT_POWER_ON, NULL);
|
||||
lcd_if_enable_retry(lcd_driver->lcd_config);
|
||||
}
|
||||
}
|
||||
|
||||
static void lcd_config_default(void)
|
||||
|
||||
Reference in New Issue
Block a user