[Intel-gfx] [PATCH] Revert "drm/i915: Allocate context objects from stolen"

Jani Nikula jani.nikula at linux.intel.com
Tue Jun 30 01:31:54 PDT 2015


On Mon, 29 Jun 2015, ville.syrjala at linux.intel.com wrote:
> From: Ville Syrjälä <ville.syrjala at linux.intel.com>
>
> Stolen gets trashed during hibernation, so storing contexts there
> is not a very good idea. On my IVB machines this leads to a totally
> dead GPU on resume. A reboot is required to resurrect it. So let's
> not store contexts where they will get trampled.
>
> This reverts commit 149c86e74fe44dcbac5e9f8d145c5fbc5dc21261.

Looks like a *partial* revert of

commit 149c86e74fe44dcbac5e9f8d145c5fbc5dc21261
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Tue Apr 7 16:21:11 2015 +0100

    drm/i915: Allocate context objects from stolen

and the not reverted hunk has been touched since in 

commit 3126a660f352b3fe48125a8a0b4fdbf85935d8bf
Author: Dan Carpenter <dan.carpenter at oracle.com>
Date:   Thu Apr 30 17:30:50 2015 +0300

    drm/i915: checking IS_ERR() instead of NULL

The commit message should say it's a partial revert and not claim
otherwise, and document why not everything was reverted.

The above commits are in Linus' tree.

BR,
Jani.

>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
> Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
> ---
>  drivers/gpu/drm/i915/i915_gem_context.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_gem_context.c b/drivers/gpu/drm/i915/i915_gem_context.c
> index a7e58a8..5c7ccf4 100644
> --- a/drivers/gpu/drm/i915/i915_gem_context.c
> +++ b/drivers/gpu/drm/i915/i915_gem_context.c
> @@ -157,9 +157,7 @@ i915_gem_alloc_context_obj(struct drm_device *dev, size_t size)
>  	struct drm_i915_gem_object *obj;
>  	int ret;
>  
> -	obj = i915_gem_object_create_stolen(dev, size);
> -	if (obj == NULL)
> -		obj = i915_gem_alloc_object(dev, size);
> +	obj = i915_gem_alloc_object(dev, size);
>  	if (obj == NULL)
>  		return ERR_PTR(-ENOMEM);
>  
> -- 
> 2.3.6
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Jani Nikula, Intel Open Source Technology Center


More information about the Intel-gfx mailing list