diff options
author | =?utf-8?q?Michel_D=C3=A4nzer?= <michel@tungstengraphics.com> | 2006-10-24 23:34:58 +1000 |
---|---|---|
committer | airlied <airlied@linux.ie> | 2006-12-07 15:53:29 +1100 |
commit | 049b323321bbcb476b799f50dc6444c0ed5a0e0e (patch) | |
tree | 86c57b038dcb7a6de4b6a7af8c276550d6b9524b /drivers/char | |
parent | ab285d74e6742422fd0465577a31fb03fe9ed241 (diff) |
drm: Core vsync: Don't clobber target sequence number when scheduling signal.
It looks like this would have caused signals to always get sent on the next
vertical blank, regardless of the sequence number.
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/drm/drm_irq.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/char/drm/drm_irq.c b/drivers/char/drm/drm_irq.c index 78aae5b35c6..9d00c51fe2c 100644 --- a/drivers/char/drm/drm_irq.c +++ b/drivers/char/drm/drm_irq.c @@ -296,8 +296,6 @@ int drm_wait_vblank(DRM_IOCTL_ARGS) ? &dev->vbl_sigs2 : &dev->vbl_sigs; drm_vbl_sig_t *vbl_sig; - vblwait.reply.sequence = seq; - spin_lock_irqsave(&dev->vbl_lock, irqflags); /* Check if this task has already scheduled the same signal @@ -310,6 +308,7 @@ int drm_wait_vblank(DRM_IOCTL_ARGS) && vbl_sig->task == current) { spin_unlock_irqrestore(&dev->vbl_lock, irqflags); + vblwait.reply.sequence = seq; goto done; } } @@ -340,6 +339,8 @@ int drm_wait_vblank(DRM_IOCTL_ARGS) list_add_tail((struct list_head *)vbl_sig, &vbl_sigs->head); spin_unlock_irqrestore(&dev->vbl_lock, irqflags); + + vblwait.reply.sequence = seq; } else { if (flags & _DRM_VBLANK_SECONDARY) { if (dev->driver->vblank_wait2) |