diff options
author | Jaroslav Kysela <perex@suse.cz> | 2006-06-01 18:34:01 +0200 |
---|---|---|
committer | Jaroslav Kysela <perex@suse.cz> | 2006-09-23 10:36:42 +0200 |
commit | 42750b04c5baa7c5ffdf0a8be2b9b320efdf069f (patch) | |
tree | 52aea8f1eeb44405b67bc5b381cce6bc20e2bff6 /sound/pci/ca0106 | |
parent | 3eeab61aa3ddd3c0bedb7449ada1599de22fdb5a (diff) | |
download | op-kernel-dev-42750b04c5baa7c5ffdf0a8be2b9b320efdf069f.zip op-kernel-dev-42750b04c5baa7c5ffdf0a8be2b9b320efdf069f.tar.gz |
[ALSA] Control API - TLV implementation for additional information like dB scale
This patch implements a TLV mechanism to transfer an additional information
like dB scale to the user space. The types might be extended in future.
Acked-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/ca0106')
-rw-r--r-- | sound/pci/ca0106/ca0106_mixer.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/pci/ca0106/ca0106_mixer.c b/sound/pci/ca0106/ca0106_mixer.c index 146eed70d..35309b3 100644 --- a/sound/pci/ca0106/ca0106_mixer.c +++ b/sound/pci/ca0106/ca0106_mixer.c @@ -70,9 +70,12 @@ #include <sound/pcm.h> #include <sound/ac97_codec.h> #include <sound/info.h> +#include <sound/tlv.h> #include "ca0106.h" +static DECLARE_TLV_DB_SCALE(snd_ca0106_db_scale, -5150, 75, 1); + static int snd_ca0106_shared_spdif_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo) { @@ -472,6 +475,7 @@ static int snd_ca0106_i2c_volume_put(struct snd_kcontrol *kcontrol, .info = snd_ca0106_volume_info, \ .get = snd_ca0106_volume_get, \ .put = snd_ca0106_volume_put, \ + .tlv = snd_ca0106_db_scale, \ .private_value = ((chid) << 8) | (reg) \ } |