提交 7a5857c3 编写于 作者: S Sodhi, VunnyX 提交者: Mark Brown

ASoC: Intel: Skylake: Fix to turn off hdmi power on probe failure

HDMI codec is required to be powered up before controller initialization
for successful enumeration of codec. If the probe fails it needs to be
powered off to balance the power state of HDMI codec.

This fix balances the reference count in the error path before turning
off the codec.
Reported-by: NTakashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: NSodhi, VunnyX <vunnyx.sodhi@intel.com>
Signed-off-by: NSubhransu S. Prusty <subhransu.s.prusty@intel.com>
Signed-off-by: NMark Brown <broonie@kernel.org>
上级 6d13f62d
......@@ -674,7 +674,7 @@ static int skl_probe(struct pci_dev *pci,
if (skl->nhlt == NULL) {
err = -ENODEV;
goto out_free;
goto out_display_power_off;
}
skl_nhlt_update_topology_bin(skl);
......@@ -746,6 +746,9 @@ static int skl_probe(struct pci_dev *pci,
skl_machine_device_unregister(skl);
out_nhlt_free:
skl_nhlt_free(skl->nhlt);
out_display_power_off:
if (IS_ENABLED(CONFIG_SND_SOC_HDAC_HDMI))
snd_hdac_display_power(bus, false);
out_free:
skl->init_failed = 1;
skl_free(ebus);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册