diff options
author | Hai Li <hali@codeaurora.org> | 2015-07-27 20:49:45 +0300 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2015-08-16 01:27:22 +0300 |
commit | 78b1d470d57dd7a6e0efda63ebad97f0d44e817c (patch) | |
tree | df7ce98b79674d78b29fb050c21be46c1f69ea58 /drivers/gpu/drm/msm/msm_drv.h | |
parent | 8a94b0aa372ebf7375c8ea861cb9bbf84b39d2df (diff) | |
download | linux-78b1d470d57dd7a6e0efda63ebad97f0d44e817c.tar.xz |
drm/msm: Enable clocks during enable/disable_vblank() callbacks
AHB clock should be enabled before accessing registers during
enable/disable_vblank(). Since these 2 callbacks are called in
atomic context while clk_prepare may cause thread sleep, a work
is scheduled to control vblanks.
v2: fixup spinlock initialization
Signed-off-by: Hai Li <hali@codeaurora.org>
[add comment about cancel_work_sync() before drm_irq_uninstall()]
Signed-off-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/msm/msm_drv.h')
-rw-r--r-- | drivers/gpu/drm/msm/msm_drv.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/gpu/drm/msm/msm_drv.h b/drivers/gpu/drm/msm/msm_drv.h index c89c9352d31e..12c97cf27e13 100644 --- a/drivers/gpu/drm/msm/msm_drv.h +++ b/drivers/gpu/drm/msm/msm_drv.h @@ -71,6 +71,12 @@ enum msm_mdp_plane_property { PLANE_PROP_MAX_NUM }; +struct msm_vblank_ctrl { + struct work_struct work; + struct list_head event_list; + spinlock_t lock; +}; + struct msm_drm_private { struct msm_kms *kms; @@ -147,6 +153,8 @@ struct msm_drm_private { */ struct drm_mm mm; } vram; + + struct msm_vblank_ctrl vblank_ctrl; }; struct msm_format { |