[Intel-gfx] [PATCH] drm/i915: Enable runtime pm

Jesse Barnes jbarnes at virtuousgeek.org
Tue May 12 10:40:24 PDT 2015


On 05/08/2015 11:51 AM, Daniel Vetter wrote:
> Like with every other feature that's not enabled by default we break
> runtime pm support way too often by accident because the overall test
> coverage isn't great. And it's been almost 2 years since we enabled
> the power well code by default
> 
> commit bf51d5e2cda5d36d98e4b46ac7fca9461e512c41
> Author: Paulo Zanoni <paulo.r.zanoni at intel.com>
> Date:   Wed Jul 3 17:12:13 2013 -0300
> 
>     drm/i915: switch disable_power_well default value to 1
> 
> It's really more than overdue for runtime pm itself to follow!
> 
> Note that in practice this wont do a hole lot yet, since we're still
> gated on snd-hda-intel doing proper runtime pm. But I've discussed
> this with Liam and we agreed that this needs to be done. And the audio
> team is working to hold up their end of this bargain.
> 
> And the justification for updating the autosuspend delay to 100ms:
> Quick measurment shows that we can do a full rpm cycle in about 5ms,
> which means the delay should still be really conservative from a power
> conservation pov. The only workload that would suffer from ping-pong
> is also only gpu/compute with all screens off. 100ms should cover any
> kind of latency with submitting follow-up batches.
> 
> Cc: Takashi Iwai <tiwai at suse.de>
> Cc: Liam Girdwood <liam.r.girdwood at intel.com>
> Cc: Yang, Libin <libin.yang at intel.com>
> Cc: Lin, Mengdong <mengdong.lin at intel.com>
> Cc: Li, Jocelyn <jocelyn.li at intel.com>
> Cc: Kaskinen, Tanu <tanu.kaskinen at intel.com>
> Cc: Zanoni, Paulo R <paulo.r.zanoni at intel.com>
> Signed-off-by: Daniel Vetter <daniel.vetter at intel.com>
> ---
>  drivers/gpu/drm/i915/intel_runtime_pm.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_runtime_pm.c b/drivers/gpu/drm/i915/intel_runtime_pm.c
> index 317b9b43d1c1..36ecbe275dd9 100644
> --- a/drivers/gpu/drm/i915/intel_runtime_pm.c
> +++ b/drivers/gpu/drm/i915/intel_runtime_pm.c
> @@ -1919,9 +1919,10 @@ void intel_runtime_pm_enable(struct drm_i915_private *dev_priv)
>  		return;
>  	}
>  
> -	pm_runtime_set_autosuspend_delay(device, 10000); /* 10s */
> +	pm_runtime_set_autosuspend_delay(device, 100);
>  	pm_runtime_mark_last_busy(device);
>  	pm_runtime_use_autosuspend(device);
> +	pm_runtime_allow(device);
>  
>  	pm_runtime_put_autosuspend(device);
>  }
> 

This also changes the timeout...  it shouldn't break anything, but it
would be good to get some numbers from Eero's team on this.  It might be
better to use a lower or higher number based on a typical desktop
workload by default (though I guess the user or distro can do their own
tuning and override the value too).

Jesse


More information about the Intel-gfx mailing list