summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRob Clark <robdclark@gmail.com>2014-03-24 09:12:24 -0400
committerRob Clark <robdclark@gmail.com>2014-03-31 10:27:46 -0400
commit30b6f8f6792abe582ef25100984a113ac9bc88dd (patch)
tree63e3bd92ed563fd972ed92ef93f4a7014f37d9fd
parent93ddb0d3b022dfbd963f243bd01741643cebfb28 (diff)
drm/msm/mdp: add timeout for irq wait
Make things recover a bit more gracefully if we get stuck with no vblank irq ever coming. Signed-off-by: Rob Clark <robdclark@gmail.com>
-rw-r--r--drivers/gpu/drm/msm/mdp/mdp_kms.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/msm/mdp/mdp_kms.c b/drivers/gpu/drm/msm/mdp/mdp_kms.c
index 3be48f7c36b..03455b64a24 100644
--- a/drivers/gpu/drm/msm/mdp/mdp_kms.c
+++ b/drivers/gpu/drm/msm/mdp/mdp_kms.c
@@ -101,7 +101,8 @@ void mdp_irq_wait(struct mdp_kms *mdp_kms, uint32_t irqmask)
.count = 1,
};
mdp_irq_register(mdp_kms, &wait.irq);
- wait_event(wait_event, (wait.count <= 0));
+ wait_event_timeout(wait_event, (wait.count <= 0),
+ msecs_to_jiffies(100));
mdp_irq_unregister(mdp_kms, &wait.irq);
}