summaryrefslogtreecommitdiff
path: root/linux-core
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2008-05-26 03:25:16 -0700
committerKeith Packard <keithp@keithp.com>2008-05-26 03:25:16 -0700
commitd434b64f6a760d85295e32298a9a1f3624ee1b69 (patch)
treed3b334ab5fd277c5fb159217f6bbe0edd3d88b9c /linux-core
parent7cf3fd29fe058a0bfc2ba7e889d1b360398be161 (diff)
[i915] leave interrupts masked off when not in use.
The interrupt enable register cannot be used to temporarily disable interrupts, instead use the interrupt mask register. Note that this change means that a pile of buffers will be left stuck on the chip as the final interrupts will not be recognized to come and drain things.
Diffstat (limited to 'linux-core')
-rw-r--r--linux-core/i915_gem.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/linux-core/i915_gem.c b/linux-core/i915_gem.c
index 99dc00fc..3ad3f40c 100644
--- a/linux-core/i915_gem.c
+++ b/linux-core/i915_gem.c
@@ -311,11 +311,13 @@ i915_wait_request(struct drm_device *dev, uint32_t seqno)
BUG_ON(seqno == 0);
- i915_user_irq_on(dev_priv);
- ret = wait_event_interruptible(dev_priv->irq_queue,
- i915_seqno_passed(i915_get_gem_seqno(dev),
- seqno));
- i915_user_irq_off(dev_priv);
+ if (!i915_seqno_passed(i915_get_gem_seqno(dev), seqno)) {
+ i915_user_irq_on(dev_priv);
+ ret = wait_event_interruptible(dev_priv->irq_queue,
+ i915_seqno_passed(i915_get_gem_seqno(dev),
+ seqno));
+ i915_user_irq_off(dev_priv);
+ }
/* Directly dispatch request retiring. While we have the work queue
* to handle this, the waiter on a request often wants an associated
@@ -1538,6 +1540,7 @@ int
i915_gem_flush_pwrite(struct drm_gem_object *obj,
uint64_t offset, uint64_t size)
{
+#if 0
struct drm_device *dev = obj->dev;
struct drm_i915_gem_object *obj_priv = obj->driver_private;
@@ -1555,6 +1558,7 @@ i915_gem_flush_pwrite(struct drm_gem_object *obj,
drm_agp_chipset_flush(dev);
obj->write_domain = 0;
}
+#endif
return 0;
}