[Intel-gfx] [PATCH] drm/i915: Revert "drm/i915: Reject the pin ioctl on gen6+"

Daniel Vetter daniel at ffwll.ch
Mon Jul 7 23:04:55 CEST 2014


On Thu, Jul 03, 2014 at 08:12:35AM +0100, Damien Lespiau wrote:
> This reverts commit 02f6bcccf7c324115747aae2f0addd6af5d321cd.
> 
> The OA buffer can contain global data (in particular, not linked to a
> context or a single batch execution) about GPU events (eg. hw context
> switches, rc6 transitions, frequency changes, ...) and needs to be
> mapped to GGTT. The pin ioctl provided a way to do that.
> 
> Admittedly, this change broke what seems to be a valid use case of
> pinning a buffer in GGTT, even when PPGTT is used (which is the reason
> invoked in the commit message).

Global OA buffers should be handled by the kernel and exposed through
perf, imo. I think I'll go lalala on this a bit longer ...
-Daniel

> 
> Cc: Daniel Vetter <daniel.vetter at ffwll.ch>
> Cc: Tomasz Madajczak <tomasz.madajczak at intel.com>
> Cc: Adam Rutkowski <adam.j.rutkowski at intel.com>
> 
> Signed-off-by: Damien Lespiau <damien.lespiau at intel.com>
> ---
>  drivers/gpu/drm/i915/i915_gem.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
> index 1794a04..8019809 100644
> --- a/drivers/gpu/drm/i915/i915_gem.c
> +++ b/drivers/gpu/drm/i915/i915_gem.c
> @@ -4143,9 +4143,6 @@ i915_gem_pin_ioctl(struct drm_device *dev, void *data,
>  	struct drm_i915_gem_object *obj;
>  	int ret;
>  
> -	if (INTEL_INFO(dev)->gen >= 6)
> -		return -ENODEV;
> -
>  	ret = i915_mutex_lock_interruptible(dev);
>  	if (ret)
>  		return ret;
> -- 
> 1.8.3.1
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch



More information about the Intel-gfx mailing list