diff options
author | Laurentiu Palcu <laurentiu.palcu@nxp.com> | 2018-06-04 14:47:36 +0300 |
---|---|---|
committer | Jason Liu <jason.hui.liu@nxp.com> | 2019-02-12 10:32:15 +0800 |
commit | 7ad6072a37fad26351894376f2674d526a0281a8 (patch) | |
tree | 3fe2977d9e52f07366ced049edcb013374f759a9 /include/video | |
parent | e67bb6ee2fd308b12984ef27c683d7defcc665d7 (diff) |
MLK-17925: drm: imx: dcss: fix tearing
The video tearing appeared only when the application used 2 buffers.
That's because, sometimes, the context loader could be armed after the
DB event came in the frame trace. That made a buffer submitted in frame
N end up on screen in frame N+2 because the context loader waits for the
next DB event. Since vblank events are sent at the end of the frame, by
the time the buffer lands on screen, the application will reuse it while
it's being displayed, hence the tearing effect.
This patch moves the CTXLD trigger moment all the way to the end of the
frame trace, just before DB event arrives. This will leave the
application plenty of time to submit new buffers.
In the event that the trigger moment is missed (application submits a
buffer right at the end of a frame trace), then we're not signalling the
next VBLANK event to application. This way, application will know that
the buffer is still needed and will not submit a new one.
Signed-off-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
Diffstat (limited to 'include/video')
-rw-r--r-- | include/video/imx-dcss.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/video/imx-dcss.h b/include/video/imx-dcss.h index 2b63cbcb090e..c0d5dd8fb37f 100644 --- a/include/video/imx-dcss.h +++ b/include/video/imx-dcss.h @@ -106,6 +106,7 @@ bool dcss_scaler_can_scale(struct dcss_soc *dcss, int ch_num, /* CTXLD */ int dcss_ctxld_enable(struct dcss_soc *dcss); +bool dcss_ctxld_is_flushed(struct dcss_soc *dcss); /* HDR10 */ enum dcss_hdr10_nonlinearity { |