summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/exynos/exynos_drm_encoder.c
diff options
context:
space:
mode:
authorInki Dae <inki.dae@samsung.com>2012-08-20 19:55:14 +0900
committerInki Dae <inki.dae@samsung.com>2012-10-04 10:05:59 +0900
commitb011941f0ffdefb87585d9ed786164037d0d50df (patch)
tree5108a8c71a1177206a44e695d7a1f3d9e6709a10 /drivers/gpu/drm/exynos/exynos_drm_encoder.c
parent50caf25c583b938c681b61e64dac58da9b640f2f (diff)
downloadlinux-b011941f0ffdefb87585d9ed786164037d0d50df.tar.bz2
drm/exynos: add wait_for_vblank callback interface.
Changelog v2: fixed comments. Changelog v1: this interface can be used to make sure that hardware overlay is disabled to avoid that memory region is accessed by dma after gem buffer was released. Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_encoder.c')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_encoder.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_encoder.c b/drivers/gpu/drm/exynos/exynos_drm_encoder.c
index 08ba62fe2f16..f4531167fda6 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_encoder.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_encoder.c
@@ -430,4 +430,14 @@ void exynos_drm_encoder_plane_disable(struct drm_encoder *encoder, void *data)
if (overlay_ops && overlay_ops->disable)
overlay_ops->disable(manager->dev, zpos);
+
+ /*
+ * wait for vblank interrupt
+ * - this makes sure that hardware overlay is disabled to avoid
+ * for the dma accesses to memory after gem buffer was released
+ * because the setting for disabling the overlay will be updated
+ * at vsync.
+ */
+ if (overlay_ops->wait_for_vblank)
+ overlay_ops->wait_for_vblank(manager->dev);
}