aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/hda_codec.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2012-12-20 05:02:00 -0500
committerTakashi Iwai <tiwai@suse.de>2013-01-12 02:33:54 -0500
commitaa88a3553eebdcc3ce6801aabb4ed0223bfa198e (patch)
tree50581f0b8181b16d2243c03897ac14530c8b9569 /sound/pci/hda/hda_codec.c
parentde1e37b7d0dc3f1b8d0f84f5ff64ef8eebdf1e9f (diff)
ALSA: hda - Clear cached_write flag in snd_hda_codec_resume_*()
These functions are supposed to be called at finishing the cached sequential writes, so clear the flag properly for lazy developers who often forget details. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/hda_codec.c')
-rw-r--r--sound/pci/hda/hda_codec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 23c821428a43..3207e5c57141 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -1955,6 +1955,7 @@ void snd_hda_codec_resume_amp(struct hda_codec *codec)
1955 int i; 1955 int i;
1956 1956
1957 mutex_lock(&codec->hash_mutex); 1957 mutex_lock(&codec->hash_mutex);
1958 codec->cached_write = 0;
1958 for (i = 0; i < codec->amp_cache.buf.used; i++) { 1959 for (i = 0; i < codec->amp_cache.buf.used; i++) {
1959 struct hda_amp_info *buffer; 1960 struct hda_amp_info *buffer;
1960 u32 key; 1961 u32 key;
@@ -3520,6 +3521,7 @@ void snd_hda_codec_resume_cache(struct hda_codec *codec)
3520 int i; 3521 int i;
3521 3522
3522 mutex_lock(&codec->hash_mutex); 3523 mutex_lock(&codec->hash_mutex);
3524 codec->cached_write = 0;
3523 for (i = 0; i < codec->cmd_cache.buf.used; i++) { 3525 for (i = 0; i < codec->cmd_cache.buf.used; i++) {
3524 struct hda_cache_head *buffer; 3526 struct hda_cache_head *buffer;
3525 u32 key; 3527 u32 key;