diff options
author | Mark Brown <broonie@kernel.org> | 2019-08-20 20:28:43 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-08-20 20:28:43 +0300 |
commit | dd28d54c248fa37794dfa3d23a24ff99a1d3b6ac (patch) | |
tree | 066b7a24eb08527f47da41ac3fd3621d073a24d6 /sound/soc/sof/intel/hda.c | |
parent | d5e120422db8808e1c8b1507900ca393a877c58f (diff) | |
parent | bf283a05c09b58db83afbb1a8a3c6a684c56c1bb (diff) | |
download | linux-dd28d54c248fa37794dfa3d23a24ff99a1d3b6ac.tar.xz |
Merge branch 'asoc-5.3' into asoc-5.4
Diffstat (limited to 'sound/soc/sof/intel/hda.c')
-rw-r--r-- | sound/soc/sof/intel/hda.c | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/sound/soc/sof/intel/hda.c b/sound/soc/sof/intel/hda.c index c97c004afa43..c72e9a09eee1 100644 --- a/sound/soc/sof/intel/hda.c +++ b/sound/soc/sof/intel/hda.c @@ -357,10 +357,23 @@ static int hda_init_caps(struct snd_sof_dev *sdev) if (bus->ppcap) dev_dbg(sdev->dev, "PP capability, will probe DSP later.\n"); +#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA) + /* init i915 and HDMI codecs */ + ret = hda_codec_i915_init(sdev); + if (ret < 0) { + dev_err(sdev->dev, "error: init i915 and HDMI codec failed\n"); + return ret; + } +#endif + + /* Init HDA controller after i915 init */ ret = hda_dsp_ctrl_init_chip(sdev, true); if (ret < 0) { dev_err(bus->dev, "error: init chip failed with ret: %d\n", ret); +#if IS_ENABLED(CONFIG_SND_SOC_SOF_HDA) + hda_codec_i915_exit(sdev); +#endif return ret; } @@ -368,13 +381,6 @@ static int hda_init_caps(struct snd_sof_dev *sdev) if (bus->mlcap) snd_hdac_ext_bus_get_ml_capabilities(bus); - /* init i915 and HDMI codecs */ - ret = hda_codec_i915_init(sdev); - if (ret < 0) { - dev_err(sdev->dev, "error: no HDMI audio devices found\n"); - return ret; - } - /* codec detection */ if (!bus->codec_mask) { dev_info(bus->dev, "no hda codecs found!\n"); |