[Intel-gfx] [PATCH 52/55] drm/i915: Track active vma requests

Joonas Lahtinen joonas.lahtinen at linux.intel.com
Wed Jul 27 09:47:46 UTC 2016


On ma, 2016-07-25 at 18:32 +0100, Chris Wilson wrote:

> diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.h b/drivers/gpu/drm/i915/i915_gem_gtt.h
> index 529fb483afc8..d2206f40f7b2 100644
> --- a/drivers/gpu/drm/i915/i915_gem_gtt.h
> +++ b/drivers/gpu/drm/i915/i915_gem_gtt.h
>  
> +static inline bool i915_vma_is_active(const struct i915_vma *vma)
> +{
> +	return vma->active;
> +}
> +
> +static inline void i915_vma_set_active(struct i915_vma *vma,
> +				       unsigned int engine)
> +{
> +	vma->active |= BIT(engine);
> +}
> +
> +static inline void i915_vma_unset_active(struct i915_vma *vma,
> +					 unsigned int engine)
> +{
> +	vma->active &= ~BIT(engine);
> +}
> +
> +static inline bool i915_vma_has_active_engine(const struct i915_vma *vma,
> +					      unsigned int engine)
> +{
> +	return vma->active & BIT(engine);
> +}
> +

Are these going to grow more complex? Otherwise looks fine,

Reviewed-by: Joonas Lahtinen <joonas.lahtinen at linux.intel.com>

Regards, Joonas
-- 
Joonas Lahtinen
Open Source Technology Center
Intel Corporation


More information about the Intel-gfx mailing list