diff options
author | Inki Dae <inki.dae@samsung.com> | 2014-10-24 12:09:35 +0900 |
---|---|---|
committer | Inki Dae <inki.dae@samsung.com> | 2014-10-23 21:26:46 -0700 |
commit | d69e45dccaea2e2da28751e0bdaeae67bba1aa78 (patch) | |
tree | 73638e54557d333225d55c9f65cf8800b12c7e66 /drivers/gpu | |
parent | 8c9cfccfd06aeba4c06ca1b3ec27c75d5092523f (diff) | |
download | linux-3.10-d69e45dccaea2e2da28751e0bdaeae67bba1aa78.tar.gz linux-3.10-d69e45dccaea2e2da28751e0bdaeae67bba1aa78.tar.bz2 linux-3.10-d69e45dccaea2e2da28751e0bdaeae67bba1aa78.zip |
drm/exynos: fimd: make a wait_for_vblank event to be handled in same period
This patch makes sure for a wait_for_vblank event to be handled
in same period. For this, it adds a new member, triggerred which
means whether trigger request is completed or not since trigger
request.
So if there is a trigger request, update-request, then this patch makes
a wait_for_vblank event to be handled after the trigger request is
completed.
Change-Id: If1a2491a323b637d20806373e0502b2b0a9ff810
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_fimd.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index 37583ae0ab3..1500128e02f 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fimd.c +++ b/drivers/gpu/drm/exynos/exynos_drm_fimd.c @@ -165,6 +165,7 @@ struct fimd_context { atomic_t wait_vsync_event; atomic_t win_updated; atomic_t triggering; + atomic_t triggerred; spinlock_t win_updated_lock; struct exynos_drm_panel_info panel; @@ -985,6 +986,13 @@ static int fimd_te_handler(struct exynos_drm_manager *mgr) if (atomic_read(&ctx->triggering)) return 0; + + /* Handle wait for vblank request in case of in-trigger. */ + if (atomic_read(&ctx->triggerred)) { + atomic_set(&ctx->triggerred, 0); + drm_handle_vblank(ctx->drm_dev, ctx->pipe); + } + spin_lock_irqsave(&ctx->win_updated_lock, flags); /* @@ -995,6 +1003,7 @@ static int fimd_te_handler(struct exynos_drm_manager *mgr) atomic_set(&ctx->win_updated, 0); spin_unlock_irqrestore(&ctx->win_updated_lock, flags); + atomic_set(&ctx->triggerred, 1); fimd_trigger(ctx->dev); spin_lock_irqsave(&ctx->win_updated_lock, flags); |