diff options
author | Jesse Barnes <jbarnes@virtuousgeek.org> | 2009-02-06 10:22:41 -0800 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2009-02-08 21:43:04 +1000 |
commit | 9880b7a527ffbb52f65c2de0a8d4eea86e24775e (patch) | |
tree | 5c41b544a86c04de609c4dad245bb93cd2e000e7 /drivers/gpu/drm/i915/i915_dma.c | |
parent | 14d200c5e5bd19219d930bbb9a5a22758c8f5bec (diff) |
drm/i915: add get_vblank_counter function for GM45
As discussed in the long thread about vblank related timeouts, it turns out
GM45 has different frame count registers than previous chips. This patch
adds support for them, which prevents us from waiting on really stale
sequence values in drm_wait_vblank (which rather than returning immediately
ends up timing out or getting interrupted).
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r-- | drivers/gpu/drm/i915/i915_dma.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c index 0ded483d9ac..81f1cff56fd 100644 --- a/drivers/gpu/drm/i915/i915_dma.c +++ b/drivers/gpu/drm/i915/i915_dma.c @@ -1112,6 +1112,10 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags) dev_priv->has_gem = 1; #endif + dev->driver->get_vblank_counter = i915_get_vblank_counter; + if (IS_GM45(dev)) + dev->driver->get_vblank_counter = gm45_get_vblank_counter; + i915_gem_load(dev); /* Init HWS */ |