• Takashi Iwai's avatar
    ASoC: intel: skl: Fix display power regression · 687ae9e2
    Takashi Iwai authored
    Since the refactoring of HD-audio display power management, the
    display power status is managed per domain.  Meanwhile the ASoC
    hdac_hdmi driver still keeps and relies (incorrectly) on the
    refcounting together with ASoC skl driver, and this leads to the
    display state always on.
    
    This patch is an attempt to address the regression by simplifying the
    PM code of ASoC skl and hdac_hdmi drivers.  Basically, since the
    refactoring, we don't have to manage the display power at HD-audio
    controller suspend / resume but only at HD-audio HDMI codec suspend /
    resume.  So the patch drops the superfluous snd_hdac_display_power()
    calls in skl driver.
    
    Meanwhile, in hdac_hdmi side, we rewrite the PM call just to re-use
    the runtime PM callbacks like other drivers do.  Now the logic is
    simple: turn off at suspend and turn on at resume.
    
    The patch also fixes the possibly missing display-power off at skl
    driver removal as well as some error paths at probe.
    
    Fixes: 029d92c2 ("ALSA: hda: Refactor display power management")
    Reported-by: default avatarLibin Yang <libin.yang@intel.com>
    Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
    687ae9e2
hdac_hdmi.c 55.6 KB