• T
    ALSA: hda - Re-setup HDMI pin and audio infoframe on stream switches · b054087d
    Takashi Iwai 提交于
    When the transcoder:port mapping on Haswell HDMI/DP audio is changed
    during the stream playback, the sound gets lost.  Typically this
    problem is seen when the user switches the graphics mode from eDP+DP
    to DP-only configuration, where CRTC 1 is used for DP in the former
    while CRTC 0 is used for the latter.
    
    The graphics controller notifies the change via the normal ELD update
    procedure, so we get the intrinsic event.  For enabling the sound
    again, the HDMI audio driver needs to reset the pin and set up the
    audio infoframe again.
    
    This patch achieves it by:
    - keep the current status of channels and info frame setup in per_pin
      struct,
    - check the reconnection in the intrinsic event handler,
    - reset the pin and the re-invoke hdmi_setup_audio_infoframe()
      accordingly.
    
    The hdmi_setup_audio_infoframe() function has been changed, too, so
    that it can be invoked without passing the substream instance.
    
    The patch is mostly based on the work by Mengdong Lin.
    
    Cc: Mengdong Lin <mengdong.lin@intel.com>
    Cc: <stable@vger.kernel.org>
    Signed-off-by: NTakashi Iwai <tiwai@suse.de>
    b054087d
patch_hdmi.c 76.5 KB