diff mbox series

[v9,13/13] drm/i915: Add state readout for DRM infoframe

Message ID 1557340733-9629-14-git-send-email-uma.shankar@intel.com (mailing list archive)
State New, archived
Headers show
Series Add HDR Metadata Parsing and handling in DRM layer | expand

Commit Message

Shankar, Uma May 8, 2019, 6:38 p.m. UTC
Added state readout for DRM infoframe and enabled
state validation for DRM infoframe.

Signed-off-by: Uma Shankar <uma.shankar@intel.com>
---
 drivers/gpu/drm/i915/intel_ddi.c     | 4 ++++
 drivers/gpu/drm/i915/intel_display.c | 1 +
 drivers/gpu/drm/i915/intel_hdmi.c    | 4 ++++
 3 files changed, 9 insertions(+)

Comments

Ville Syrjälä May 13, 2019, 7:50 p.m. UTC | #1
On Thu, May 09, 2019 at 12:08:53AM +0530, Uma Shankar wrote:
> Added state readout for DRM infoframe and enabled
> state validation for DRM infoframe.
> 
> Signed-off-by: Uma Shankar <uma.shankar@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_ddi.c     | 4 ++++
>  drivers/gpu/drm/i915/intel_display.c | 1 +
>  drivers/gpu/drm/i915/intel_hdmi.c    | 4 ++++
>  3 files changed, 9 insertions(+)
> 
> diff --git a/drivers/gpu/drm/i915/intel_ddi.c b/drivers/gpu/drm/i915/intel_ddi.c
> index d37526b..3a38f32 100644
> --- a/drivers/gpu/drm/i915/intel_ddi.c
> +++ b/drivers/gpu/drm/i915/intel_ddi.c
> @@ -3849,6 +3849,10 @@ void intel_ddi_get_config(struct intel_encoder *encoder,
>  	intel_read_infoframe(encoder, pipe_config,
>  			     HDMI_INFOFRAME_TYPE_VENDOR,
>  			     &pipe_config->infoframes.hdmi);
> +	if ((INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv)))
> +		intel_read_infoframe(encoder, pipe_config,
> +				     HDMI_INFOFRAME_TYPE_DRM,
> +				     &pipe_config->infoframes.drm);
>  }
>  
>  static enum intel_output_type
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index a351c8e..74b5189 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -12231,6 +12231,7 @@ static bool fastboot_enabled(struct drm_i915_private *dev_priv)
>  	PIPE_CONF_CHECK_INFOFRAME(avi);
>  	PIPE_CONF_CHECK_INFOFRAME(spd);
>  	PIPE_CONF_CHECK_INFOFRAME(hdmi);
> +	PIPE_CONF_CHECK_INFOFRAME(drm);
>  
>  #undef PIPE_CONF_CHECK_X
>  #undef PIPE_CONF_CHECK_I
> diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c
> index 224d33e..3886065 100644
> --- a/drivers/gpu/drm/i915/intel_hdmi.c
> +++ b/drivers/gpu/drm/i915/intel_hdmi.c
> @@ -1867,6 +1867,10 @@ static void intel_hdmi_get_config(struct intel_encoder *encoder,
>  	intel_read_infoframe(encoder, pipe_config,
>  			     HDMI_INFOFRAME_TYPE_VENDOR,
>  			     &pipe_config->infoframes.hdmi);
> +	if ((INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv)))
> +		intel_read_infoframe(encoder, pipe_config,
> +				     HDMI_INFOFRAME_TYPE_DRM,
> +				     &pipe_config->infoframes.drm);

Dead code.

>  }
>  
>  static void intel_enable_hdmi_audio(struct intel_encoder *encoder,
> -- 
> 1.9.1
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/intel_ddi.c b/drivers/gpu/drm/i915/intel_ddi.c
index d37526b..3a38f32 100644
--- a/drivers/gpu/drm/i915/intel_ddi.c
+++ b/drivers/gpu/drm/i915/intel_ddi.c
@@ -3849,6 +3849,10 @@  void intel_ddi_get_config(struct intel_encoder *encoder,
 	intel_read_infoframe(encoder, pipe_config,
 			     HDMI_INFOFRAME_TYPE_VENDOR,
 			     &pipe_config->infoframes.hdmi);
+	if ((INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv)))
+		intel_read_infoframe(encoder, pipe_config,
+				     HDMI_INFOFRAME_TYPE_DRM,
+				     &pipe_config->infoframes.drm);
 }
 
 static enum intel_output_type
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index a351c8e..74b5189 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -12231,6 +12231,7 @@  static bool fastboot_enabled(struct drm_i915_private *dev_priv)
 	PIPE_CONF_CHECK_INFOFRAME(avi);
 	PIPE_CONF_CHECK_INFOFRAME(spd);
 	PIPE_CONF_CHECK_INFOFRAME(hdmi);
+	PIPE_CONF_CHECK_INFOFRAME(drm);
 
 #undef PIPE_CONF_CHECK_X
 #undef PIPE_CONF_CHECK_I
diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c
index 224d33e..3886065 100644
--- a/drivers/gpu/drm/i915/intel_hdmi.c
+++ b/drivers/gpu/drm/i915/intel_hdmi.c
@@ -1867,6 +1867,10 @@  static void intel_hdmi_get_config(struct intel_encoder *encoder,
 	intel_read_infoframe(encoder, pipe_config,
 			     HDMI_INFOFRAME_TYPE_VENDOR,
 			     &pipe_config->infoframes.hdmi);
+	if ((INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv)))
+		intel_read_infoframe(encoder, pipe_config,
+				     HDMI_INFOFRAME_TYPE_DRM,
+				     &pipe_config->infoframes.drm);
 }
 
 static void intel_enable_hdmi_audio(struct intel_encoder *encoder,