From bbf3d7949ffadf87ad8274ec0380a2a5c11a509e Mon Sep 17 00:00:00 2001 From: Raviteja Tamatam Date: Thu, 4 Jun 2020 17:49:51 +0530 Subject: [PATCH] disp: msm: sde: modify from fixed to variable programmable fetch start With 120 fps panels and vfp method of dfps ,the vfp is very large in lower fps and there is huge time gap between programmable fetch start (MDP vsync) and panel vsync. As fence is released early timing registers are modified by the next commit before the previous timing parameters takes effect and this is leading to underrun. With variable programmable fetch start MDP vsync is close to panel vsync and avoids such condition. Change-Id: Id88b5e2957bf4af751f49f1f32327715a34b102b Signed-off-by: Raviteja Tamatam --- msm/sde/sde_encoder_phys_vid.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/msm/sde/sde_encoder_phys_vid.c b/msm/sde/sde_encoder_phys_vid.c index 5898eea83c28..98ab00c5997d 100644 --- a/msm/sde/sde_encoder_phys_vid.c +++ b/msm/sde/sde_encoder_phys_vid.c @@ -279,9 +279,9 @@ static void programmable_fetch_config(struct sde_encoder_phys *phys_enc, m = phys_enc->sde_kms->catalog; vfp_fetch_lines = programmable_fetch_get_num_lines(vid_enc, - timing, true); + timing, false); if (vfp_fetch_lines) { - vert_total = get_vertical_total(timing, true); + vert_total = get_vertical_total(timing, false); horiz_total = get_horizontal_total(timing); vfp_fetch_start_vsync_counter = (vert_total - vfp_fetch_lines) * horiz_total + 1;