diff options
| author | Ujwal Patel <ujwalp@codeaurora.org> | 2015-10-29 13:49:36 -0700 |
|---|---|---|
| committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 20:47:37 -0700 |
| commit | aed000e0159225380716df09909c0b2cde06ec2e (patch) | |
| tree | 7bf27304bafa5c600cc59a13eb3ce2972b786ba1 | |
| parent | c529db234206ad9e49a1e2b6cb7908292db09939 (diff) | |
msm: mdss: update initial line buffering for DSC
Change initial line buffering calculations for DSC as per updated
recommendations. Without enough buffering, in certain conditions DSI
underflow can be observed.
CRs-fixed: 932124
Change-Id: Ia1b04558104061020981ade9a9c86777902360c2
Signed-off-by: Ujwal Patel <ujwalp@codeaurora.org>
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_dsi_panel.c | 2 | ||||
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_mdp_ctl.c | 9 |
2 files changed, 8 insertions, 3 deletions
diff --git a/drivers/video/fbdev/msm/mdss_dsi_panel.c b/drivers/video/fbdev/msm/mdss_dsi_panel.c index 45f84232f663..6132c7fb317e 100644 --- a/drivers/video/fbdev/msm/mdss_dsi_panel.c +++ b/drivers/video/fbdev/msm/mdss_dsi_panel.c @@ -1207,7 +1207,7 @@ int mdss_dsc_initial_line_calc(int bpc, int xmit_delay, int total_pixels; ssm_delay = ((bpc < 10) ? 83 : 91); - total_pixels = ssm_delay * 3 + 30 + xmit_delay + 6; + total_pixels = ssm_delay * 3 + xmit_delay + 47; total_pixels += ((slice_per_line > 1) ? (ssm_delay * 3) : 0); return CEIL(total_pixels, slice_width); diff --git a/drivers/video/fbdev/msm/mdss_mdp_ctl.c b/drivers/video/fbdev/msm/mdss_mdp_ctl.c index f6bc5287a1d4..49fd2383ab89 100644 --- a/drivers/video/fbdev/msm/mdss_mdp_ctl.c +++ b/drivers/video/fbdev/msm/mdss_mdp_ctl.c @@ -2423,6 +2423,8 @@ static void mdss_mdp_ctl_dsc_config(struct mdss_mdp_mixer *mixer, int bpp, lsb; struct mdss_data_type *mdata = mdss_mdp_get_mdata(); char __iomem *offset = mdata->mdp_base; + u32 initial_lines = dsc->initial_lines; + bool is_cmd_mode = !(mode & BIT(2)); data = mdss_mdp_pingpong_read(mixer->pingpong_base, MDSS_MDP_REG_PP_DCE_DATA_OUT_SWAP); @@ -2445,7 +2447,10 @@ static void mdss_mdp_ctl_dsc_config(struct mdss_mdp_mixer *mixer, if (ich_reset_override) data = 3 << 28; - data |= (dsc->initial_lines << 20); + if (is_cmd_mode) + initial_lines += 1; + + data |= (initial_lines << 20); data |= ((dsc->slice_last_group_size - 1) << 18); /* bpp is 6.4 format, 4 LSBs bits are for fractional part */ lsb = dsc->bpp % 4; @@ -2462,7 +2467,7 @@ static void mdss_mdp_ctl_dsc_config(struct mdss_mdp_mixer *mixer, pr_debug("%d %d %d %d %d %d %d %d %d, data=%x\n", ich_reset_override, - dsc->initial_lines , dsc->slice_last_group_size, + initial_lines , dsc->slice_last_group_size, dsc->bpp, dsc->block_pred_enable, dsc->line_buf_depth, dsc->enable_422, dsc->convert_rgb, dsc->input_10_bits, data); |
