From de8e41000136bf9a0ccf652fc364658f3210b6f4 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Thu, 5 Mar 2015 13:39:56 +0200 Subject: drm: omapdrm: Implement planes atomic operations Implement the CRTC .atomic_begin() and .atomic_flush() operations, the plane .atomic_check(), .atomic_update() and operations, and use the transitional atomic helpers to implement the plane update and disable operations on top of the new atomic operations. Signed-off-by: Laurent Pinchart Signed-off-by: Tomi Valkeinen --- drivers/gpu/drm/omapdrm/omap_crtc.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'drivers/gpu/drm/omapdrm/omap_crtc.c') diff --git a/drivers/gpu/drm/omapdrm/omap_crtc.c b/drivers/gpu/drm/omapdrm/omap_crtc.c index 5f4f5ad93345..277cad1dacf7 100644 --- a/drivers/gpu/drm/omapdrm/omap_crtc.c +++ b/drivers/gpu/drm/omapdrm/omap_crtc.c @@ -652,6 +652,18 @@ static int omap_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, return omap_crtc_flush(crtc); } +static void omap_crtc_atomic_begin(struct drm_crtc *crtc) +{ + dispc_runtime_get(); +} + +static void omap_crtc_atomic_flush(struct drm_crtc *crtc) +{ + omap_crtc_flush(crtc); + + dispc_runtime_put(); +} + static void page_flip_worker(struct work_struct *work) { struct omap_crtc *omap_crtc = @@ -792,6 +804,8 @@ static const struct drm_crtc_helper_funcs omap_crtc_helper_funcs = { .mode_set_base = omap_crtc_mode_set_base, .disable = omap_crtc_disable, .enable = omap_crtc_enable, + .atomic_begin = omap_crtc_atomic_begin, + .atomic_flush = omap_crtc_atomic_flush, }; /* ----------------------------------------------------------------------------- -- cgit v1.2.3