[alsa-devel] ALSA patch Nvidia 8 channel hdmi audio
Alan Alan
alanwww1 at gmail.com
Fri Jun 5 01:20:52 CEST 2009
I made a test on Windows. And it seems that my codec MCP7A does support up
to 8channels 192khz, 24bits no problem.
One important thing i noticed:
If i plug the hdmi to the lcd TV, the windows control panel only shows up
to 2ch, 48khz. When i plug it into the Onkyo-TXSR605 av receiver and reboot,
only than it shows up the HD options.
I enclosed a screenshout about it. When i press test button, the audio
sounds in the receiver even with 192/24
Strange thing here that on win, it does not even show the 88.2khz number.
And sample rates depend on what device is plugged, but on alsa i always get
the same output (48, 88.2khz) whatever device i plug on.
2009/6/4 Takashi Iwai <tiwai at suse.de>
> At Thu, 4 Jun 2009 08:18:23 +0200,
> Alan Alan wrote:
> >
> > 2009/6/4 Takashi Iwai <tiwai at suse.de>
> >
> > At Thu, 4 Jun 2009 01:28:24 +0200,
> > Alan Alan wrote:
> > >
> > > Hello Takashi !
> > >
> > > I tried to apply the patch that removes restrictions to 16bits
> 48khz
> > format.
> > > Well now we have the following:
> > > 16bit 48khz works
> > > 32bit 48khz works
> > > 32bit 44khz, 96khz, 192khz don't work
> > > 24bit 44khz, 48khz, 96khz, 192khz don't work
> > > 16bit 44khz, 96khz, 192khz don't work
> > >
> > > I only get
> > > Sample format not available for playback:
> > > Setting of hwparams failed:
> >
> > As you can find in alsa-info output, it seems that the codec supports
> > only 48kHz and 88.2kHz, strangely. I don't know whether it's a
> > (hardware) bug or not.
> >
> > The codec surely supports up to 192khz as it works on Windows.
> >
> > I think this line is completely wrong as here it says:
>
> It is not "wrong". These are values that the codec reports, so it's
> more or less correct as the h/w information.
>
> > rates [0xc0]: 48000 88200
>
> Wei, is it right? Or is anything missing here?
>
>
> > bits [0xf]: 8 16 20 24
> >
> > 8, 20, 24bits are supported, but they all give an error message.
>
> 24bit here means 24bit in 4 bytes, thus it's essentially 32bit format.
> 24bit in 3 bytes format isn't supported on HD-audio.
>
> > 32 bits are not supposed to be supported but it works with 48 and
> 88.2khz.
> >
> > How can we change the software side to accept 96 or 192khz spample
> formats and
> > 24 bits ?
>
> As long as the codec reports so, it's no "software" problem.
>
> > I think it is not hardware limited and we just need to change the allowed
> > formats to be played.
>
> If it's just a hardware problem that reports wrong values, you can
> override the information, simply replacing the bits my patch disabled
> to the right values.
>
>
> Takashi
>
> >
> > >
> > > I enclosed to pastebin my alsainfo script output.
> > >
> > > http://pastebin.com/m77dcfb3f
> > >
> > > Thanks for the help !
> > >
> > > 2009/6/3 Takashi Iwai <tiwai at suse.de>
> > >
> > > At Wed, 3 Jun 2009 11:34:00 +0200,
> > > Alan Alan wrote:
> > > >
> > > > Hello Takashi !
> > > >
> > > > What should this patch do ?
> > >
> > > The patch removes the restriction patch_nvhdmi.c sets.
> Instead,
> > > the driver tries to detect the supported format, rate, etc from
> the
> > > codec widget information.
> > >
> > > > Is it a cure for the 96, 192khz or 24bit sample playback
> problem ?
> > >
> > > Possibly.
> > >
> > > > If so, will it resample or natievly pass the stream to the
> > amplifier ?
> > >
> > > It just enables the native support, possibly.
> > >
> > > And, don't forget to give back the alsa-info.sh output (run
> with
> > > --no-upload option).
> > >
> > > Takashi
> > >
> > > >
> > > > Thank you
> > > >
> > > > Alan
> > > >
> > > > 2009/6/3 Takashi Iwai <tiwai at suse.de>
> > > >
> > > > At Wed, 3 Jun 2009 10:00:24 +0200,
> > > > Alan Alan wrote:
> > > > >
> > > > > Hello Wei !
> > > > >
> > > > > Thanks for replying.
> > > > > I tested it with speaker-test and xbmc babylon. Both
> had
> > problems
> > > with
> > > > > channel mapping.
> > > > > I used this command:
> > > > >
> > > > > speaker-test -Dhdmi -c6
> > > > > or
> > > > > speaker-test -Dhdmi -c8
> > > > >
> > > > > alternatively you could try
> > > > >
> > > > > speaker-test -Dhw:0,3 -c6
> > > > >
> > > > >
> > > > > I had to rund Xorg first and have the command from an
> xterm,
> > > becasue
> > > > from a
> > > > > normal terminal it would not work.
> > > > > I think that is normal as a limitation of hdmi.
> > > > >
> > > > > What about the support for 24bits 192khz sound ?
> > > > >
> > > > > speaker-test -Dhdmi -c6 -r192000 does not work.
> > > >
> > > > How about the patch below?
> > > >
> > > > Also, could you give alsa-info.sh output?
> > > >
> > > > Takashi
> > > >
> > > > ---
> > > > diff --git a/sound/pci/hda/patch_nvhdmi.c
> b/sound/pci/hda/
> > > patch_nvhdmi.c
> > > > index f5792e2..48443de 100644
> > > > --- a/sound/pci/hda/patch_nvhdmi.c
> > > > +++ b/sound/pci/hda/patch_nvhdmi.c
> > > > @@ -258,9 +258,11 @@ static struct hda_pcm_stream
> > > > nvhdmi_pcm_digital_playback_8ch = {
> > > > .channels_min = 2,
> > > > .channels_max = 8,
> > > > .nid = Nv_Master_Convert_nid,
> > > > +#if 0
> > > > .rates = SNDRV_PCM_RATE_48000,
> > > > .maxbps = 16,
> > > > .formats = SNDRV_PCM_FMTBIT_S16_LE,
> > > > +#endif
> > > > .ops = {
> > > > .open = nvhdmi_dig_playback_pcm_open,
> > > > .close =
> nvhdmi_dig_playback_pcm_close_8ch,
> > > > @@ -273,9 +275,11 @@ static struct hda_pcm_stream
> > > > nvhdmi_pcm_digital_playback_2ch = {
> > > > .channels_min = 2,
> > > > .channels_max = 2,
> > > > .nid = Nv_Master_Convert_nid,
> > > > +#if 0
> > > > .rates = SNDRV_PCM_RATE_48000,
> > > > .maxbps = 16,
> > > > .formats = SNDRV_PCM_FMTBIT_S16_LE,
> > > > +#endif
> > > > .ops = {
> > > > .open = nvhdmi_dig_playback_pcm_open,
> > > > .close =
> nvhdmi_dig_playback_pcm_close_2ch,
> > > >
> > > >
> > >
> > >
> >
> >
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: NV-hdmi.jpg
Type: image/jpeg
Size: 144879 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20090605/26528bcc/attachment-0001.jpg
More information about the Alsa-devel
mailing list