Commit b994e53c authored by Tomi Valkeinen's avatar Tomi Valkeinen

drm/omap: fix WBDELAYCOUNT with interlace

Vertical blanking needs to be halved on interlace modes. WBDELAYCOUNT
was calculated without such halving, resulting in WBUNCOMPLETE errors.
Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
Acked-by: default avatarBenoit Parrot <bparrot@ti.com>
parent 46a93041
...@@ -2814,14 +2814,18 @@ int dispc_wb_setup(struct dispc_device *dispc, ...@@ -2814,14 +2814,18 @@ int dispc_wb_setup(struct dispc_device *dispc,
/* WBDELAYCOUNT */ /* WBDELAYCOUNT */
REG_FLD_MOD(dispc, DISPC_OVL_ATTRIBUTES2(plane), 0, 7, 0); REG_FLD_MOD(dispc, DISPC_OVL_ATTRIBUTES2(plane), 0, 7, 0);
} else { } else {
int wbdelay; u32 wbdelay;
if (channel_in == DSS_WB_TV_MGR) if (channel_in == DSS_WB_TV_MGR)
wbdelay = min(vm->vsync_len + vm->vback_porch, wbdelay = vm->vsync_len + vm->vback_porch;
(u32)255);
else else
wbdelay = min(vm->vfront_porch + wbdelay = vm->vfront_porch + vm->vsync_len +
vm->vsync_len + vm->vback_porch, (u32)255); vm->vback_porch;
if (vm->flags & DISPLAY_FLAGS_INTERLACED)
wbdelay /= 2;
wbdelay = min(wbdelay, 255u);
/* WBDELAYCOUNT */ /* WBDELAYCOUNT */
REG_FLD_MOD(dispc, DISPC_OVL_ATTRIBUTES2(plane), wbdelay, 7, 0); REG_FLD_MOD(dispc, DISPC_OVL_ATTRIBUTES2(plane), wbdelay, 7, 0);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment