diff mbox series

[v3] drm/i915/hdmi: SPD infoframe update for discrete

Message ID 20221027221315.2762940-1-clinton.a.taylor@intel.com (mailing list archive)
State New, archived
Headers show
Series [v3] drm/i915/hdmi: SPD infoframe update for discrete | expand

Commit Message

Clint Taylor Oct. 27, 2022, 10:13 p.m. UTC
Replace internal with discrete of dgfx platforms.

v2: commit title reword (Jani)
v3: use variable name i915 (Jani)
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Signed-off-by: Taylor, Clinton A <clinton.a.taylor@intel.com>
---
 drivers/gpu/drm/i915/display/intel_hdmi.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

Comments

Matt Roper Nov. 19, 2022, 12:05 a.m. UTC | #1
On Thu, Oct 27, 2022 at 03:13:15PM -0700, Taylor, Clinton A wrote:
> Replace internal with discrete of dgfx platforms.

I think you meant 'integrated' rather than 'internal' here?

Is there any value in trying to give a rough family name in the product
description for discrete platforms?  E.g.,

  IS_DG2  -> "Arc GPU"
  IS_DG1  -> "Iris Xe Discrete GPU"
  IS_DGFX -> "Discrete GPU"  (general fallback)
  other   -> "Integrated gfx"

Not sure if it's really worth the effort to keep updating this as new
product families come out or not.  Either way,

Reviewed-by: Matt Roper <matthew.d.roper@intel.com>

> 
> v2: commit title reword (Jani)
> v3: use variable name i915 (Jani)
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Signed-off-by: Taylor, Clinton A <clinton.a.taylor@intel.com>
> ---
>  drivers/gpu/drm/i915/display/intel_hdmi.c | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c b/drivers/gpu/drm/i915/display/intel_hdmi.c
> index 02f8374ea51f..7c5133871897 100644
> --- a/drivers/gpu/drm/i915/display/intel_hdmi.c
> +++ b/drivers/gpu/drm/i915/display/intel_hdmi.c
> @@ -766,6 +766,7 @@ intel_hdmi_compute_spd_infoframe(struct intel_encoder *encoder,
>  				 struct intel_crtc_state *crtc_state,
>  				 struct drm_connector_state *conn_state)
>  {
> +	struct drm_i915_private *i915 = to_i915(encoder->base.dev);
>  	struct hdmi_spd_infoframe *frame = &crtc_state->infoframes.spd.spd;
>  	int ret;
>  
> @@ -775,7 +776,10 @@ intel_hdmi_compute_spd_infoframe(struct intel_encoder *encoder,
>  	crtc_state->infoframes.enable |=
>  		intel_hdmi_infoframe_enable(HDMI_INFOFRAME_TYPE_SPD);
>  
> -	ret = hdmi_spd_infoframe_init(frame, "Intel", "Integrated gfx");
> +	if (IS_DGFX(i915))
> +		ret = hdmi_spd_infoframe_init(frame, "Intel", "Discrete gfx");
> +	else
> +		ret = hdmi_spd_infoframe_init(frame, "Intel", "Integrated gfx");
>  	if (drm_WARN_ON(encoder->base.dev, ret))
>  		return false;
>  
> -- 
> 2.25.1
>
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/display/intel_hdmi.c b/drivers/gpu/drm/i915/display/intel_hdmi.c
index 02f8374ea51f..7c5133871897 100644
--- a/drivers/gpu/drm/i915/display/intel_hdmi.c
+++ b/drivers/gpu/drm/i915/display/intel_hdmi.c
@@ -766,6 +766,7 @@  intel_hdmi_compute_spd_infoframe(struct intel_encoder *encoder,
 				 struct intel_crtc_state *crtc_state,
 				 struct drm_connector_state *conn_state)
 {
+	struct drm_i915_private *i915 = to_i915(encoder->base.dev);
 	struct hdmi_spd_infoframe *frame = &crtc_state->infoframes.spd.spd;
 	int ret;
 
@@ -775,7 +776,10 @@  intel_hdmi_compute_spd_infoframe(struct intel_encoder *encoder,
 	crtc_state->infoframes.enable |=
 		intel_hdmi_infoframe_enable(HDMI_INFOFRAME_TYPE_SPD);
 
-	ret = hdmi_spd_infoframe_init(frame, "Intel", "Integrated gfx");
+	if (IS_DGFX(i915))
+		ret = hdmi_spd_infoframe_init(frame, "Intel", "Discrete gfx");
+	else
+		ret = hdmi_spd_infoframe_init(frame, "Intel", "Integrated gfx");
 	if (drm_WARN_ON(encoder->base.dev, ret))
 		return false;