[Librem-5-dev] [PATCH 08/12] imx-hdp: Comment out hdr setting code

Guido Günther agx at sigxcpu.org
Mon Oct 29 04:47:50 PDT 2018


Signed-off-by: Guido Günther <guido.gunther at puri.sm>
---
 drivers/gpu/drm/imx/hdp/imx-hdmi.c |  4 ++++
 drivers/gpu/drm/imx/hdp/imx-hdp.c  | 10 ++++++++--
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/imx/hdp/imx-hdmi.c b/drivers/gpu/drm/imx/hdp/imx-hdmi.c
index ef0f3e430772..6422a96e3e57 100644
--- a/drivers/gpu/drm/imx/hdp/imx-hdmi.c
+++ b/drivers/gpu/drm/imx/hdp/imx-hdmi.c
@@ -269,6 +269,7 @@ int hdmi_get_hpd_state(state_struct *state, u8 *hpd)
 int hdmi_write_hdr_metadata(state_struct *state,
 			    union hdmi_infoframe *hdr_infoframe)
 {
+#if 0
 	struct imx_hdp *hdp = container_of(state, struct imx_hdp, state);
 	u8 buffer[40];
 	int infoframe_size;
@@ -287,4 +288,7 @@ int hdmi_write_hdr_metadata(state_struct *state,
 	return CDN_API_InfoframeSet(state, 1, infoframe_size,
 				    (u32 *)buffer,
 				    HDMI_INFOFRAME_TYPE_DRM);
+#endif
+	return 0;
 }
+
diff --git a/drivers/gpu/drm/imx/hdp/imx-hdp.c b/drivers/gpu/drm/imx/hdp/imx-hdp.c
index f8aa7cc0bd15..b0fc4b4acee1 100644
--- a/drivers/gpu/drm/imx/hdp/imx-hdp.c
+++ b/drivers/gpu/drm/imx/hdp/imx-hdp.c
@@ -684,6 +684,7 @@ static void imx_hdp_imx_encoder_disable(struct drm_encoder *encoder)
 
 static void imx_hdp_imx_encoder_enable(struct drm_encoder *encoder)
 {
+#if 0
 	struct imx_hdp *hdp = container_of(encoder, struct imx_hdp, encoder);
 	union hdmi_infoframe frame;
 	struct hdr_static_metadata *hdr_metadata;
@@ -717,6 +718,7 @@ static void imx_hdp_imx_encoder_enable(struct drm_encoder *encoder)
 	}
 
 	hdp->ops->write_hdr_metadata(&hdp->state, &frame);
+#endif
 }
 
 static int imx_hdp_imx_encoder_atomic_check(struct drm_encoder *encoder,
@@ -724,15 +726,18 @@ static int imx_hdp_imx_encoder_atomic_check(struct drm_encoder *encoder,
 				    struct drm_connector_state *conn_state)
 {
 	struct imx_crtc_state *imx_crtc_state = to_imx_crtc_state(crtc_state);
-	struct imx_hdp *hdp = container_of(encoder, struct imx_hdp, encoder);
 
 	imx_crtc_state->bus_format = MEDIA_BUS_FMT_RGB101010_1X30;
 
+#if 0
+	struct imx_hdp *hdp = container_of(encoder, struct imx_hdp, encoder);
+
 	if (conn_state->hdr_metadata_changed &&
 	    conn_state->hdr_source_metadata_blob_ptr &&
 	    conn_state->hdr_source_metadata_blob_ptr->length)
 		hdp->hdr_metadata_present = true;
 
+#endif
 	return 0;
 }
 
@@ -911,7 +916,6 @@ static struct hdp_ops imx8mq_ops = {
 	.mode_set = hdmi_mode_set_t28hpc,
 	.get_edid_block = hdmi_get_edid_block,
 	.get_hpd_state = hdmi_get_hpd_state,
-	.write_hdr_metadata = hdmi_write_hdr_metadata,
 };
 
 static struct hdp_devtype imx8mq_hdmi_devtype = {
@@ -1109,8 +1113,10 @@ static int imx_hdp_imx_bind(struct device *dev, struct device *master,
 			   &imx_hdp_connector_funcs,
 			   DRM_MODE_CONNECTOR_HDMIA);
 
+#if 0
 	drm_object_attach_property(&connector->base,
 		connector->dev->mode_config.hdr_source_metadata_property, 0);
+#endif
 
 	drm_mode_connector_attach_encoder(connector, encoder);
 
-- 
2.19.0



More information about the Librem-5-dev mailing list