msm: mdss: fix potential crash when sending backlight DCS commands
If MDSS idle power collapse feature is enabled, MDSS GDSC can get toggled when exiting idle power collapse. This may require an explicit call to TZ to restore MDSS security configs prior to accessing any MDSS registers, which is typically done whenever IOMMU is attached. For panels where backlight is controlled using DCS commands, it is possible that a backlight update could be triggered when MDSS is power collapsed. This would result in enabling MDSS GDSC and restoring DSI registers prior to sending the DCS commands. For such use cases, ensure that IOMMU is attached prior to any register programming to avoid any crashes. Change-Id: I245d1180cfeedeb938e70b792fd6d627e86c5d14 Signed-off-by: Aravind Venkateswaran <aravindh@codeaurora.org>
This commit is contained in:
parent
b088e80929
commit
4a73f2adf8
1 changed files with 2 additions and 1 deletions
|
@ -2023,7 +2023,6 @@ int mdss_dsi_cmdlist_commit(struct mdss_dsi_ctrl_pdata *ctrl, int from_mdp)
|
|||
ctrl->mdss_util->bus_scale_set_quota(MDSS_DSI_RT, SZ_1M, SZ_1M);
|
||||
|
||||
pr_debug("%s: from_mdp=%d pid=%d\n", __func__, from_mdp, current->pid);
|
||||
mdss_dsi_clk_ctrl(ctrl, DSI_ALL_CLKS, 1);
|
||||
|
||||
if (ctrl->mdss_util->iommu_ctrl) {
|
||||
rc = ctrl->mdss_util->iommu_ctrl(1);
|
||||
|
@ -2034,6 +2033,8 @@ int mdss_dsi_cmdlist_commit(struct mdss_dsi_ctrl_pdata *ctrl, int from_mdp)
|
|||
}
|
||||
}
|
||||
|
||||
mdss_dsi_clk_ctrl(ctrl, DSI_ALL_CLKS, 1);
|
||||
|
||||
if (req->flags & CMD_REQ_HS_MODE)
|
||||
mdss_dsi_set_tx_power_mode(0, &ctrl->panel_data);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue