diff options
author | Mark Yao <mark.yao@rock-chips.com> | 2015-12-16 13:09:38 +0300 |
---|---|---|
committer | Mark Yao <mark.yao@rock-chips.com> | 2015-12-28 03:49:54 +0300 |
commit | f32fad51eec51ad816cecdc3723ab443cd69b61f (patch) | |
tree | 4379da1a36a7f0c3a7925925ba9fa7a55d1b977b /drivers/gpu/drm/rockchip/rockchip_drm_drv.h | |
parent | ce3887ed0d996e6353d739e8139b8e5faeb726d5 (diff) | |
download | linux-f32fad51eec51ad816cecdc3723ab443cd69b61f.tar.xz |
drm/rockchip: support atomic asynchronous commit
If drm core requests a async commit, rockchip_drm_atomic_commit
will schedule a work task to update later.
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
Diffstat (limited to 'drivers/gpu/drm/rockchip/rockchip_drm_drv.h')
-rw-r--r-- | drivers/gpu/drm/rockchip/rockchip_drm_drv.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/drm/rockchip/rockchip_drm_drv.h b/drivers/gpu/drm/rockchip/rockchip_drm_drv.h index 4468f98ec437..bb8b076f1dbb 100644 --- a/drivers/gpu/drm/rockchip/rockchip_drm_drv.h +++ b/drivers/gpu/drm/rockchip/rockchip_drm_drv.h @@ -42,6 +42,13 @@ struct rockchip_crtc_funcs { void (*wait_for_update)(struct drm_crtc *crtc); }; +struct rockchip_atomic_commit { + struct work_struct work; + struct drm_atomic_state *state; + struct drm_device *dev; + struct mutex lock; +}; + /* * Rockchip drm private structure. * @@ -52,8 +59,11 @@ struct rockchip_drm_private { struct drm_fb_helper fbdev_helper; struct drm_gem_object *fbdev_bo; const struct rockchip_crtc_funcs *crtc_funcs[ROCKCHIP_MAX_CRTC]; + + struct rockchip_atomic_commit commit; }; +void rockchip_drm_atomic_work(struct work_struct *work); int rockchip_register_crtc_funcs(struct drm_crtc *crtc, const struct rockchip_crtc_funcs *crtc_funcs); void rockchip_unregister_crtc_funcs(struct drm_crtc *crtc); |