aboutsummaryrefslogtreecommitdiff
path: root/shared-core/i915_dma.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2008-06-13 09:19:30 -0700
committerKeith Packard <keithp@keithp.com>2008-06-13 14:29:46 -0700
commit462af73149b9286a74b95b9cda5e4224ebe0dd87 (patch)
treef205a0286d7c070e3d70be096e0eb045f043867f /shared-core/i915_dma.c
parente5364914ac2b785f9d806c72fff8d2ae914cad61 (diff)
[intel-gem] Use a delayed_work instead of a timer + work_struct
We want request retirement to occur about once a second when the request queue is non-empty. This was done with a timer that queued a work_struct, using a delayed_work instead makes a lot more sense.
Diffstat (limited to 'shared-core/i915_dma.c')
-rw-r--r--shared-core/i915_dma.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/shared-core/i915_dma.c b/shared-core/i915_dma.c
index 667a6ac0..669f1e4e 100644
--- a/shared-core/i915_dma.c
+++ b/shared-core/i915_dma.c
@@ -1072,11 +1072,8 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
INIT_LIST_HEAD(&dev_priv->mm.flushing_list);
INIT_LIST_HEAD(&dev_priv->mm.inactive_list);
INIT_LIST_HEAD(&dev_priv->mm.request_list);
- dev_priv->mm.retire_timer.function = i915_gem_retire_timeout;
- dev_priv->mm.retire_timer.data = (unsigned long) dev;
- init_timer_deferrable (&dev_priv->mm.retire_timer);
- INIT_WORK(&dev_priv->mm.retire_task,
- i915_gem_retire_handler);
+ INIT_DELAYED_WORK(&dev_priv->mm.retire_work,
+ i915_gem_retire_work_handler);
dev_priv->mm.next_gem_seqno = 1;
#ifdef __linux__