Re: [v4] drm/i915/pps: improve eDP power on flow

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 14 Nov 2022, Lee Shawn C <shawn.c.lee@xxxxxxxxx> wrote:
> After i915 dirver initialized, a panel power off cycle delay
> always append before turn eDP on. If eDP display did not
> power on before. With this change, power off duration might
> longer than power cycle delay. So driver can save power cycle
> delay to speed up driver initialization time.
>
> v2: fix commit messages
> v3: refine panel_power_off_time default value and modify
>     commit messages
> v4: add eDP power off cycle delay at the path to unload i915 module
>
> Cc: Shankar Uma <uma.shankar@xxxxxxxxx>
> Cc: Jani Nikula <jani.nikula@xxxxxxxxxxxxxxx>
> Cc: Ville Syrjälä <ville.syrjala@xxxxxxxxxxxxxxx>
> Signed-off-by: Lee Shawn C <shawn.c.lee@xxxxxxxxx>
> ---
>  drivers/gpu/drm/i915/display/intel_pps.c | 2 +-
>  drivers/gpu/drm/i915/i915_driver.c       | 4 ++++
>  2 files changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_pps.c b/drivers/gpu/drm/i915/display/intel_pps.c
> index 81ee7f3aadf6..ab4118b38120 100644
> --- a/drivers/gpu/drm/i915/display/intel_pps.c
> +++ b/drivers/gpu/drm/i915/display/intel_pps.c
> @@ -1100,7 +1100,7 @@ bool intel_pps_have_panel_power_or_vdd(struct intel_dp *intel_dp)
>  
>  static void pps_init_timestamps(struct intel_dp *intel_dp)
>  {
> -	intel_dp->pps.panel_power_off_time = ktime_get_boottime();
> +	intel_dp->pps.panel_power_off_time = 0;
>  	intel_dp->pps.last_power_on = jiffies;
>  	intel_dp->pps.last_backlight_off = jiffies;
>  }
> diff --git a/drivers/gpu/drm/i915/i915_driver.c b/drivers/gpu/drm/i915/i915_driver.c
> index c3d43f9b1e45..0e3cbd129055 100644
> --- a/drivers/gpu/drm/i915/i915_driver.c
> +++ b/drivers/gpu/drm/i915/i915_driver.c
> @@ -107,6 +107,8 @@ static const char irst_name[] = "INT3392";
>  
>  static const struct drm_driver i915_drm_driver;
>  
> +static void intel_shutdown_encoders(struct drm_i915_private *dev_priv);
> +
>  static void i915_release_bridge_dev(struct drm_device *dev,
>  				    void *bridge)
>  {
> @@ -796,6 +798,8 @@ static void i915_driver_unregister(struct drm_i915_private *dev_priv)
>  
>  	intel_display_driver_unregister(dev_priv);
>  
> +	intel_shutdown_encoders(dev_priv);
> +

Per Ville's comments on IRC, this is still too early. See [1] for
another approach.

BR,
Jani.


[1] https://patchwork.freedesktop.org/patch/msgid/20221116150657.1347504-1-jani.nikula@xxxxxxxxx


>  	for_each_gt(gt, dev_priv, i)
>  		intel_gt_driver_unregister(gt);

-- 
Jani Nikula, Intel Open Source Graphics Center




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux