Commit 98cd5796 authored by Tomi Valkeinen's avatar Tomi Valkeinen

OMAPDSS: add setup for WB capture mode in dispc_wb_setup()

dispc_wb_setup() handles configuration only for mem-to-mem case. This
patch adds the necessary configuration to handle also display capture
mode.

We need to set CAPTUREMODE to 0 (continuous capture), and WBDELAYCOUNT
according to the vertical timings of the display, so that the WB FIFO
has time to flush before the next frame starts.
Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
parent 4c055ce0
...@@ -2859,8 +2859,23 @@ int dispc_wb_setup(const struct omap_dss_writeback_info *wi, ...@@ -2859,8 +2859,23 @@ int dispc_wb_setup(const struct omap_dss_writeback_info *wi,
l = FLD_MOD(l, mem_to_mem, 19, 19); /* WRITEBACKMODE */ l = FLD_MOD(l, mem_to_mem, 19, 19); /* WRITEBACKMODE */
if (mem_to_mem) if (mem_to_mem)
l = FLD_MOD(l, 1, 26, 24); /* CAPTUREMODE */ l = FLD_MOD(l, 1, 26, 24); /* CAPTUREMODE */
else
l = FLD_MOD(l, 0, 26, 24); /* CAPTUREMODE */
dispc_write_reg(DISPC_OVL_ATTRIBUTES(plane), l); dispc_write_reg(DISPC_OVL_ATTRIBUTES(plane), l);
if (mem_to_mem) {
/* WBDELAYCOUNT */
REG_FLD_MOD(DISPC_OVL_ATTRIBUTES2(plane), 0, 7, 0);
} else {
int wbdelay;
wbdelay = min(mgr_timings->vfp + mgr_timings->vsw +
mgr_timings->vbp, 255);
/* WBDELAYCOUNT */
REG_FLD_MOD(DISPC_OVL_ATTRIBUTES2(plane), wbdelay, 7, 0);
}
return r; return r;
} }
......
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