* HDA - hdmi_show_short_audio_desc puts wrong rates in eld#N
@ 2010-12-07 11:01 Anssi Hannula
2011-01-11 17:25 ` Anssi Hannula
0 siblings, 1 reply; 2+ messages in thread
From: Anssi Hannula @ 2010-12-07 11:01 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel
Hi!
Just noticed that the sample rates reported in eld#X.Y are wrong.
They are printed by hdmi_show_short_audio_desc() in hda_eld.c. That
function uses the snd_print_pcm_rates() function to convert the rates
bitmap to a string. However, snd_print_pcm_rates() takes a HDA rates
bitmap, not a generic SNDRV_ one. (BTW, an interesting function name
for an internal HDA thing...)
This results in several errors.
For example, my 32000 44100 48000 88200 96000 176400 192000
becomes 44100 48000 88200 176400 192000 384000.
--
Anssi Hannula
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: HDA - hdmi_show_short_audio_desc puts wrong rates in eld#N
2010-12-07 11:01 HDA - hdmi_show_short_audio_desc puts wrong rates in eld#N Anssi Hannula
@ 2011-01-11 17:25 ` Anssi Hannula
0 siblings, 0 replies; 2+ messages in thread
From: Anssi Hannula @ 2011-01-11 17:25 UTC (permalink / raw)
To: alsa-devel
On 07.12.2010 13:01, Anssi Hannula wrote:
> Hi!
>
> Just noticed that the sample rates reported in eld#X.Y are wrong.
>
> They are printed by hdmi_show_short_audio_desc() in hda_eld.c. That
> function uses the snd_print_pcm_rates() function to convert the rates
> bitmap to a string. However, snd_print_pcm_rates() takes a HDA rates
> bitmap, not a generic SNDRV_ one. (BTW, an interesting function name
> for an internal HDA thing...)
>
> This results in several errors.
>
> For example, my 32000 44100 48000 88200 96000 176400 192000
> becomes 44100 48000 88200 176400 192000 384000.
In case I write a patch for this, is there a preferred approach?
(a) Add a function into alsa core that returns such a list string when
given a rates bitmap, or
(b) export the rates array in core and make the string-giving function a
static one for hda_eld.c, or
(c) add a static function into hda_eld.c that parses the bitmap manually
by checking it for all the hdmi rates (7 IIRC).
--
Anssi Hannula
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-01-11 17:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-07 11:01 HDA - hdmi_show_short_audio_desc puts wrong rates in eld#N Anssi Hannula
2011-01-11 17:25 ` Anssi Hannula
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).