Bug 12187

Summary: not audio- play (wav) with HDMI, 2.4
Product: [Build System, Metadata & Runtime] BSPs Reporter: oscar lopez arandas <oscarx.lopez.arandas>
Component: bsps-toolsAssignee: Anuj Mittal <anuj.mittal>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium CC: jair.de.jesus.gonzalez.plascencia, pravin.shankarx.patil, randy.macleod
Version: 2.4   
Target Milestone: 4.99   
Hardware: NUC   
OS: x86_64   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Don't know
Attachments:
Description Flags
wav_file
none
gst-play
none
full_log
none
2.4_M4_rc3_genericx86-64_NUC.log none

Description oscar lopez arandas 2017-10-04 20:34:33 UTC
Created attachment 4053 [details]
wav_file

launch media player and play the (wav) file via HDMI the audio is not present, sometimes is intermittent the audio in direct on output in the NUC, both via HDMI never is present.  
Check if amixer is installed, this could be done typing "amixer" on Terminal,  and Amixer is present.
 Run "amixer set Master on" to turn on audio device. and  the audio is  not present. 

==================================================================
sh-4.4# amixer set Master on
simple mixer control 'Master' 0
  capabilities: pvolume pswitch pswitch-joined
  playback channels: Front left - Front Right
  limits: playback 0 - 65536
  Mono:
  Front Left: Playback 65536 [100%] [on]
  Front Right: Playback 65536 [100%] [on]
======================================================

BUILD: 2.4 M4: rc1-592c3449697ce39bf07864fafd7f0a61ca230561
ENVIRONMENT: Genericx86-64_NUC
 NUC 6i5SYH 
images: https://autobuilder.yocto.io/pub/releases/yocto-2.4.rc1/machines/genericx86-64/core-image-sato-sdk-genericx86-64.hddimg

STEPS TO REPRODUCE: 
1. copy sample wav file to system
2. connect system with a monitor with HDMI
3. launch media player and play the wav file

EXPECTED OUTCOME:
 wav file can be played without problem, with HDMI

ACTUAL OUTCOME:
the audio is not present with  played wav file in HDMI

NOTE:
wav file in attachment
Comment 1 California Sullivan 2017-10-05 00:10:40 UTC
I was able to reproduce the initial issue on hardware available to me.

Interestingly, audio works with headphones, and once the headphones are unplugged, HDMI audio begins working as well, so I think its most likely a configuration issue.

Can you try reproducing the above?
Comment 2 oscar lopez arandas 2017-10-05 13:31:33 UTC
(In reply to comment #1)
> I was able to reproduce the initial issue on hardware available to me.
> 
> Interestingly, audio works with headphones, and once the headphones are
> unplugged, HDMI audio begins working as well, so I think its most likely a
> configuration issue.
> 
> Can you try reproducing the above?

similarly perform different tests with the headphones testing directly on nuc and then via HDMI and it does not work,
probe downloading the image again, relay tests on another nuc of the same model and switch HDMI cables, change monitor and can not get audio in any attempt.
Comment 3 California Sullivan 2017-10-05 23:13:05 UTC
try running this from a terminal:

pacmd set-card-profile 0 output:hdmi-stereo
gst-play-1.0 /path/to/your/wav/file
Comment 4 oscar lopez arandas 2017-10-06 13:47:15 UTC
(In reply to comment #3)
> try running this from a terminal:
> 
> pacmd set-card-profile 0 output:hdmi-stereo
> gst-play-1.0 /path/to/your/wav/file

if the wav file is played but still without audio, I uploaded the whole volume using the arrows above, attached process log.
Comment 5 oscar lopez arandas 2017-10-06 13:47:46 UTC
Created attachment 4057 [details]
gst-play
Comment 6 oscar lopez arandas 2017-10-06 13:54:31 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > try running this from a terminal:
> > 
> > pacmd set-card-profile 0 output:hdmi-stereo
> > gst-play-1.0 /path/to/your/wav/file
> 
> if the wav file is played but still without audio, I uploaded the whole
> volume using the arrows above, attached process log.

the audio is only present in the output of the NUC via HDMI there is no audio
Comment 7 California Sullivan 2017-10-06 18:29:00 UTC
I'm thinking this is a kernel issue, as we have found the following:

NUC6, intel-corei7-64: works (with some configuration)
NUC6, genericx86-64: does not work
NUC7, intel-corei7-64: works (with some configuration)
NUC7, genericx86-64: works (with some configuration)

intel-corei7-64 is currently using the linux-intel-4.9 kernel, whereas genericx86-64 is using the linux-yocto-4.12 kernel.

I may try pyro genericx86-64 next.
Comment 8 California Sullivan 2017-10-06 23:12:43 UTC
With pyro genericx86-64 (linux-yocto-4.10), hdmi audio works with no additional configuration.

With master genericx86-64, and PREFERRED_VERSION_linux-yocto = "4.10%", hdmi audio works with the additional configuration above.

There definitely appears to be a new kernel issue with the 4.12 kernel.
Comment 9 oscar lopez arandas 2017-10-10 16:18:33 UTC
his is the type of karnel version,
sh-4.4# uname -r
4.12.12-yocto-standard

 in the automatic test of generixc86-64-nuc and wic, this present this in central error 
-----------------------
Central error: [    1.457891] snd_hda_codec_hdmi: probe of hdaudioC0D2 failed with error -16
***********************
full-log in attachment
Comment 10 oscar lopez arandas 2017-10-10 16:19:10 UTC
Created attachment 4068 [details]
full_log
Comment 11 oscar lopez arandas 2017-10-13 17:23:33 UTC
does not play the audio in wav format, ogg through the HDMI monitor, in 2.4_M4_rc2, there is only the audio of wav and ogg formats in direct of the nuc output
Comment 12 oscar lopez arandas 2017-10-17 21:51:12 UTC
does not play the audio in wav  or ogg format, through the HDMI monitor, in 2.4_M4_rc3, there is only the audio of wav and ogg formats in direct of the nuc output

BUILD: 2.4 M4: rc3-65d23bd7986615fdfb0f1717b615534a2a14ab80 
ENVIRONMENT: Genericx86-64_NUC
 NUC 6i5SYH 
images: https://autobuilder.yocto.io/pub/releases/yocto-2.4.rc3/machines/genericx86-64/core-image-sato-sdk-genericx86-64.hddimg

STEPS TO REPRODUCE: 
1. copy sample wav or ogg file to system
2. connect system with a monitor with HDMI
3. launch media player and play the wav  or oggfile

EXPECTED OUTCOME:
 wav or ogg file can be played without problem, with HDMI

ACTUAL OUTCOME:
the audio is not present with  played wav or ogg file in HDMI
Comment 13 Jair Gonzalez 2017-10-20 21:31:53 UTC
Created attachment 4094 [details]
2.4_M4_rc3_genericx86-64_NUC.log
Comment 14 Jair Gonzalez 2017-10-20 21:33:06 UTC
BUILD: 2.4 M4: rc3-65d23bd7986615fdfb0f1717b615534a2a14ab80
ENVIRONMENT: genericx86-64_NUC
NUC Model: NUC6i5SYH
IMAGES: core-image-sato-sdk.wic, core-image-sato-sdk.hddimg

The "snd_hda_codec_hdmi" parselog errors continue appearing in 2.4 RC3 on automatic BSP testing for genericx86-64 images in NUC (in both, wic and hddimg formats). For more reference, I have attached the log file with more details about the execution using the hddimg version.

This is an example of the errors that appear:
***********************
Central error: [    1.453224] snd_hda_codec_hdmi: probe of hdaudioC0D2 failed with error -16
***********************
[    1.448566] snd_hda_intel 0000:00:1f.3: Consider building the kernel with CONFIG_SND_DYNAMIC_MINORS=y
[    1.449571] snd_hda_intel 0000:00:1f.3: control 3:0:0:ELD:0 is already present
[    1.449609] snd_hda_codec_hdmi: probe of hdaudioC0D2 failed with error -16
[    1.452014] snd_hda_intel 0000:00:1f.3: Too many HDMI devices
[    1.452015] snd_hda_intel 0000:00:1f.3: Consider building the kernel with CONFIG_SND_DYNAMIC_MINORS=y
[    1.452015] snd_hda_intel 0000:00:1f.3: Too many HDMI devices
[    1.452016] snd_hda_intel 0000:00:1f.3: Consider building the kernel with CONFIG_SND_DYNAMIC_MINORS=y
[    1.452017] snd_hda_intel 0000:00:1f.3: Too many HDMI devices
[    1.452017] snd_hda_intel 0000:00:1f.3: Consider building the kernel with CONFIG_SND_DYNAMIC_MINORS=y
[    1.453193] snd_hda_intel 0000:00:1f.3: control 3:0:0:ELD:0 is already present
[    1.453224] snd_hda_codec_hdmi: probe of hdaudioC0D2 failed with error -16
[    1.453793] snd_hda_codec_generic hdaudioC0D2: ignore pin 0x7, too many assigned pins
[    1.453795] snd_hda_codec_generic hdaudioC0D2: autoconfig for Generic: line_outs=0 (0x0/0x0/0x0/0x0/0x0) type:line
[    1.453796] snd_hda_codec_generic hdaudioC0D2:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
[    1.453796] snd_hda_codec_generic hdaudioC0D2:    hp_outs=0 (0x0/0x0/0x0/0x0/0x0)
[    1.453797] snd_hda_codec_generic hdaudioC0D2:    mono: mono_out=0x0
[    1.453798] snd_hda_codec_generic hdaudioC0D2:    dig-out=0x5/0x6
[    1.453799] snd_hda_codec_generic hdaudioC0D2:    inputs:
[    1.455463] input: HDA Intel PCH Mic as /devices/pci0000:00/0000:00:1f.3/sound/card0/input4
[    1.455526] input: HDA Intel PCH Headphone as /devices/pci0000:00/0000:00:1f.3/sound/card0/input5
[    1.455598] input: HDA Intel PCH HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:1f.3/sound/card0/input6
Comment 15 pravin 2018-07-26 05:27:04 UTC
in yocto release 2.6 M2 rc1 this bug is resolved.