[alsa-devel] New code for conexant chipsets in -mm tree
Hi.
I have a HDA NVidia, with a Conexant chipset CX20549 Venice (CXT5045)
I tried to test the last alsa-kernel in -mm tree to support my mic. (2.6.21-rc4-mm1 and 2.6.21-rc5-mm2)
When I try to load the hda-intel, I receive this message:
Mar 27 11:29:08 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode Mar 27 11:29:09 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode
After loaded, the speakers doesn't work. Headphone works ok. Mic too.
Look in code, I apply this comment and now the speakers works for me:
--- patch_conexant.c.orig 2007-03-27 11:37:43.000000000 -0300 +++ patch_conexant.c 2007-03-27 11:38:02.000000000 -0300 @@ -822,7 +822,7 @@ case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2; - spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; +// spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; break;
But, I don't understand why, because this code is not executed for my chipset.
Thanks,
Rodrigo Luiz
What system do you have? Can you post the output from this script: http://bulletproof.servebeer.com/alsa/scripts/alsa-info.sh
I'm working on that driver, and am interested in knowing what I need to add to fix it.
Tobin
On Tue, 2007-03-27 at 12:17 -0300, Rodrigo Luiz wrote:
Hi.
I have a HDA NVidia, with a Conexant chipset CX20549 Venice (CXT5045)
I tried to test the last alsa-kernel in -mm tree to support my mic. (2.6.21-rc4-mm1 and 2.6.21-rc5-mm2)
When I try to load the hda-intel, I receive this message:
Mar 27 11:29:08 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode Mar 27 11:29:09 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode
After loaded, the speakers doesn't work. Headphone works ok. Mic too.
Look in code, I apply this comment and now the speakers works for me:
--- patch_conexant.c.orig 2007-03-27 11:37:43.000000000 -0300 +++ patch_conexant.c 2007-03-27 11:38:02.000000000 -0300 @@ -822,7 +822,7 @@ case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2;
spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;
+// spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; break;
But, I don't understand why, because this code is not executed for my chipset.
Thanks,
Rodrigo Luiz _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
Hi Tobin,
I'm using a x86-64 arch with a SMP support.
More details in the link of output from my alsa-info.sh using the original patch_conexant.c
Rodrigo.
Tobin Davis wrote:
What system do you have? Can you post the output from this script: http://bulletproof.servebeer.com/alsa/scripts/alsa-info.sh
I'm working on that driver, and am interested in knowing what I need to add to fix it.
Tobin
On Tue, 2007-03-27 at 12:17 -0300, Rodrigo Luiz wrote:
Hi.
I have a HDA NVidia, with a Conexant chipset CX20549 Venice (CXT5045)
I tried to test the last alsa-kernel in -mm tree to support my mic. (2.6.21-rc4-mm1 and 2.6.21-rc5-mm2)
When I try to load the hda-intel, I receive this message:
Mar 27 11:29:08 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode Mar 27 11:29:09 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode
After loaded, the speakers doesn't work. Headphone works ok. Mic too.
Look in code, I apply this comment and now the speakers works for me:
--- patch_conexant.c.orig 2007-03-27 11:37:43.000000000 -0300 +++ patch_conexant.c 2007-03-27 11:38:02.000000000 -0300 @@ -822,7 +822,7 @@ case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2;
spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;
+// spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; break;
But, I don't understand why, because this code is not executed for my chipset.
Thanks,
Rodrigo Luiz _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org mailto:Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
-- Tobin Davis <tdavis@dsl-only.net mailto:tdavis@dsl-only.net>
I'm not entirely sure that the code you have is the latest. Could you compare your patch_conexant.c with this one: http://members.dsl-only.net/~tdavis/patch_conexant.c
This is my latest version (it's also in the alsa hg tree).
Tobin
On Tue, 2007-03-27 at 13:48 -0300, Rodrigo Luiz wrote:
Hi Tobin,
I'm using a x86-64 arch with a SMP support.
More details in the link of output from my alsa-info.sh using the original patch_conexant.c
Rodrigo.
Tobin Davis wrote:
What system do you have? Can you post the output from this script: http://bulletproof.servebeer.com/alsa/scripts/alsa-info.sh
I'm working on that driver, and am interested in knowing what I need to add to fix it.
Tobin
On Tue, 2007-03-27 at 12:17 -0300, Rodrigo Luiz wrote:
Hi.
I have a HDA NVidia, with a Conexant chipset CX20549 Venice (CXT5045)
I tried to test the last alsa-kernel in -mm tree to support my mic. (2.6.21-rc4-mm1 and 2.6.21-rc5-mm2)
When I try to load the hda-intel, I receive this message:
Mar 27 11:29:08 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode Mar 27 11:29:09 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode
After loaded, the speakers doesn't work. Headphone works ok. Mic too.
Look in code, I apply this comment and now the speakers works for me:
--- patch_conexant.c.orig 2007-03-27 11:37:43.000000000 -0300 +++ patch_conexant.c 2007-03-27 11:38:02.000000000 -0300 @@ -822,7 +822,7 @@ case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2;
spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;
+// spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; break;
But, I don't understand why, because this code is not executed for my chipset.
Thanks,
Rodrigo Luiz _______________________________________________ Alsa-devel mailing list Alsa-devel@alsa-project.org mailto:Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
-- Tobin Davis <tdavis@dsl-only.net mailto:tdavis@dsl-only.net>
Alsa-devel mailing list Alsa-devel@alsa-project.org http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
This file in your home page is more recent in that -mm tree.
However, the changes is just for cxt5047 chipsets.
But I tried to load the hda-intel with the last one patch_conexant.c and I have the same issue.
Rodrigo.
The diff:
--- sound/pci/hda/patch_conexant.c 2007-03-27 13:21:30.000000000 -0300 +++ patch_conexant.c 2007-03-27 14:10:08.000000000 -0300 @@ -978,22 +978,10 @@ HDA_CODEC_MUTE("PCM Switch", 0x10, 0x00, HDA_OUTPUT), HDA_CODEC_VOLUME("PCM-2 Volume", 0x1c, 0x00, HDA_OUTPUT), HDA_CODEC_MUTE("PCM-2 Switch", 0x1c, 0x00, HDA_OUTPUT), - { - .iface = SNDRV_CTL_ELEM_IFACE_MIXER, - .name = "Master Playback Volume", - .info = snd_hda_mixer_amp_volume_info, - .get = snd_hda_mixer_amp_volume_get, - .put = cxt5047_hp_master_vol_put, - .private_value = HDA_COMPOSE_AMP_VAL(0x13, 3, 0, HDA_OUTPUT), - }, - { - .iface = SNDRV_CTL_ELEM_IFACE_MIXER, - .name = "Master Playback Switch", - .info = cxt_eapd_info, - .get = cxt_eapd_get, - .put = cxt5047_hp_master_sw_put, - .private_value = 0x13, - }, + HDA_CODEC_VOLUME("Speaker Volume", 0x1d, 0x00, HDA_OUTPUT), + HDA_CODEC_MUTE("Speaker Switch", 0x1d, 0x00, HDA_OUTPUT), + HDA_CODEC_VOLUME("Headphone Volume", 0x13, 0x00, HDA_OUTPUT), + HDA_CODEC_MUTE("Headphone Switch", 0x13, 0x00, HDA_OUTPUT),
{} };
Tobin Davis wrote:
I'm not entirely sure that the code you have is the latest. Could you compare your patch_conexant.c with this one: http://members.dsl-only.net/~tdavis/patch_conexant.c
This is my latest version (it's also in the alsa hg tree).
Tobin
The other thing to check is that you are not specifying a "model=" parameter in the modprobe.conf file. The module should be allowed to autodetect your system. Your previous comment about commenting out the "spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;" line indicates that your system is using the "model=fujitsu" option for some reason.
The diff below was actually a test for a user, and is not intended to be added to the main driver, sorry.
Tobin
On Tue, 2007-03-27 at 14:33 -0300, Rodrigo Luiz wrote:
This file in your home page is more recent in that -mm tree.
However, the changes is just for cxt5047 chipsets.
But I tried to load the hda-intel with the last one patch_conexant.c and I have the same issue.
Rodrigo.
The diff:
--- sound/pci/hda/patch_conexant.c 2007-03-27 13:21:30.000000000 -0300 +++ patch_conexant.c 2007-03-27 14:10:08.000000000 -0300 @@ -978,22 +978,10 @@ HDA_CODEC_MUTE("PCM Switch", 0x10, 0x00, HDA_OUTPUT), HDA_CODEC_VOLUME("PCM-2 Volume", 0x1c, 0x00, HDA_OUTPUT), HDA_CODEC_MUTE("PCM-2 Switch", 0x1c, 0x00, HDA_OUTPUT),
{
.iface = SNDRV_CTL_ELEM_IFACE_MIXER,
.name = "Master Playback Volume",
.info = snd_hda_mixer_amp_volume_info,
.get = snd_hda_mixer_amp_volume_get,
.put = cxt5047_hp_master_vol_put,
.private_value = HDA_COMPOSE_AMP_VAL(0x13, 3, 0,
HDA_OUTPUT),
},
{
.iface = SNDRV_CTL_ELEM_IFACE_MIXER,
.name = "Master Playback Switch",
.info = cxt_eapd_info,
.get = cxt_eapd_get,
.put = cxt5047_hp_master_sw_put,
.private_value = 0x13,
},
HDA_CODEC_VOLUME("Speaker Volume", 0x1d, 0x00, HDA_OUTPUT),
HDA_CODEC_MUTE("Speaker Switch", 0x1d, 0x00, HDA_OUTPUT),
HDA_CODEC_VOLUME("Headphone Volume", 0x13, 0x00, HDA_OUTPUT),
HDA_CODEC_MUTE("Headphone Switch", 0x13, 0x00, HDA_OUTPUT), {}
};
Tobin Davis wrote:
I'm not entirely sure that the code you have is the latest. Could you compare your patch_conexant.c with this one: http://members.dsl-only.net/~tdavis/patch_conexant.c
This is my latest version (it's also in the alsa hg tree).
Tobin
Tobin Davis wrote:
The other thing to check is that you are not specifying a "model=" parameter in the modprobe.conf file. The module should be allowed to autodetect your system. Your previous comment about commenting out the "spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;" line indicates that your system is using the "model=fujitsu" option for some reason.
My modprobe.conf is empty and I dont' give any paramter for this module.
But I also am not understanding. My test code:
switch (board_config) { case CXT5045_LAPTOP: codec->patch_ops.unsol_event = cxt5045_hp_unsol_event; spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2; spec->init_verbs[1] = cxt5045_hp_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; printk(KERN_DEBUG"cxt5045_laptop\n"); //for test break; case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2; // spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; printk(KERN_DEBUG"cxt5045_fujitsu\n"); //for test break;
And I see in log:
Mar 27 15:36:48 dig kernel: cxt5045_laptop
But if I uncomment the line "spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;", my speaker don't work and I receive these messages in log too.
Mar 27 15:44:59 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode... Mar 27 15:45:00 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode...
It's very strange. The case CXT5045_FUJITSU isn't executed, but it is influencing in the module. It is truth. :/
The diff below was actually a test for a user, and is not intended to be added to the main driver, sorry.
Ok. I only showed the diff between your patch_conexant and of the mm tree.
Rodrigo.
At Tue, 27 Mar 2007 15:50:09 -0300, Rodrigo Luiz wrote:
Tobin Davis wrote:
The other thing to check is that you are not specifying a "model=" parameter in the modprobe.conf file. The module should be allowed to autodetect your system. Your previous comment about commenting out the "spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;" line indicates that your system is using the "model=fujitsu" option for some reason.
My modprobe.conf is empty and I dont' give any paramter for this module.
But I also am not understanding. My test code:
switch (board_config) { case CXT5045_LAPTOP: codec->patch_ops.unsol_event = cxt5045_hp_unsol_event; spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2; spec->init_verbs[1] = cxt5045_hp_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; printk(KERN_DEBUG"cxt5045_laptop\n"); //for test break; case CXT5045_FUJITSU: spec->input_mux = &cxt5045_capture_source; spec->num_init_verbs = 2;
// spec->init_verbs[1] = cxt5045_mic_sense_init_verbs; spec->mixers[0] = cxt5045_mixers; codec->patch_ops.init = cxt5045_init; printk(KERN_DEBUG"cxt5045_fujitsu\n"); //for test break;
And I see in log:
Mar 27 15:36:48 dig kernel: cxt5045_laptop
But if I uncomment the line "spec->init_verbs[1] = cxt5045_mic_sense_init_verbs;", my speaker don't work and I receive these messages in log too.
Mar 27 15:44:59 dig kernel: hda_intel: azx_get_response timeout, switching to polling mode... Mar 27 15:45:00 dig kernel: hda_intel: azx_get_response timeout, switching to single_cmd mode...
It's very strange. The case CXT5045_FUJITSU isn't executed, but it is influencing in the module. It is truth. :/
It must be a coincidence. The compiler optimization stripped out the verbs because no one is referring. Try the patch below.
Takashi
diff -r 92288445bcd3 pci/hda/patch_conexant.c --- a/pci/hda/patch_conexant.c Wed Mar 28 13:42:25 2007 +0200 +++ b/pci/hda/patch_conexant.c Wed Mar 28 15:06:52 2007 +0200 @@ -632,11 +632,13 @@ static struct hda_verb cxt5045_hp_sense_ static struct hda_verb cxt5045_hp_sense_init_verbs[] = { /* pin sensing on HP jack */ {0x11, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | CONEXANT_HP_EVENT}, + { } /* end */ };
static struct hda_verb cxt5045_mic_sense_init_verbs[] = { /* pin sensing on HP jack */ {0x12, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | CONEXANT_MIC_EVENT}, + { } /* end */ };
#ifdef CONFIG_SND_DEBUG
Takashi Iwai wrote:
At Tue, 27 Mar 2007 15:50:09 -0300,
It must be a coincidence. The compiler optimization stripped out the verbs because no one is referring. Try the patch below.
Thanks Takashi.
This patch works! It was really a issue of gcc optimization.
My version is:
Reading specs from /usr/lib64/gcc/x86_64-slackware-linux/3.4.6/specs Configured with: ../gcc-3.4.6/configure --prefix=/usr --disable-multilib --libdir=/usr/lib64 --enable-shared --enable-threads=posix --enable-__cxa_atexit --disable-checking --with-gnu-ld --verbose --target=x86_64-slackware-linux --host=x86_64-slackware-linux --build=x86_64-slackware-linux Thread model: posix gcc version 3.4.6
Rodrigo.
participants (3)
-
Rodrigo Luiz
-
Takashi Iwai
-
Tobin Davis