summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/i915/i915_dma.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2010-09-26 11:03:27 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2010-09-26 11:03:27 +0100
commit1c25595f8d31392b8c36b54c624d01591dbfb87b (patch)
tree961ce6bb76bdc7aa7b245bb77fa054df6ee9b463 /drivers/gpu/drm/i915/i915_dma.c
parent447da18742b170b8e09ac71edf63c5798d2dbb0b (diff)
drm/i915: Convert the file mutex into a spinlock
Daniel Vetter pointed out that in this case is would be clearer and cleaner to use a spinlock instead of a mutex to protect the per-file request list manipulation. Make it so. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r--drivers/gpu/drm/i915/i915_dma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c
index ba050ed8df5..b752c31fbcf 100644
--- a/drivers/gpu/drm/i915/i915_dma.c
+++ b/drivers/gpu/drm/i915/i915_dma.c
@@ -2173,8 +2173,8 @@ int i915_driver_open(struct drm_device *dev, struct drm_file *file)
file->driver_priv = file_priv;
+ spin_lock_init(&file_priv->mm.lock);
INIT_LIST_HEAD(&file_priv->mm.request_list);
- mutex_init(&file_priv->mutex);
return 0;
}