summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2022-10-26 20:01:43 +0300
committerVille Syrjälä <ville.syrjala@linux.intel.com>2022-10-27 20:19:19 +0300
commit6e22c35ddaa19dcaa57bf9bfb4ca747ee7ce98a6 (patch)
treeb50232308aa4c4ac212d5de32e00fe045e1f093e /drivers/gpu/drm
parent9f4a51256f439265f28d729a8866692337d58505 (diff)
drm/i915/audio: Nuke intel_eld_uptodate()
No idea why we do this ELD comparions on g4x before loading the new ELD. Seems entirely pointless so just get rid of it. Cc: Chaitanya Kumar Borah <chaitanya.kumar.borah@intel.com> Cc: Kai Vehmanen <kai.vehmanen@linux.intel.com> Cc: Takashi Iwai <tiwai@suse.de> Reviewed-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20221026170150.2654-9-ville.syrjala@linux.intel.com
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/i915/display/intel_audio.c33
1 files changed, 0 insertions, 33 deletions
diff --git a/drivers/gpu/drm/i915/display/intel_audio.c b/drivers/gpu/drm/i915/display/intel_audio.c
index 093283fd1c28..7867eb670560 100644
--- a/drivers/gpu/drm/i915/display/intel_audio.c
+++ b/drivers/gpu/drm/i915/display/intel_audio.c
@@ -304,33 +304,6 @@ static int audio_config_hdmi_get_n(const struct intel_crtc_state *crtc_state,
return 0;
}
-static bool intel_eld_uptodate(struct drm_connector *connector,
- i915_reg_t reg_eldv, u32 bits_eldv,
- i915_reg_t reg_elda, u32 bits_elda,
- i915_reg_t reg_edid)
-{
- struct drm_i915_private *i915 = to_i915(connector->dev);
- const u8 *eld = connector->eld;
- u32 tmp;
- int i;
-
- tmp = intel_de_read(i915, reg_eldv);
- tmp &= bits_eldv;
-
- if (!tmp)
- return false;
-
- tmp = intel_de_read(i915, reg_elda);
- tmp &= ~bits_elda;
- intel_de_write(i915, reg_elda, tmp);
-
- for (i = 0; i < drm_eld_size(eld) / 4; i++)
- if (intel_de_read(i915, reg_edid) != *((const u32 *)eld + i))
- return false;
-
- return true;
-}
-
static void g4x_audio_codec_disable(struct intel_encoder *encoder,
const struct intel_crtc_state *old_crtc_state,
const struct drm_connector_state *old_conn_state)
@@ -354,12 +327,6 @@ static void g4x_audio_codec_enable(struct intel_encoder *encoder,
u32 tmp;
int len, i;
- if (intel_eld_uptodate(connector,
- G4X_AUD_CNTL_ST, G4X_ELD_VALID,
- G4X_AUD_CNTL_ST, G4X_ELD_ADDRESS_MASK,
- G4X_HDMIW_HDMIEDID))
- return;
-
tmp = intel_de_read(i915, G4X_AUD_CNTL_ST);
tmp &= ~(G4X_ELD_VALID | G4X_ELD_ADDRESS_MASK);
len = REG_FIELD_GET(G4X_ELD_BUFFER_SIZE_MASK, tmp);