summaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/patch_hdmi.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2015-02-25 15:18:50 +0100
committerTakashi Iwai <tiwai@suse.de>2015-03-23 13:19:39 +0100
commiteeecd9d10d3da0b9efd6f58fad55c4355dcc246a (patch)
tree8a664234ab300d8275d9d1acc604f52b5c7d0270 /sound/pci/hda/patch_hdmi.c
parent9ba17b4d132f56a680fa1ba0bc2a8f98b6263d93 (diff)
downloadtalos-obmc-linux-eeecd9d10d3da0b9efd6f58fad55c4355dcc246a.tar.gz
talos-obmc-linux-eeecd9d10d3da0b9efd6f58fad55c4355dcc246a.zip
ALSA: hda - Use regmap for amp accesses
This patch converts the amp access functions to the regmap helpers. The amp values were formerly cached in the own hash table. Now it's dropped by the regmap's cache. The only tricky conversion is snd_hda_codec_amp_init(). This function shouldn't do anything if the amp was already initialized. For achieving this behavior, a value is read once at first temporarily in the cache-only mode. Only if it returns an error, i.e. the item still doesn't exist in the cache, it proceeds to the update. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_hdmi.c')
-rw-r--r--sound/pci/hda/patch_hdmi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
index 35d92a8a99ce..04c5ab20eb76 100644
--- a/sound/pci/hda/patch_hdmi.c
+++ b/sound/pci/hda/patch_hdmi.c
@@ -2211,7 +2211,7 @@ static int generic_hdmi_resume(struct hda_codec *codec)
int pin_idx;
codec->patch_ops.init(codec);
- snd_hda_codec_resume_amp(codec);
+ regcache_sync(codec->core.regmap);
snd_hda_codec_resume_cache(codec);
for (pin_idx = 0; pin_idx < spec->num_pins; pin_idx++) {
OpenPOWER on IntegriCloud