Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Massimo Del Fedele <max@veneto.com>
To: alsa-devel@alsa-project.org
Subject: Re: Fix for Asus G75 notebook subwoofer
Date: Wed, 07 Nov 2012 16:51:01 +0100	[thread overview]
Message-ID: <509A8365.7060001@veneto.com> (raw)
In-Reply-To: <s5h390l7chn.wl%tiwai@suse.de>

Il 07/11/2012 14:45, Takashi Iwai ha scritto:
> At Wed, 07 Nov 2012 14:37:33 +0100,
> Massimo Del Fedele wrote:
>>
>>
>> Il 07/11/2012 09:56, Takashi Iwai ha scritto:
>>> At Tue, 06 Nov 2012 18:23:51 +0100,
>>> Massimo Del Fedele wrote:
>>>>
>>>> Il 06/11/2012 15:24, Takashi Iwai ha scritto:
>>>>> At Tue, 06 Nov 2012 15:18:58 +0100,
>>>>> Massimo Del Fedele wrote:
>>>>>> Il 06/11/2012 10:06, Takashi Iwai ha scritto:
>>>>>>
>>>>>>> Could you attach to ML too?
>>>>>> I tried, but they're too big
>>>>> Did you compress it?
>>>> No, but I'm doing now... in compressed file are both info
>>> Could you post also alsa-info.sh output before applying your patch,
>>> too?
>>>
>>>>>>>> BTW, did you see the above patch (error in via_auto_fill_dac_nids) ?
>>>>>>>> My patch isn't correct either (fails when the 'continue' path is taken)
>>>>>>>> but it's better than now. I guess that code should be rewritten, it's
>>>>>>>> quite weird in respect to dac numbering.
>>>>>>> Could you elaborate a bit more?
>>>>>>>
>>>>>> Ok. here the original functions :
>>>>> Hmm... could you give a "diff -up" output instead?
>>>> Ok... here is te diff (with whole asus patch). I cleaned up the part of via_auto_fill_dac_nids,
>>>> it should be correct now in all parts, even for skipped nids.
>>> Actually the only place to be fixed is the assignment of
>>> spec->private_dac_nids[].  spec->out_path[] should correspond to
>>> cfg->line_out_pins[].  That is, the patch below should suffice (in
>>> addition to pin default changes and connection overrides for VT1802).
>>>
>>>
>>> thanks,
>>>
>>> Takashi
>>>
>>> ---
>>> diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c
>>> index 72a2f60..1c1367b 100644
>>> --- a/sound/pci/hda/patch_via.c
>>> +++ b/sound/pci/hda/patch_via.c
>>> @@ -1825,7 +1825,7 @@ static int via_auto_fill_dac_nids(struct hda_codec *codec)
>>>    					    &spec->out_mix_path))
>>>    			dac = spec->out_mix_path.path[0];
>>>    		if (dac) {
>>> -			spec->private_dac_nids[i] = dac;
>>> +			spec->private_dac_nids[dac_num] = dac;
>>>    			dac_num++;
>>>    		}
>>>    	}
>>>
>>>
>>>
>> Hi...  not tested, but IMHO your patch won't  be enough; you're not updating the spec->multiout.num_dacs inside the loop,
>> which means that is_empty_dac(codec, conn[i]) inside __parse_output_path() wil
> l not detect used DACs as used :
>
> Ah, good point.  Fixed now.
>
>
> Takashi
>

Working well now; this is the verbose dmesg output :

[  920.868350] ALSA hda_auto_parser.c:664 >hda_codec: VT1802: Apply pincfg for Asus G75
[  920.868367] ALSA hda_auto_parser.c:318 autoconfig: line_outs=2 (0x24/0x33/0x0/0x0/0x0) type:speaker
[  920.868371] ALSA hda_auto_parser.c:322    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
[  920.868374] ALSA hda_auto_parser.c:326    hp_outs=1 (0x25/0x0/0x0/0x0/0x0)
[  920.868376] ALSA hda_auto_parser.c:327    mono: mono_out=0x0
[  920.868378] ALSA hda_auto_parser.c:330    dig-out=0x2d/0x0
[  920.868380] ALSA hda_auto_parser.c:331    inputs:
[  920.868384] ALSA hda_auto_parser.c:335      Internal Mic=0x29
[  920.868387] ALSA hda_auto_parser.c:335      Mic=0x2b
[  920.868631] ALSA patch_via.c:1861 output-path: depth=4, 08/34/14/24/00
[  920.868647] ALSA patch_via.c:1861 output-path: depth=4, 08/21/14/24/00
[  920.868861] ALSA patch_via.c:1861 output-path: depth=4, 09/3c/1c/33/00
[  920.869321] ALSA patch_via.c:1861 output-path: depth=4, 08/35/15/25/00
[  920.869325] ALSA patch_via.c:1861 output-path: depth=4, 08/21/15/25/00

Which seems ok to me.
As before, I now have 2 front speakers (correctly) and 2 rear speakers, going to mono subwoofer.
I don't know if it's a correct behaviour or not.

Thank you

Massimo

  reply	other threads:[~2012-11-07 15:51 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-31 16:49 Fix for Asus G75 notebook subwoofer Massimo Del Fedele
2012-11-01  8:11 ` Raymond Yau
2012-11-01 11:15   ` Massimo Del Fedele
2012-11-02  1:44     ` Raymond Yau
2012-11-02 14:57       ` Massimo Del Fedele
2012-11-03  0:37         ` Raymond Yau
2012-11-03  9:04           ` Massimo Del Fedele
2012-11-04  6:27         ` Raymond Yau
2012-11-04  9:31           ` Massimo Del Fedele
2012-11-07  0:50             ` Raymond Yau
2012-11-06  8:36 ` Takashi Iwai
2012-11-06  8:57   ` Massimo Del Fedele
2012-11-06  9:06     ` Takashi Iwai
2012-11-06 14:18       ` Massimo Del Fedele
2012-11-06 14:24         ` Takashi Iwai
2012-11-06 17:23           ` Massimo Del Fedele
2012-11-07  8:56             ` Takashi Iwai
2012-11-07  8:56             ` Takashi Iwai
2012-11-07 13:37               ` Massimo Del Fedele
2012-11-07 13:45                 ` Takashi Iwai
2012-11-07 15:51                   ` Massimo Del Fedele [this message]
2012-11-07 15:54                     ` Takashi Iwai
2012-11-07 17:02                       ` Massimo Del Fedele
2012-11-07 17:13                         ` Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=509A8365.7060001@veneto.com \
    --to=max@veneto.com \
    --cc=alsa-devel@alsa-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox