* [PATCH 0/2] Two fixes for ca0132
@ 2012-08-20 9:16 David Henningsson
2012-08-20 9:16 ` [PATCH 1/2] ALSA: hda - Fix "Line" and "Mic" names for CA0132 David Henningsson
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: David Henningsson @ 2012-08-20 9:16 UTC (permalink / raw)
To: tiwai, alsa-devel, ian_minett; +Cc: David Henningsson
I came across the following codec:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1038651/+attachment/3267820/+files/Card0.Codecs.codec.0.txt
...and the codec wouldn't load due to mixer errors. I don't know more about the codec than the codec proc shows,
and looking at that file it seems a bit broken, but maybe Ian would be able to make it work, with the help of
some secret verbs? At least now the codec would load correctly, so that the output side could be used.
David Henningsson (2):
ALSA: hda - Fix "Line" and "Mic" names for CA0132
ALSA: hda - don't create dysfunctional mixer controls for ca0132
sound/pci/hda/patch_ca0132.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
--
1.7.9.5
^ permalink raw reply [flat|nested] 7+ messages in thread* [PATCH 1/2] ALSA: hda - Fix "Line" and "Mic" names for CA0132 2012-08-20 9:16 [PATCH 0/2] Two fixes for ca0132 David Henningsson @ 2012-08-20 9:16 ` David Henningsson 2012-08-20 9:17 ` [PATCH 2/2] ALSA: hda - don't create dysfunctional mixer controls for ca0132 David Henningsson 2012-08-20 9:22 ` [PATCH 0/2] Two fixes " Takashi Iwai 2 siblings, 0 replies; 7+ messages in thread From: David Henningsson @ 2012-08-20 9:16 UTC (permalink / raw) To: tiwai, alsa-devel, ian_minett; +Cc: David Henningsson The names "Line-In" and "Mic-In" are nonstandard. Standard names make them controllable by e g PulseAudio. Signed-off-by: David Henningsson <david.henningsson@canonical.com> --- sound/pci/hda/patch_ca0132.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/pci/hda/patch_ca0132.c b/sound/pci/hda/patch_ca0132.c index d0d3540..2685590 100644 --- a/sound/pci/hda/patch_ca0132.c +++ b/sound/pci/hda/patch_ca0132.c @@ -988,12 +988,12 @@ static void ca0132_config(struct hda_codec *codec) /* Mic-in */ spec->input_pins[0] = 0x12; - spec->input_labels[0] = "Mic-In"; + spec->input_labels[0] = "Mic"; spec->adcs[0] = 0x07; /* Line-In */ spec->input_pins[1] = 0x11; - spec->input_labels[1] = "Line-In"; + spec->input_labels[1] = "Line"; spec->adcs[1] = 0x08; spec->num_inputs = 2; } -- 1.7.9.5 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 2/2] ALSA: hda - don't create dysfunctional mixer controls for ca0132 2012-08-20 9:16 [PATCH 0/2] Two fixes for ca0132 David Henningsson 2012-08-20 9:16 ` [PATCH 1/2] ALSA: hda - Fix "Line" and "Mic" names for CA0132 David Henningsson @ 2012-08-20 9:17 ` David Henningsson 2012-08-20 9:22 ` [PATCH 0/2] Two fixes " Takashi Iwai 2 siblings, 0 replies; 7+ messages in thread From: David Henningsson @ 2012-08-20 9:17 UTC (permalink / raw) To: tiwai, alsa-devel, ian_minett; +Cc: stable, David Henningsson It's possible that these amps are settable somehow, e g through secret codec verbs, but for now, don't create the controls (as they won't be working anyway, and cause errors in amixer). Cc: stable@kernel.org BugLink: https://bugs.launchpad.net/bugs/1038651 Signed-off-by: David Henningsson <david.henningsson@canonical.com> --- sound/pci/hda/patch_ca0132.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sound/pci/hda/patch_ca0132.c b/sound/pci/hda/patch_ca0132.c index 2685590..bf061a3 100644 --- a/sound/pci/hda/patch_ca0132.c +++ b/sound/pci/hda/patch_ca0132.c @@ -275,6 +275,10 @@ static int _add_switch(struct hda_codec *codec, hda_nid_t nid, const char *pfx, int type = dir ? HDA_INPUT : HDA_OUTPUT; struct snd_kcontrol_new knew = HDA_CODEC_MUTE_MONO(namestr, nid, chan, 0, type); + if ((query_amp_caps(codec, nid, type) & AC_AMPCAP_MUTE) == 0) { + snd_printdd("Skipping '%s %s Switch' (no mute on node 0x%x)\n", pfx, dirstr[dir], nid); + return 0; + } sprintf(namestr, "%s %s Switch", pfx, dirstr[dir]); return snd_hda_ctl_add(codec, nid, snd_ctl_new1(&knew, codec)); } @@ -286,6 +290,10 @@ static int _add_volume(struct hda_codec *codec, hda_nid_t nid, const char *pfx, int type = dir ? HDA_INPUT : HDA_OUTPUT; struct snd_kcontrol_new knew = HDA_CODEC_VOLUME_MONO(namestr, nid, chan, 0, type); + if ((query_amp_caps(codec, nid, type) & AC_AMPCAP_NUM_STEPS) == 0) { + snd_printdd("Skipping '%s %s Volume' (no amp on node 0x%x)\n", pfx, dirstr[dir], nid); + return 0; + } sprintf(namestr, "%s %s Volume", pfx, dirstr[dir]); return snd_hda_ctl_add(codec, nid, snd_ctl_new1(&knew, codec)); } -- 1.7.9.5 ^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH 0/2] Two fixes for ca0132 2012-08-20 9:16 [PATCH 0/2] Two fixes for ca0132 David Henningsson 2012-08-20 9:16 ` [PATCH 1/2] ALSA: hda - Fix "Line" and "Mic" names for CA0132 David Henningsson 2012-08-20 9:17 ` [PATCH 2/2] ALSA: hda - don't create dysfunctional mixer controls for ca0132 David Henningsson @ 2012-08-20 9:22 ` Takashi Iwai 2012-08-20 9:24 ` Takashi Iwai 2012-08-20 9:27 ` David Henningsson 2 siblings, 2 replies; 7+ messages in thread From: Takashi Iwai @ 2012-08-20 9:22 UTC (permalink / raw) To: David Henningsson; +Cc: alsa-devel, ian_minett At Mon, 20 Aug 2012 11:16:58 +0200, David Henningsson wrote: > > I came across the following codec: > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1038651/+attachment/3267820/+files/Card0.Codecs.codec.0.txt > > ...and the codec wouldn't load due to mixer errors. I don't know more about the codec than the codec proc shows, > and looking at that file it seems a bit broken, but maybe Ian would be able to make it work, with the help of > some secret verbs? At least now the codec would load correctly, so that the output side could be used. Both fixes already have existed in my local queue for weeks and provided to some people who reported CA0132 problems (including Ian). Basically they are for fixing the missing SPDIF controls. But they were pending because of the upcoming DSP loading stuff, which seem to be pretty delayed. So I'm going to apply the fixes for 3.6 kernel. thanks, Takashi > > David Henningsson (2): > ALSA: hda - Fix "Line" and "Mic" names for CA0132 > ALSA: hda - don't create dysfunctional mixer controls for ca0132 > > sound/pci/hda/patch_ca0132.c | 12 ++++++++++-- > 1 file changed, 10 insertions(+), 2 deletions(-) > > -- > 1.7.9.5 > ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 0/2] Two fixes for ca0132 2012-08-20 9:22 ` [PATCH 0/2] Two fixes " Takashi Iwai @ 2012-08-20 9:24 ` Takashi Iwai 2012-08-20 9:27 ` David Henningsson 1 sibling, 0 replies; 7+ messages in thread From: Takashi Iwai @ 2012-08-20 9:24 UTC (permalink / raw) To: David Henningsson; +Cc: alsa-devel, ian_minett At Mon, 20 Aug 2012 11:22:45 +0200, Takashi Iwai wrote: > > At Mon, 20 Aug 2012 11:16:58 +0200, > David Henningsson wrote: > > > > I came across the following codec: > > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1038651/+attachment/3267820/+files/Card0.Codecs.codec.0.txt > > > > ...and the codec wouldn't load due to mixer errors. I don't know more about the codec than the codec proc shows, > > and looking at that file it seems a bit broken, but maybe Ian would be able to make it work, with the help of > > some secret verbs? At least now the codec would load correctly, so that the output side could be used. > > Both fixes already have existed in my local queue for weeks and > provided to some people who reported CA0132 problems (including Ian). > Basically they are for fixing the missing SPDIF controls. But they > were pending because of the upcoming DSP loading stuff, which seem to > be pretty delayed. > > So I'm going to apply the fixes for 3.6 kernel. FWIW, the patches are in topic/ca0132-fix branch of sound git tree (which should appear shortly later). Takashi ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 0/2] Two fixes for ca0132 2012-08-20 9:22 ` [PATCH 0/2] Two fixes " Takashi Iwai 2012-08-20 9:24 ` Takashi Iwai @ 2012-08-20 9:27 ` David Henningsson 2012-08-20 9:34 ` Takashi Iwai 1 sibling, 1 reply; 7+ messages in thread From: David Henningsson @ 2012-08-20 9:27 UTC (permalink / raw) To: Takashi Iwai; +Cc: alsa-devel, ian_minett On 08/20/2012 11:22 AM, Takashi Iwai wrote: > At Mon, 20 Aug 2012 11:16:58 +0200, > David Henningsson wrote: >> >> I came across the following codec: >> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1038651/+attachment/3267820/+files/Card0.Codecs.codec.0.txt >> >> ...and the codec wouldn't load due to mixer errors. I don't know more about the codec than the codec proc shows, >> and looking at that file it seems a bit broken, but maybe Ian would be able to make it work, with the help of >> some secret verbs? At least now the codec would load correctly, so that the output side could be used. > > Both fixes already have existed in my local queue for weeks and > provided to some people who reported CA0132 problems (including Ian). > Basically they are for fixing the missing SPDIF controls. In my case, it was about input (mic and mic boost). > But they > were pending because of the upcoming DSP loading stuff, which seem to > be pretty delayed. > > So I'm going to apply the fixes for 3.6 kernel. At least the latter one (don't create dysfunctional...) should go to stable, too. > > > thanks, > > Takashi > >> >> David Henningsson (2): >> ALSA: hda - Fix "Line" and "Mic" names for CA0132 >> ALSA: hda - don't create dysfunctional mixer controls for ca0132 >> >> sound/pci/hda/patch_ca0132.c | 12 ++++++++++-- >> 1 file changed, 10 insertions(+), 2 deletions(-) >> >> -- >> 1.7.9.5 >> > -- David Henningsson, Canonical Ltd. https://launchpad.net/~diwic ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 0/2] Two fixes for ca0132 2012-08-20 9:27 ` David Henningsson @ 2012-08-20 9:34 ` Takashi Iwai 0 siblings, 0 replies; 7+ messages in thread From: Takashi Iwai @ 2012-08-20 9:34 UTC (permalink / raw) To: David Henningsson; +Cc: alsa-devel, ian_minett At Mon, 20 Aug 2012 11:27:08 +0200, David Henningsson wrote: > > On 08/20/2012 11:22 AM, Takashi Iwai wrote: > > At Mon, 20 Aug 2012 11:16:58 +0200, > > David Henningsson wrote: > >> > >> I came across the following codec: > >> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1038651/+attachment/3267820/+files/Card0.Codecs.codec.0.txt > >> > >> ...and the codec wouldn't load due to mixer errors. I don't know more about the codec than the codec proc shows, > >> and looking at that file it seems a bit broken, but maybe Ian would be able to make it work, with the help of > >> some secret verbs? At least now the codec would load correctly, so that the output side could be used. > > > > Both fixes already have existed in my local queue for weeks and > > provided to some people who reported CA0132 problems (including Ian). > > Basically they are for fixing the missing SPDIF controls. > > In my case, it was about input (mic and mic boost). > > > But they > > were pending because of the upcoming DSP loading stuff, which seem to > > be pretty delayed. > > > > So I'm going to apply the fixes for 3.6 kernel. > > At least the latter one (don't create dysfunctional...) should go to > stable, too. Right. I applied that one now. thanks, Takashi ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2012-08-20 9:04 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2012-08-20 9:16 [PATCH 0/2] Two fixes for ca0132 David Henningsson 2012-08-20 9:16 ` [PATCH 1/2] ALSA: hda - Fix "Line" and "Mic" names for CA0132 David Henningsson 2012-08-20 9:17 ` [PATCH 2/2] ALSA: hda - don't create dysfunctional mixer controls for ca0132 David Henningsson 2012-08-20 9:22 ` [PATCH 0/2] Two fixes " Takashi Iwai 2012-08-20 9:24 ` Takashi Iwai 2012-08-20 9:27 ` David Henningsson 2012-08-20 9:34 ` Takashi Iwai
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).