Re: [PATCH 4/8] drm/i915/pmu: Suspend sampling when GPU is idle

Chris Wilson
2017-09-25T17:39:55Z

Quoting Tvrtko Ursulin (2017-09-25 16:15:39)
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
>
> If only a subset of events is enabled we can afford to suspend
> the sampling timer when the GPU is idle and so save some cycles
> and power.
>
> v2: Rebase and limit timer even more.
> v3: Rebase.
> v4: Rebase.
> v5: Skip action if perf PMU failed to register.
> v6: Checkpatch cleanup.
> v7:
> * Add a common helper to start the timer if needed. (Chris Wilson)
> * Add comment explaining bitwise logic in pmu_needs_timer.
> v8: Fix some comments styles. (Chris Wilson)
>
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

You may have gone a little overboard on the comments; a little too far
into i++ /* post-increment i*/ ;)

Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris