[alsa-devel] [PATCH] ALSA: hda - initialize audio InfoFrame to be all zero

Takashi Iwai tiwai at suse.de
Tue Mar 11 09:16:05 CET 2014


At Tue, 11 Mar 2014 17:12:52 -0400,
mengdong.lin at intel.com wrote:
> 
> From: Mengdong Lin <mengdong.lin at intel.com>
> 
> This patch initialized the local audio InfoFrame variable 'ai' to be all zero,
> thus the data bytes will indicate "Refer to Stream Header" by default.
> 
> Signed-off-by: Mengdong Lin <mengdong.lin at intel.com>

Thanks, applied.


Takashi

> 
> diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
> index 5ef9503..3ab7063 100644
> --- a/sound/pci/hda/patch_hdmi.c
> +++ b/sound/pci/hda/patch_hdmi.c
> @@ -1062,6 +1062,7 @@ static void hdmi_pin_setup_infoframe(struct hda_codec *codec,
>  {
>  	union audio_infoframe ai;
>  
> +	memset(&ai, 0, sizeof(ai));
>  	if (conn_type == 0) { /* HDMI */
>  		struct hdmi_audio_infoframe *hdmi_ai = &ai.hdmi;
>  
> -- 
> 1.8.1.2
> 


More information about the Alsa-devel mailing list