summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Thomson <Adam.Thomson.Opensource@diasemi.com>2015-09-29 16:43:56 +0100
committerMark Brown <broonie@kernel.org>2015-09-30 19:22:48 +0100
commitc25c79b468a61ad8a54f764553056e2e2a427ea8 (patch)
treec3cd9dcaa14bbabcdca68c5f47d2df92cdf1c8b9
parent6ff33f3902c3b1c5d0db6b1e2c70b6d76fba357f (diff)
downloadop-kernel-dev-c25c79b468a61ad8a54f764553056e2e2a427ea8.zip
op-kernel-dev-c25c79b468a61ad8a54f764553056e2e2a427ea8.tar.gz
ASoC: Add SOC_DOUBLE_R_EXT
_EXT version of SOC_DOUBLE_R required to allow for custom handlers. Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com> Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r--include/sound/soc.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/sound/soc.h b/include/sound/soc.h
index 884e728..2d79cb5 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -217,6 +217,13 @@
.get = xhandler_get, .put = xhandler_put, \
.private_value = \
SOC_DOUBLE_VALUE(reg, shift_left, shift_right, max, invert, 0) }
+#define SOC_DOUBLE_R_EXT(xname, reg_left, reg_right, xshift, xmax, xinvert,\
+ xhandler_get, xhandler_put) \
+{ .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = (xname), \
+ .info = snd_soc_info_volsw, \
+ .get = xhandler_get, .put = xhandler_put, \
+ .private_value = SOC_DOUBLE_R_VALUE(reg_left, reg_right, xshift, \
+ xmax, xinvert) }
#define SOC_SINGLE_EXT_TLV(xname, xreg, xshift, xmax, xinvert,\
xhandler_get, xhandler_put, tlv_array) \
{ .iface = SNDRV_CTL_ELEM_IFACE_MIXER, .name = xname, \
OpenPOWER on IntegriCloud