[alsa-devel] Regression post-ALSA 1.0.22 for Lenovo G555 Internal mic

Roo - Andrew Baines andrewmbaines at gmail.com
Tue May 24 12:57:16 CEST 2011


I tried the patch but for some reason it fails, am i using patch wrong? When
I try and open it in Kompare it says its not a valid diff file.

shark alsa-kernel # patch -p2 </home/roo/alsa-patch
patching file pci/hda/patch_conexant.c
Hunk #1 FAILED at 3484.
Hunk #2 FAILED at 3508.
Hunk #3 FAILED at 3519.
Hunk #4 FAILED at 3703.
Hunk #5 FAILED at 3757.
5 out of 5 hunks FAILED -- saving rejects to file
pci/hda/patch_conexant.c.rej

New alsa-info.sh output is attached also.

When I ran arecord with pasuspender I got an error 'D is not a valid option'
so I killed pulse and did arecord. What I got was a 0.00 second long
recording even if i specified --duration=10.

There are no alsa records in /var/log/messages at all when I grep for ALSA,
alsa, conexant, snd, sound.

Thanks
Andrew



On 24 May 2011 10:38, Takashi Iwai <tiwai at suse.de> wrote:

> At Mon, 23 May 2011 23:24:48 +0100,
> Roo - Andrew Baines wrote:
> >
> > With the latest snapshot, the mic does not work still.
>
> Hrm OK, could you give alsa-info.sh output again?
>
> > What has also changed from the previous snapshot provided is that when
> the
> > headphones are plugged in, no sound comes through the headphones, but
> still
> > through the speakers - before it came through both.
>
> Weird, there is no change regarding this since the last time.
> It looks like something is unstable with jack-sensing.
>
> > I have attached a verbose pulse log of about 15 seconds when i plugged in
> > and unplugged my headphones - I couldnt work out how to do an ALSA one.
>
> Don't use PulseAudio for the primary testing.  Use alsa-native, e.g.
> "arecord -Dplughw -vv foo.wav".  You can avoid PA by wrapping with
> pasuspender.
>
>        % pasuspender arecord -Dplughw -vv foo.wav
>
> Also, try the patch below on alsa-driver/alsa-kernel directory with
> patch -p2 option.  This will give a few debug prints.  See "XXX ..."
> kernel messages at initialization and upon plugging/unplugging HP/mic
> jacks.
>
>
> thanks,
>
> Takashi
>
> ---
> diff --git a/sound/pci/hda/patch_conexant.c
> b/sound/pci/hda/patch_conexant.c
> index e8dc736..1095bbb 100644
> --- a/sound/pci/hda/patch_conexant.c
> +++ b/sound/pci/hda/patch_conexant.c
> @@ -3484,11 +3484,16 @@ static void cx_auto_update_speakers(struct
> hda_codec *codec)
>        struct auto_pin_cfg *cfg = &spec->autocfg;
>        int on;
>
> +       printk("XXX cx_auto_update_speakers: auto_mute=%d, hp_present=%d,
> line_present=%d\n", spec->auto_mute, spec->hp_present, spec->line_present);
>        if (!spec->auto_mute)
> -               on = 0;
> +               on = 1;
>        else
> -               on = spec->hp_present | spec->line_present;
> +               on = spec->hp_present;
>        cx_auto_turn_eapd(codec, cfg->hp_outs, cfg->hp_pins, on);
> +       if (!spec->auto_mute)
> +               on = 0;
> +       else
> +               on |= spec->detect_line && spec->line_present;
>        do_automute(codec, cfg->speaker_outs, cfg->speaker_pins, !on);
>
>        /* toggle line-out mutes if needed, too */
> @@ -3508,6 +3513,7 @@ static void cx_auto_hp_automute(struct hda_codec
> *codec)
>        struct conexant_spec *spec = codec->spec;
>        struct auto_pin_cfg *cfg = &spec->autocfg;
>
> +       printk("XXX cx_auto_hp_automute\n");
>        if (!spec->auto_mute)
>                return;
>        spec->hp_present = detect_jacks(codec, cfg->hp_outs, cfg->hp_pins);
> @@ -3519,6 +3525,7 @@ static void cx_auto_line_automute(struct hda_codec
> *codec)
>        struct conexant_spec *spec = codec->spec;
>        struct auto_pin_cfg *cfg = &spec->autocfg;
>
> +       printk("XXX cx_auto_line_automute\n");
>        if (!spec->auto_mute || !spec->detect_line)
>                return;
>        spec->line_present = detect_jacks(codec, cfg->line_outs,
> @@ -3703,6 +3710,8 @@ static int cx_auto_mux_enum_update(struct hda_codec
> *codec,
>                return 0;
>        if (idx >= imux->num_items)
>                idx = imux->num_items - 1;
> +       printk("XXX cx_auto_mux_enum_update idx=%d, adc=%x, pin=%x\n",
> +              idx, spec->imux_info[idx].adc, spec->imux_info[idx].pin);
>        if (spec->cur_mux[0] == idx)
>                changed = 0;
>        adc = spec->imux_info[idx].adc;
> @@ -3757,6 +3766,7 @@ static void cx_auto_automic(struct hda_codec *codec)
>  {
>        struct conexant_spec *spec = codec->spec;
>
> +       printk("XXX cx_auto_automic\n");
>        if (!spec->auto_mic)
>                return;
>        if (!select_automic(codec, spec->auto_mic_ext, true))
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: alsa-info.txt.PgGTmgfAEl
Type: application/octet-stream
Size: 14680 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20110524/3105abe1/attachment.dll 


More information about the Alsa-devel mailing list