[Intel-gfx] Problems with HDMI audio on Intel DG45FC motherboard

Wu Fengguang fengguang.wu at intel.com
Wed Oct 28 07:13:09 CET 2009


On Wed, Oct 28, 2009 at 12:46:21PM +0800, Wu Fengguang wrote:
> - if add a 800ms sleep in intel_hdmi_playback_pcm_prepare(), the
>   first-0.5s-samples-lost problem disappears

I managed to locate the HDA command that caused the delay :)

        void snd_hda_codec_setup_stream(struct hda_codec *codec, hda_nid_t nid,
                                        u32 stream_tag,
                                        int channel_id, int format)
        {      
                if (!nid)
                        return;

                snd_printdd("hda_codec_setup_stream: "
                            "NID=0x%x, stream=0x%x, channel=%d, format=0x%x\n",
                            nid, stream_tag, channel_id, format);
==>             snd_hda_codec_write(codec, nid, 0, AC_VERB_SET_CHANNEL_STREAMID,
                                    (stream_tag << 4) | channel_id);
+               msleep(500);


If the msleep() is added before the AC_VERB_SET_CHANNEL_STREAMID line,
problem remains; if added after it, problem disappears.

However it's very unclear how it can be fixed in a more sane way..

Thanks,
Fengguang



More information about the Intel-gfx mailing list