[Intel-gfx] [PATCH 3/6] drm/i915/display: Add intel_aux_ch_to_power_domain()
Imre Deak
imre.deak at intel.com
Wed Apr 1 12:09:13 UTC 2020
On Tue, Mar 31, 2020 at 05:41:17PM -0700, José Roberto de Souza wrote:
> This is a similar function to intel_aux_power_domain() but it do not
> care about TBT ports, this will be needed by GEN11 TC sequences.
>
> Cc: Imre Deak <imre.deak at intel.com>
> Cc: Cooper Chiou <cooper.chiou at intel.com>
> Cc: Kai-Heng Feng <kai.heng.feng at canonical.com>
> Signed-off-by: José Roberto de Souza <jose.souza at intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_display.c | 14 ++++++++++++--
> drivers/gpu/drm/i915/display/intel_display.h | 2 ++
> 2 files changed, 14 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> index e09a11b1e509..7e06d2306dcd 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.c
> +++ b/drivers/gpu/drm/i915/display/intel_display.c
> @@ -7278,7 +7278,17 @@ intel_aux_power_domain(struct intel_digital_port *dig_port)
> }
> }
>
> - switch (dig_port->aux_ch) {
> + return intel_aux_ch_to_power_domain(dig_port->aux_ch);
> +}
> +
> +/*
> + * Converts aux_ch to power_domain without caring about TBT ports for that use
> + * intel_aux_power_domain()
> + */
> +enum intel_display_power_domain
> +intel_aux_ch_to_power_domain(enum aux_ch aux_ch)
Maybe intel_legacy_aux_to_power_domain()?
> +{
> + switch (aux_ch) {
> case AUX_CH_A:
> return POWER_DOMAIN_AUX_A;
> case AUX_CH_B:
> @@ -7294,7 +7304,7 @@ intel_aux_power_domain(struct intel_digital_port *dig_port)
> case AUX_CH_G:
> return POWER_DOMAIN_AUX_G;
> default:
> - MISSING_CASE(dig_port->aux_ch);
> + MISSING_CASE(aux_ch);
> return POWER_DOMAIN_AUX_A;
> }
> }
> diff --git a/drivers/gpu/drm/i915/display/intel_display.h b/drivers/gpu/drm/i915/display/intel_display.h
> index adb1225a3480..ad50119c0453 100644
> --- a/drivers/gpu/drm/i915/display/intel_display.h
> +++ b/drivers/gpu/drm/i915/display/intel_display.h
> @@ -579,6 +579,8 @@ void hsw_disable_ips(const struct intel_crtc_state *crtc_state);
> enum intel_display_power_domain intel_port_to_power_domain(enum port port);
> enum intel_display_power_domain
> intel_aux_power_domain(struct intel_digital_port *dig_port);
> +enum intel_display_power_domain
> +intel_aux_ch_to_power_domain(enum aux_ch aux_ch);
> void intel_mode_from_pipe_config(struct drm_display_mode *mode,
> struct intel_crtc_state *pipe_config);
> void intel_crtc_arm_fifo_underrun(struct intel_crtc *crtc,
> --
> 2.26.0
>
More information about the Intel-gfx
mailing list