aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2016-06-13 19:42:00 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-06-14 01:57:20 -0400
commitb0212486909de4f239ca9f20d032de1b1f2dc52e (patch)
tree0362c8e4f1380f526e13a2ad4e7da02e5019ebdd
parentc02726ffea2df09acc46adb049a7fb4ea10f0e05 (diff)
drm/i915: Fix missing unlock on error in i915_ppgtt_info()
Add the missing unlock before return from function i915_ppgtt_info() in the error handling case. Fixes: 1d2ac403ae3b(drm: Protect dev->filelist with its own mutex) Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch> Link: http://patchwork.freedesktop.org/patch/msgid/1465861320-26221-1-git-send-email-weiyj_lk@163.com
-rw-r--r--drivers/gpu/drm/i915/i915_debugfs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index e4f2c55d9697..614ac085e51f 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -2393,16 +2393,16 @@ static int i915_ppgtt_info(struct seq_file *m, void *data)
2393 task = get_pid_task(file->pid, PIDTYPE_PID); 2393 task = get_pid_task(file->pid, PIDTYPE_PID);
2394 if (!task) { 2394 if (!task) {
2395 ret = -ESRCH; 2395 ret = -ESRCH;
2396 goto out_put; 2396 goto out_unlock;
2397 } 2397 }
2398 seq_printf(m, "\nproc: %s\n", task->comm); 2398 seq_printf(m, "\nproc: %s\n", task->comm);
2399 put_task_struct(task); 2399 put_task_struct(task);
2400 idr_for_each(&file_priv->context_idr, per_file_ctx, 2400 idr_for_each(&file_priv->context_idr, per_file_ctx,
2401 (void *)(unsigned long)m); 2401 (void *)(unsigned long)m);
2402 } 2402 }
2403out_unlock:
2403 mutex_unlock(&dev->filelist_mutex); 2404 mutex_unlock(&dev->filelist_mutex);
2404 2405
2405out_put:
2406 intel_runtime_pm_put(dev_priv); 2406 intel_runtime_pm_put(dev_priv);
2407 mutex_unlock(&dev->struct_mutex); 2407 mutex_unlock(&dev->struct_mutex);
2408 2408