ALSA: hda - Fix yet remaining issue with vmaster 0dB initialization
authorTakashi Iwai <tiwai@suse.de>
Wed, 22 Nov 2017 11:34:56 +0000 (12:34 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 30 Nov 2017 08:40:49 +0000 (08:40 +0000)
commit665000d9507ac332b7dede78fb3f5dd7b6f77177
tree17c53cf15e536bcb9daf8392c982598895ce0016
parent2ee1a8cf61714a960f7286d07890499553ea28e0
ALSA: hda - Fix yet remaining issue with vmaster 0dB initialization

commit d6c0615f510bc1ee26cfb2b9a3343ac99b9c46fb upstream.

The previous fix for addressing the breakage in vmaster slave
initialization, commit a91d66129fb9 ("ALSA: hda - Fix incorrect TLV
callback check introduced during set_fs() removal"), introduced a new
helper to process over each slave kctl.  However, this helper passes
only the original kctl, not the virtual slave kctl.  As a result,
HD-audio driver (which is the only user so far) couldn't initialize
the slave correctly because it's trying to update the value directly
with the original kctl, not with the mapped kctl.

This patch fixes the situation again by passing both the mapped slaved
and original slave kctls to the function.  Luckily there is a single
caller as of now, so changing the call signature is no big matter.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=197959
Fixes: a91d66129fb9 ("ALSA: hda - Fix incorrect TLV callback check introduced during set_fs() removal")
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
include/sound/control.h
sound/core/vmaster.c
sound/pci/hda/hda_codec.c