Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Anssi Hannula <anssi.hannula@iki.fi>
To: John Ettedgui <john.ettedgui@gmail.com>
Cc: alsa-devel@alsa-project.org
Subject: Re: ALSA Multichannel through HDMI
Date: Fri, 26 Nov 2010 17:30:07 +0200	[thread overview]
Message-ID: <4CEFD27F.8040107@iki.fi> (raw)
In-Reply-To: <AANLkTin=YmPtqHDDqfNnvMXfZmMFKKkV4m10OWW_4ANY@mail.gmail.com>

On 26.11.2010 08:00, John Ettedgui wrote:
> On Thu, Nov 25, 2010 at 9:56 PM, John Ettedgui <john.ettedgui@gmail.com> wrote:
>> On Thu, Nov 25, 2010 at 6:21 PM, John Ettedgui <john.ettedgui@gmail.com> wrote:
>>> On Thu, Nov 25, 2010 at 6:16 PM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>> On 26.11.2010 04:02, John Ettedgui wrote:
>>>>> On Thu, Nov 25, 2010 at 5:08 PM, John Ettedgui <john.ettedgui@gmail.com> wrote:
>>>>>> On Thu, Nov 25, 2010 at 4:59 PM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>> On 26.11.2010 02:53, John Ettedgui wrote:
>>>>>>>> On Thu, Nov 25, 2010 at 3:34 PM, John Ettedgui <john.ettedgui@gmail.com> wrote:
>>>>>>>>> On Thu, Nov 25, 2010 at 3:15 PM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>>>>> On 26.11.2010 01:11, John Ettedgui wrote:
>>>>>>>>>>> On Thu, Nov 25, 2010 at 2:58 PM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>>>>>>> On 26.11.2010 00:42, John Ettedgui wrote:
>>>>>>>>>>>>> On Thu, Nov 25, 2010 at 11:19 AM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>>>>>>>>> On 25.11.2010 14:21, John Ettedgui wrote:
>>>>>>>>>>>>>>> On Thu, Nov 25, 2010 at 3:40 AM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>>>>>>>>>>> On 25.11.2010 13:09, John Ettedgui wrote:
>>>>>>>>>>>>>>>>> On Thu, Nov 25, 2010 at 2:49 AM, Anssi Hannula <anssi.hannula@iki.fi> wrote:
>>>>>>>>>>>>>>>>>> On 25.11.2010 06:12, John Ettedgui wrote:
>>>>>>>>>>>>>>>>>>> I'm actually trying to get a 5.1 setup working without passthrough, if
>>>>>>>>>>>>>>>>>>> I use mplayer with passthrough my receiver behaves just fine, but I am
>>>>>>>>>>>>>>>>>>> trying to send the 6 channels from the computer.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> I was actually told that the current ALSA driver for radeon's hdmi
>>>>>>>>>>>>>>>>>>> does not support more than 2 channels, and that would explain why I'm
>>>>>>>>>>>>>>>>>>> getting this behavior. Is that true though?
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Yes.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> However, strangely your log output seems to show the intel's hdmi parser
>>>>>>>>>>>>>>>>>> being used instead:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> ALSA sound/pci/hda/patch_intelhdmi.c:842: hdmi_setup_stream: NID=0x2,
>>>>>>>>>>>>>>>>>>> stream=0x1, new-format=0x11
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Were you just trying some patch at the time?
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> yes Wu gave me a patch to try against the kernel, I'm guessing this is
>>>>>>>>>>>>>>>>> the reason you see something unexpected.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Did 6 channels work with that patch? (possibly with a wrong channel order)
>>>>>>>>>>>>>>> Not any better as far as I remember.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> OK. Did 2 channel audio continue to work with it?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> If you are not sure, here's the patch doing the same thing against
>>>>>>>>>>>>>> current alsa driver:
>>>>>>>>>>>>>> http://stuff.onse.fi/0001-ALSA-hda-Use-generic-HDMI-code-for-ATI-HDMI-codecs.patch
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Confirming that would help (it would allow to switch the ATI chip to use
>>>>>>>>>>>>>> the generic parser instead of the ATI-specific one), though not with the
>>>>>>>>>>>>>> multichannel issue (see below).
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> [...]
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Since I just moved to jack/rca cables I'm in no hurry anymore, but is
>>>>>>>>>>>>>>>>> there any reason why the driver cannot work with more than 2 channels?
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> I don't really know (it is simply not implemented).
>>>>>>>>>>>>>>> Alright.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Anything I could do to help with that?
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Possibly. But see above, so that we won't try the same things you
>>>>>>>>>>>>>>>> already tried :)
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Sure :)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Looking again at the the alsa info output you provided, I don't think I
>>>>>>>>>>>>>> have any great ideas. It looks like the chip simply reports that it
>>>>>>>>>>>>>> supports a maximum of 2 channels.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> One option could be hardcoding "chans = 8;" in generic_hdmi_build_pcms()
>>>>>>>>>>>>>> in sound/pci/hda/patch_hdmi.c (assuming you have the above patch and 2
>>>>>>>>>>>>>> channel audio works with it). However, I find it rather unlikely that it
>>>>>>>>>>>>>> would make any difference.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Anssi Hannula
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> Anssi,
>>>>>>>>>>>>> the patch fails on my kernel, I cannot find the hda_codec_preset
>>>>>>>>>>>>> manually in there either.
>>>>>>>>>>>>> Did you want me to try that against a 2.6.37 rc instead of a 2.6.36?
>>>>>>>>>>>>
>>>>>>>>>>>> For 2.6.36 I think you can just use your earlier patch.
>>>>>>>>>>>>
>>>>>>>>>>>> Note that on that kernel generic_hdmi_build_pcms() is
>>>>>>>>>>>> intel_hdmi_build_pcms() in patch_intelhdmi.c.
>>>>>>>>>>>>
>>>>>>>>>>> ok
>>>>>>>>>>>> BTW, I've just been informed by another ATI user that his card was
>>>>>>>>>>>> actually stereo-only, while he thought earlier it was multichannel
>>>>>>>>>>>> capable. So, are you sure your card is a multichannel one?
>>>>>>>>>>>> (if not, it would explain why the card says it is not)
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Anssi Hannula
>>>>>>>>>>>>
>>>>>>>>>>> Yes, it works fine in Window  so I believe the hardware part is good.
>>>>>>>>>>
>>>>>>>>>> And you are sure it is multichannel PCM, and not e.g. multichannel DTS
>>>>>>>>>> or multichannel AC-3 with on-the-fly compression, which are possible
>>>>>>>>>> with stereo hdmi as well?
>>>>>>>>>>
>>>>>>>>>> Just making sure :)
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Anssi Hannula
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Well, I have not super tested it, but the reason I believe it is is
>>>>>>>>> simple, when I use passthrough my receiver says Dolby digital or
>>>>>>>>> something like that, but in Windows just going around or playing games
>>>>>>>>> it says Multichannel.
>>>>>>>
>>>>>>> Sounds ok then.
>>>>>>>
>>>>>>>>> I'll get the patch applied in a few minutes, I was running out of
>>>>>>>>> memory and my system was getting really slow... :)
>>>>>>>>>
>>>>>>>>
>>>>>>>> I am not sure if I did it right but now I don't even get hdmi sound
>>>>>>>> working anymore.
>>>>>>>> It is not listed in aplay-l, and dmesg gives me this:
>>>>>>>> [drm:radeon_dvi_detect] *ERROR* HDMI Type A-1: probed a monitor but
>>>>>>>> no|invalid EDID
>>>>>>>>
>>>>>>>> I've attached the patch I used, since I could not used the previous
>>>>>>>> one I had to hack it, maybe I broke something?
>>>>>>>> (I have not set channels to 8 yet, just changed the parser)
>>>>>>>
>>>>>>> The patch looks ok. The above error message is weird, as it comes from
>>>>>>> the display driver which should not be affected by the patch at all.
>>>>>>>
>>>>>>> I'll look at the code later (tomorrow maybe). Until then I'd advise you
>>>>>>> to retry without the patch and with the patch again, just to make sure
>>>>>>> this is not some unrelated issue...
>>>>>>> Also, post the whole dmesg when it works (2 channel, without patch), and
>>>>>>> when it doesn't (with patch).
>>>>>>>
>>>>>>> --
>>>>>>> Anssi Hannula
>>>>>>>
>>>>>> Following your message I restarted my computer and that error was
>>>>>> gone, yet there is still nothing display in aplay -l / aplay -L about
>>>>>> hdmi anymore.
>>>>>> I'll go back to my non patched kernel and see what it does.
>>>>>>
>>>>> With the non-patched kernel I get back my hdmi in aplay -l, so it
>>>>> looks like the patch messed up something.
>>>>
>>>> Indeed.
>>>>
>>>>> I really think that when I tried it before it did not do that, but it
>>>>> was so long ago that I could be wrong...
>>>>
>>>> Well, the driver has changed since then, it could be more strict now :)
>>>>
>>>>> Anyway here are the 2 dmesgs (not sure if they'll help though).
>>>>
>>>> Indeed, there doesn't seem to be any difference. Maybe try with
>>>> CONFIG_SND_DEBUG_VERBOSE?
>>>>
>>>> --
>>>> Anssi Hannula
>>>>
>>>
>>> Sure I'll get that.
>>>
>>
>> There you go.

> ALSA sound/pci/hda/hda_intel.c:2531: chipset global capabilities = 0x1001
> ALSA sound/pci/hda/hda_intel.c:913: codec_mask = 0x1
> ALSA sound/pci/hda/hda_intel.c:1354: codec #0 probed OK
> ALSA sound/pci/hda/hda_generic.c:683: hda_generic: no proper input path found

Hm, for some reason it doesn't try to use the intelhdmi module. Is it
getting loaded? Have you run "depmod"?
Does "modinfo snd-hda-codec-intelhdmi" show the alias you added?

-- 
Anssi Hannula

  reply	other threads:[~2010-11-26 15:30 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20100112045102.GA29735@localhost>
     [not found] ` <eb9000ab1001112311o4bcf98dp2b616d1afffec9e0@mail.gmail.com>
     [not found]   ` <20100112132140.GA7647@localhost>
     [not found]     ` <eb9000ab1001120828l6829c6b1g30916b872a0467f7@mail.gmail.com>
     [not found]       ` <20100113010942.GA6435@localhost>
     [not found]         ` <eb9000ab1001121732y4212e6m9596f68e24d6c226@mail.gmail.com>
     [not found]           ` <20100113014550.GA10184@localhost>
     [not found]             ` <eb9000ab1001122048s1ac0d9c3n130692ba83dd53d1@mail.gmail.com>
     [not found]               ` <20100113045238.GB26275@localhost>
     [not found]                 ` <eb9000ab1001122055s54bc6697t6103def1e8ae64ae@mail.gmail.com>
     [not found]                   ` <20100113050254.GA28475@localhost>
2010-11-24 23:26                     ` ALSA Multichannel through HDMI John Ettedgui
2010-11-25  3:59                       ` Mohammad Bahathir Hashim
2010-11-25  4:12                         ` John Ettedgui
2010-11-25  5:10                           ` Mohammad Bahathir Hashim
2010-11-25  5:36                             ` John Ettedgui
2010-11-25 10:49                           ` Anssi Hannula
2010-11-25 11:09                             ` John Ettedgui
2010-11-25 11:40                               ` Anssi Hannula
2010-11-25 12:21                                 ` John Ettedgui
2010-11-25 19:19                                   ` Anssi Hannula
2010-11-25 22:42                                     ` John Ettedgui
2010-11-25 22:58                                       ` Anssi Hannula
2010-11-25 23:11                                         ` John Ettedgui
2010-11-25 23:15                                           ` Anssi Hannula
     [not found]                                             ` <AANLkTikS4C6GS2EuqdA_D58y4h9qCMBEWPSoO7JdhC9g@mail.gmail.com>
2010-11-26  0:53                                               ` John Ettedgui
2010-11-26  0:59                                                 ` Anssi Hannula
2010-11-26  1:08                                                   ` John Ettedgui
2010-11-26  2:02                                                     ` John Ettedgui
2010-11-26  2:13                                                       ` John Ettedgui
2010-11-26  2:16                                                       ` Anssi Hannula
     [not found]                                                         ` <AANLkTinbea0wMDCuEQgbO7tqxWBB_qfZub9+yNyC+2LR@mail.gmail.com>
2010-11-26  5:56                                                           ` John Ettedgui
2010-11-26  6:00                                                             ` John Ettedgui
2010-11-26 15:30                                                               ` Anssi Hannula [this message]
2010-11-27  4:53                                                                 ` John Ettedgui
2010-12-04 23:58                                                                   ` Anssi Hannula
2010-12-05 22:32                                                                     ` John Ettedgui
2011-01-22 23:34                                                                       ` John Ettedgui
2010-01-08  4:25 John Ettedgui

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=4CEFD27F.8040107@iki.fi \
    --to=anssi.hannula@iki.fi \
    --cc=alsa-devel@alsa-project.org \
    --cc=john.ettedgui@gmail.com \
    /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