提交 e3848694 编写于 作者: M Mika Kuoppala 提交者: Daniel Vetter

drm/i915: release mutex in i915_gem_init()'s error path

Found with smatch.
Signed-off-by: NMika Kuoppala <mika.kuoppala@intel.com>
Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
上级 7f76b23a
......@@ -4467,8 +4467,10 @@ int i915_gem_init(struct drm_device *dev)
i915_gem_init_global_gtt(dev);
ret = i915_gem_context_init(dev);
if (ret)
if (ret) {
mutex_unlock(&dev->struct_mutex);
return ret;
}
ret = i915_gem_init_hw(dev);
mutex_unlock(&dev->struct_mutex);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册