From 2642e635f24ba4c28d64b7b602456275beeef79d Mon Sep 17 00:00:00 2001 From: Robert Noland Date: Thu, 25 Jun 2009 15:47:32 +0000 Subject: [PATCH] Keep track of the hardware counter more aggressively while interrupts are enabled. This should help to reduce cases where the hardware counter reference jumps by large amounts. MFC after: 3 days --- sys/dev/drm/drm_irq.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/dev/drm/drm_irq.c b/sys/dev/drm/drm_irq.c index be513e235523..4c1f8652e44e 100644 --- a/sys/dev/drm/drm_irq.c +++ b/sys/dev/drm/drm_irq.c @@ -325,6 +325,10 @@ int drm_vblank_get(struct drm_device *dev, int crtc) } } + if (dev->vblank[crtc].enabled) + dev->vblank[crtc].last = + dev->driver->get_vblank_counter(dev, crtc); + return ret; }