On Mon, Feb 10, 2014 at 04:30:49PM +0200, Mika Kuoppala wrote:
> From: Chris Wilson <ch...@chris-wilson.co.uk>
> 
> +     request = i915_gem_find_active_request(ring);
> +     if (request) {
> +             /* We need to copy these to an anonymous buffer as the simplest
> +              * method to avoid being overwritten by userspace.
> +              */
> +             return i915_error_object_create(dev_priv, request->batch_obj, 
> request->ctx->vm);

This needs to protect against ctx == NULL, e.g.
  request->ctx ? request->ctx->vm : &dev_priv->gtt.base)
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to