summaryrefslogtreecommitdiffstats
path: root/sound/soc/codecs/hdac_hda.c
diff options
context:
space:
mode:
authorKai Vehmanen <kai.vehmanen@linux.intel.com>2020-09-30 14:41:40 +0300
committerTakashi Iwai <tiwai@suse.de>2020-09-30 16:53:23 +0200
commit7a2ba46f3693ec8fbd508c4e693692e85ac14ed6 (patch)
tree014cfd08a6f6f96567a2b98061cf39e7e39b4e6e /sound/soc/codecs/hdac_hda.c
parenta0645daf16101bb9a6d87598c17e9a8b7bd60ea7 (diff)
downloadlinux-7a2ba46f3693ec8fbd508c4e693692e85ac14ed6.tar.bz2
ASoC: hdac_hda: allow runtime pm at end of probe
Align with recent change to forbid runtime suspend during codec init in snd_hda_codec_device_new(), with matching call to allow suspend at end of hdac_hda_codec_probe(). In snd-hda-intel, call to snd_hda_set_power_save() at end of controller probe does the same thing, but ASoC controller drivers do not modify runtime settings for codecs, so this has to be done in codec drivers, and in this case in hdac_hda. Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com> Acked-by: Mark Brown <broonie@kernel.org> Link: https://lore.kernel.org/r/20200930114140.3839617-3-kai.vehmanen@linux.intel.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/soc/codecs/hdac_hda.c')
-rw-r--r--sound/soc/codecs/hdac_hda.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/soc/codecs/hdac_hda.c b/sound/soc/codecs/hdac_hda.c
index 49e6f23fc766..390dd6c7f6a5 100644
--- a/sound/soc/codecs/hdac_hda.c
+++ b/sound/soc/codecs/hdac_hda.c
@@ -481,6 +481,9 @@ static int hdac_hda_codec_probe(struct snd_soc_component *component)
snd_hdac_display_power(hdev->bus,
HDA_CODEC_IDX_CONTROLLER, false);
+ /* match for forbid call in snd_hda_codec_device_new() */
+ pm_runtime_allow(&hdev->dev);
+
/*
* hdac_device core already sets the state to active and calls
* get_noresume. So enable runtime and set the device to suspend.