[gem] Hold a reference on the object in i915_gem_wait_space.
Otherwise, in the middle of the function called using it the last ref might disappear.main
parent
f8e38e49dd
commit
7078978db0
|
@ -982,7 +982,9 @@ i915_gem_wait_space(struct drm_device *dev)
|
|||
list);
|
||||
if (obj_priv == last_priv)
|
||||
break;
|
||||
drm_gem_object_reference(obj_priv->obj);
|
||||
ret = i915_gem_object_wait_rendering(obj_priv->obj);
|
||||
drm_gem_object_unreference(obj_priv->obj);
|
||||
if (ret)
|
||||
break;
|
||||
last_priv = obj_priv;
|
||||
|
|
Loading…
Reference in New Issue