ASoC: wm9712/wm9713: Replace virtual registers with custom put/get callbacks
authorLars-Peter Clausen <lars@metafoo.de>
Mon, 3 Nov 2014 18:33:03 +0000 (19:33 +0100)
committerMark Brown <broonie@kernel.org>
Sat, 8 Nov 2014 09:44:36 +0000 (09:44 +0000)
commitcf1f2ebe8d6176de80ef9d9c979f998ec38fb265
tree83c19ea088ca0eca54b20dfb4fef3e42f445a6e6
parent65ba65f200b6f24b9a0638e3636ad6647259a26d
ASoC: wm9712/wm9713: Replace virtual registers with custom put/get callbacks

The wm9712/wm9713 has separate mixers for the left and the right channel,
but the inputs to the mixers are enabled/disabled by the same control.
Currently this is implemented by the driver by registering two virtual
controls for each physical control, one for the left mixer and one for the
right mixer.

Using virtual registers will no longer work when the driver has
been converted to regmap. This patch converts the driver to use controls
with custom put/get callbacks instead which implement the logic making sure
that the physical control is unmuted when either the left or the right
control is unmuted.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/wm9712.c
sound/soc/codecs/wm9713.c