Add support for the AK5365 ADC. Signed-off-by: Jochen Voss <voss@xxxxxxxxxx> diff -ur alsa-driver-1.0.12rc2.orig/alsa-kernel/i2c/other/ak4xxx-adda.c alsa-driver-1.0.12rc2/alsa-kernel/i2c/other/ak4xxx-adda.c --- alsa-driver-1.0.12rc2.orig/alsa-kernel/i2c/other/ak4xxx-adda.c 2006-08-04 13:41:21.000000000 +0100 +++ alsa-driver-1.0.12rc2/alsa-kernel/i2c/other/ak4xxx-adda.c 2006-08-08 19:44:20.000000000 +0100 @@ -598,6 +598,31 @@ if (err < 0) goto __error; } + + if (ak->type == SND_AK5365) { + memset(ctl, 0, sizeof(*ctl)); + if (ak->channel_names == NULL) + strcpy(ctl->id.name, "Capture Volume"); + else + strcpy(ctl->id.name, ak->channel_names[0]); + ctl->id.index = ak->idx_offset * 2; + ctl->id.iface = SNDRV_CTL_ELEM_IFACE_MIXER; + ctl->count = 1; + ctl->info = snd_akm4xxx_stereo_volume_info; + ctl->get = snd_akm4xxx_stereo_volume_get; + ctl->put = snd_akm4xxx_stereo_volume_put; + /* Registers 4 & 5 (see AK5365 data sheet, pages 34 and 35): + * valid values are from 0x00 (mute) to 0x98 (+12dB). */ + ctl->private_value = + AK_COMPOSE(0, 4, 0, 0x98); + ctl->private_data = ak; + err = snd_ctl_add(ak->card, + snd_ctl_new(ctl, SNDRV_CTL_ELEM_ACCESS_READ| + SNDRV_CTL_ELEM_ACCESS_WRITE)); + if (err < 0) + goto __error; + } + if (ak->type == SND_AK4355 || ak->type == SND_AK4358) num_emphs = 1; else diff -ur alsa-driver-1.0.12rc2.orig/alsa-kernel/include/ak4xxx-adda.h alsa-driver-1.0.12rc2/alsa-kernel/include/ak4xxx-adda.h --- alsa-driver-1.0.12rc2.orig/alsa-kernel/include/ak4xxx-adda.h 2006-08-04 13:41:21.000000000 +0100 +++ alsa-driver-1.0.12rc2/alsa-kernel/include/ak4xxx-adda.h 2006-08-08 19:45:15.000000000 +0100 @@ -53,7 +53,8 @@ unsigned int idx_offset; /* control index offset */ enum { SND_AK4524, SND_AK4528, SND_AK4529, - SND_AK4355, SND_AK4358, SND_AK4381 + SND_AK4355, SND_AK4358, SND_AK4381, + SND_AK5365 } type; unsigned int *num_stereo; /* array of combined counts * for the mixer
Attachment:
signature.asc
Description: Digital signature
------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.sourceforge.net/lists/listinfo/alsa-devel