drm/i915: Enable DP audio for Haswell
Subsystems (2)
PATCH 1/1 drm/i915: Enable DP audio for Haswell
This patch adds the missing code to send ELD for Haswell DisplayPort, based on Xingchao's original patch.
A test was performed with HSW-D machine and NEC EA232Wmi DP monitor.
--- drivers/gpu/drm/i915/intel_ddi.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/gpu/drm/i915/intel_ddi.c +9 -0
@@ -669,6 +669,15 @@ static void intel_ddi_mode_set(struct drm_encoder *encoder,break ; } +if (intel_hdmi->has_audio) { +DRM_DEBUG_DRIVER ("DP audio on pipe %c on DDI\n" , +pipe_name (intel_crtc->pipe)); + +/* write eld */ +DRM_DEBUG_DRIVER ("DP audio: write eld information\n" ); +intel_write_eld (encoder, adjusted_mode); + } +intel_dp_init_link_config (intel_dp); }else if (type ==INTEL_OUTPUT_HDMI ) {
Signature · 1 line
1.8.0
Hi
drivers/gpu/drm/i915/intel_ddi.c: In function ‘intel_ddi_mode_set’:drivers/gpu/drm/i915/intel_ddi.c:672:7: error: ‘intel_hdmi’ undeclared (first use in this function) drivers/gpu/drm/i915/intel_ddi.c:672:7: note: each undeclared identifier is reported only once for each function it appears in make[4]: ** [drivers/gpu/drm/i915/intel_ddi.o] Erro 1
2012/11/16 Takashi Iwai <[email protected]>:
Quoted 16 lines
This patch adds the missing code to send ELD for Haswell DisplayPort, based on Xingchao's original patch.
A test was performed with HSW-D machine and NEC EA232Wmi DP monitor.
Cc Xingchao Wang <[email protected]>Signed-off-by Takashi Iwai <[email protected]>--- drivers/gpu/drm/i915/intel_ddi.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/gpu/drm/i915/intel_ddi.c +0
-0
drivers/gpu/drm/i915/intel_ddi.c static void intel_ddi_mode_set(struct drm_encoder *encoder, · line 672
Quoted 4 lines
drivers/gpu/drm/i915/intel_ddi.c +1
-0@@ -669,6 +669,15 @@ static void intel_ddi_mode_set(struct drm_encoder *encoder,break ; } +if (intel_hdmi->has_audio) {
Replacing it with intel_dp->has_audio makes it look correct.
You could also try to "unify" the 2 "has_audio" checks of this function into one single check at the end of the function.
Quoted 18 lines
drivers/gpu/drm/i915/intel_ddi.c +8
-1+DRM_DEBUG_DRIVER ("DP audio on pipe %c on DDI\n" , +pipe_name (intel_crtc->pipe)); + +/* write eld */ +DRM_DEBUG_DRIVER ("DP audio: write eld information\n" ); +intel_write_eld (encoder, adjusted_mode); + } +intel_dp_init_link_config (intel_dp); }else if (type ==INTEL_OUTPUT_HDMI ) { --1.8.0
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 1 line
Paulo Zanoni
At Mon, 19 Nov 2012 15:01:59 -0200,
Quoted 9 lines · Paulo Zanoni
Hi
drivers/gpu/drm/i915/intel_ddi.c: In function ‘intel_ddi_mode_set’:drivers/gpu/drm/i915/intel_ddi.c:672:7: error: ‘intel_hdmi’ undeclared (first use in this function)drivers/gpu/drm/i915/intel_ddi.c:672:7: note: each undeclared identifier is reported only once for each function it appears in make[4]: ** [drivers/gpu/drm/i915/intel_ddi.o] Erro 1
Doh, sorry, I posted a version before refreshing.
Will submit the right one soon.
Quoted 20 lines
2012/11/16 Takashi Iwai <[email protected]>:
Quoted 19 lines
This patch adds the missing code to send ELD for Haswell DisplayPort, based on Xingchao's original patch.
A test was performed with HSW-D machine and NEC EA232Wmi DP monitor.
Cc Xingchao Wang <[email protected]>Signed-off-by Takashi Iwai <[email protected]>--- drivers/gpu/drm/i915/intel_ddi.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/gpu/drm/i915/intel_ddi.c +0
-0@@ -669,6 +669,15 @@ static void intel_ddi_mode_set(struct drm_encoder *encoder,break ; }
Quoted 6 lines
drivers/gpu/drm/i915/intel_ddi.c static void intel_ddi_mode_set(struct drm_encoder *encoder, · line 672
Quoted 1 line
drivers/gpu/drm/i915/intel_ddi.c +1
-0+if (intel_hdmi->has_audio) {Replacing it with
intel_dp->has_audiomakes it look correct.You could also try to "unify" the 2 "
has_audio" checks of this function into one single check at the end of the function.
Yes. A more refactoring is possible, but I left it as is from the safety side.
thanks,
Takashi
Quoted 10 lines
Quoted 10 lines
drivers/gpu/drm/i915/intel_ddi.c +8
-0+DRM_DEBUG_DRIVER ("DP audio on pipe %c on DDI\n" , +pipe_name (intel_crtc->pipe)); + +/* write eld */ +DRM_DEBUG_DRIVER ("DP audio: write eld information\n" ); +intel_write_eld (encoder, adjusted_mode); + } +intel_dp_init_link_config (intel_dp);
Quoted 14 lines
Quoted 8 lines
drivers/gpu/drm/i915/intel_ddi.c +0
-1}else if (type ==INTEL_OUTPUT_HDMI ) { --1.8.0
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfxSignature · 1 line
Paulo Zanoni
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx