mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 05:39:54 -04:00
disp: msm: dsi: Trigger ESD event if display isn't on
Check display turns on during the display resume. If it doesn't, then trigger the ESD to restart the panel, instead waiting until the ESD thread starts, detects, and perform ESD recovery. Port from: 17e936d Change-Id: I040b35c7ff27d35db15eedcbf94df80e6185da19 Signed-off-by: Bang Nguyen <bangnguyen@motorola.com> Reviewed-on: https://gerrit.mot.com/1697288 SLTApproved: Slta Waiver SME-Granted: SME Approvals Granted Tested-by: Jira Key Reviewed-by: Shuo Yan <shuoyan@motorola.com> Reviewed-by: Guobin Zhang <zhanggb@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
ffaa831b2a
commit
fc4eaf19ee
1 changed files with 19 additions and 0 deletions
|
|
@ -18,6 +18,8 @@
|
|||
#include "sde_dbg.h"
|
||||
#include "sde_dsc_helper.h"
|
||||
#include "sde_vdc_helper.h"
|
||||
#include "dsi_display.h"
|
||||
|
||||
|
||||
/**
|
||||
* topology is currently defined by a set of following 3 values:
|
||||
|
|
@ -3606,6 +3608,22 @@ end:
|
|||
|
||||
}
|
||||
|
||||
static int dsi_panel_trigger_panel_dead_event(struct dsi_panel *panel)
|
||||
{
|
||||
bool panel_dead;
|
||||
struct drm_event event;
|
||||
struct dsi_display *dsi_display = container_of(panel->host, struct dsi_display, host);
|
||||
struct drm_connector *drm_conn = dsi_display->drm_conn;
|
||||
|
||||
panel_dead = true;
|
||||
event.type = DRM_EVENT_PANEL_DEAD;
|
||||
event.length = sizeof(u32);
|
||||
msm_mode_object_event_notify(&drm_conn->base,
|
||||
drm_conn->dev, &event, (u8 *)&panel_dead);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
struct dsi_panel *dsi_panel_get(struct device *parent,
|
||||
struct device_node *of_node,
|
||||
struct device_node *parser_node,
|
||||
|
|
@ -4838,6 +4856,7 @@ int dsi_panel_enable(struct dsi_panel *panel)
|
|||
if (pwr_mode != panel->disp_on_chk_val) {
|
||||
DSI_ERR("%s: Read Pwr_mode=0%x is not matched with expected value =0x%x\n",
|
||||
__func__, pwr_mode, panel->disp_on_chk_val);
|
||||
dsi_panel_trigger_panel_dead_event(panel);
|
||||
} else
|
||||
DSI_INFO("-. Pwr_mode(0x0A) = 0x%x\n", pwr_mode);
|
||||
} else
|
||||
|
|
|
|||
Loading…
Reference in a new issue