[Intel-gfx] [PATCH 3/3] drm/i915: Move dev_priv->pm_i{m, e}r into intel_gt

Chris Wilson chris at chris-wilson.co.uk
Tue Jul 2 10:32:03 UTC 2019


Quoting Tvrtko Ursulin (2019-07-02 11:23:13)
> From: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
> 
> PM interrupts belong to the GT so move the variables to be inside
> struct intel_gt.

I even had gt_pm patches kicking around :-p
Which are in desperate need of revival. :-(

> Co-authored-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
> Signed-off-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio at intel.com>
> Cc: Andi Shyti <andi.shyti at intel.com>

Reviewed-by: Chris Wilson <chris at chris-wilson.co.uk>
> ---
>  drivers/gpu/drm/i915/gt/intel_gt_types.h   |   3 +
>  drivers/gpu/drm/i915/gt/intel_ringbuffer.c |   4 +-
>  drivers/gpu/drm/i915/i915_drv.h            |   2 -
>  drivers/gpu/drm/i915/i915_irq.c            | 121 +++++++++++----------
>  drivers/gpu/drm/i915/i915_irq.h            |   4 +-
>  5 files changed, 71 insertions(+), 63 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gt/intel_gt_types.h b/drivers/gpu/drm/i915/gt/intel_gt_types.h
> index c03e56628ee2..37da428bef62 100644
> --- a/drivers/gpu/drm/i915/gt/intel_gt_types.h
> +++ b/drivers/gpu/drm/i915/gt/intel_gt_types.h
> @@ -55,6 +55,9 @@ struct intel_gt {
>         ktime_t last_init_time;
>  
>         struct i915_vma *scratch;
> +
> +       u32 pm_imr;
> +       u32 pm_ier;

Fwiw, I do intend to bring back gt_pm and move all the rps/ips tracking
underneath it and extract it from i915_irq.c & intel_pm.c into gt/

We have a long standing bugs in race conditions between the pm
interrupts and the rps worker, plus overdue work to let userspace make
fine grained suggestions for frequency/power control.
-Chris


More information about the Intel-gfx mailing list