All of lore.kernel.org
 help / color / mirror / Atom feed
* HDMI Audio Channels mis-detected on i915
@ 2011-05-21  1:06 Jeremy Bush
  2011-05-23 13:32 ` Wu Fengguang
  0 siblings, 1 reply; 5+ messages in thread
From: Jeremy Bush @ 2011-05-21  1:06 UTC (permalink / raw)
  To: intel-gfx

Hello,

I posted something similar to this on the ALSA mailing list, but they directed me here, since HDMI detection has to do with the video driver instead of ALSA.

I have my machine hooked up to an Onkyo TX-SR607 7.2-Channel receiver. Yet when the machine boots,  HDMI detection mis-detects the hardware on the other end of the HDMI cable:

[ 2.090473] HDMI: detected monitor at connection type HDMI
[ 2.090475] HDMI: available speakers: FL/FR
[ 2.090477] HDMI: supports coding type LPCM: channels = 2, rates = 44100 48000 88200, bits = 16
[ 2.090480] HDMI hot plug event: Pin=6 Presence_Detect=1 ELD_Valid=1

You can see my whole alsa info (including it actually detecting the hardware can do 7.1 [note Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP]) here: http://www.alsa-project.org/db/?f=5b55a63fea6580dfcbf1a85c7c734f977df798f1

Is this a known problem?

My machine specs are as follows:

Intel i3 2100T
MSI H67MA-E45 (with Realtek ALC892 audio chip)

I'm using HDMI output only.

Thanks for any info-

Jeremy Bush

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HDMI Audio Channels mis-detected on i915
  2011-05-21  1:06 HDMI Audio Channels mis-detected on i915 Jeremy Bush
@ 2011-05-23 13:32 ` Wu Fengguang
  2011-05-23 13:39   ` Jeremy Bush
  2011-05-23 23:29   ` Jeremy Bush
  0 siblings, 2 replies; 5+ messages in thread
From: Wu Fengguang @ 2011-05-23 13:32 UTC (permalink / raw)
  To: Jeremy Bush; +Cc: intel-gfx

Hi Jeremy,

On Fri, May 20, 2011 at 08:06:20PM -0500, Jeremy Bush wrote:
> Hello,
> 
> I posted something similar to this on the ALSA mailing list, but they directed me here, since HDMI detection has to do with the video driver instead of ALSA.

Right.

> I have my machine hooked up to an Onkyo TX-SR607 7.2-Channel receiver. Yet when the machine boots,  HDMI detection mis-detects the hardware on the other end of the HDMI cable:
> 
> [ 2.090473] HDMI: detected monitor at connection type HDMI
> [ 2.090475] HDMI: available speakers: FL/FR
> [ 2.090477] HDMI: supports coding type LPCM: channels = 2, rates = 44100 48000 88200, bits = 16
> [ 2.090480] HDMI hot plug event: Pin=6 Presence_Detect=1 ELD_Valid=1

That information is filled by BIOS or VBIOS. There are 3 possibilities
1) BIOS provides some dumb EDID-Like Data (ELD) regardless of the HDMI sink
2) BIOS does not parse EDID correctly
3) your TX-SR607 EDID data is broken

I'm writing a drm patch to do ELD for audio in the graphics driver,
which will address problems caused by (1) and (2). I've done the
scratch patch, but will need more tests before sending it out.

For now you may still manually correct ELD with this command:

        echo speakers 0 > '/proc/asound/card0/eld#3.0'

By clearing the speakers setting, the audio driver will assume your
HDMI sink supports all speakers.

> You can see my whole alsa info (including it actually detecting the hardware can do 7.1 [note Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP]) here: http://www.alsa-project.org/db/?f=5b55a63fea6580dfcbf1a85c7c734f977df798f1

This is the Intel HDMI port's audio capability and is always
8-channels. In contrast the ELD describes how many speakers (and hence
channels) are attached to the HDMI sink device (TX-SR607 in your case).

> Is this a known problem?
> 
> My machine specs are as follows:
> 
> Intel i3 2100T
> MSI H67MA-E45 (with Realtek ALC892 audio chip)
> 
> I'm using HDMI output only.

Will you try the above workaround command first? For the long term
solution, if you are ready to compile new kernels, I can send you the
patch for testing.

Thanks,
Fengguang

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HDMI Audio Channels mis-detected on i915
  2011-05-23 13:32 ` Wu Fengguang
@ 2011-05-23 13:39   ` Jeremy Bush
  2011-05-23 14:08     ` Jeremy Bush
  2011-05-23 23:29   ` Jeremy Bush
  1 sibling, 1 reply; 5+ messages in thread
From: Jeremy Bush @ 2011-05-23 13:39 UTC (permalink / raw)
  To: Wu Fengguang; +Cc: intel-gfx


On May 23, 2011, at 8:32 AM, Wu Fengguang wrote:

> Hi Jeremy,
> 
>> I have my machine hooked up to an Onkyo TX-SR607 7.2-Channel receiver. Yet when the machine boots,  HDMI detection mis-detects the hardware on the other end of the HDMI cable:
>> 
>> [ 2.090473] HDMI: detected monitor at connection type HDMI
>> [ 2.090475] HDMI: available speakers: FL/FR
>> [ 2.090477] HDMI: supports coding type LPCM: channels = 2, rates = 44100 48000 88200, bits = 16
>> [ 2.090480] HDMI hot plug event: Pin=6 Presence_Detect=1 ELD_Valid=1
> 
> That information is filled by BIOS or VBIOS. There are 3 possibilities
> 1) BIOS provides some dumb EDID-Like Data (ELD) regardless of the HDMI sink
> 2) BIOS does not parse EDID correctly
> 3) your TX-SR607 EDID data is broken
> 
> I'm writing a drm patch to do ELD for audio in the graphics driver,
> which will address problems caused by (1) and (2). I've done the
> scratch patch, but will need more tests before sending it out.
> 
> For now you may still manually correct ELD with this command:
> 
>        echo speakers 0 > '/proc/asound/card0/eld#3.0'
> 
> By clearing the speakers setting, the audio driver will assume your
> HDMI sink supports all speakers.


Hrm, just tried that, but speaker-test is still failing:

htpc ~ # echo speakers 0 > /proc/asound/card1/eld#3.0 
htpc ~ # cat /proc/asound/card1/eld#3.0 
monitor_present		1
eld_valid		1
monitor_name		
connection_type		HDMI
eld_version		[0x2] CEA-861D or below
edid_version		[0x3] CEA-861-B, C or D
manufacture_id		0x0
product_id		0x0
port_id			0x0
support_hdcp		1
support_ai		0
audio_sync_delay	0
speakers		[0x0]
sad_count		1
sad0_coding_type	[0x1] LPCM
sad0_channels		2
sad0_rates		[0xe0] 44100 48000 88200
sad0_bits		[0x20000] 16
htpc ~ # speaker-test -c 8 -t wav

speaker-test 1.0.23

Playback device is default
Stream parameters are 48000Hz, S16_LE, 8 channels
WAV file(s)
Channels count (8) not available for playbacks: Invalid argument
Setting of hwparams failed: Invalid argument

> 
>> You can see my whole alsa info (including it actually detecting the hardware can do 7.1 [note Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP]) here: http://www.alsa-project.org/db/?f=5b55a63fea6580dfcbf1a85c7c734f977df798f1
> 
> This is the Intel HDMI port's audio capability and is always
> 8-channels. In contrast the ELD describes how many speakers (and hence
> channels) are attached to the HDMI sink device (TX-SR607 in your case).
> 
>> Is this a known problem?
>> 
>> My machine specs are as follows:
>> 
>> Intel i3 2100T
>> MSI H67MA-E45 (with Realtek ALC892 audio chip)
>> 
>> I'm using HDMI output only.
> 
> Will you try the above workaround command first? For the long term
> solution, if you are ready to compile new kernels, I can send you the
> patch for testing.

I'm running gentoo, so I compile kernels regularly :)

Jeremy

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HDMI Audio Channels mis-detected on i915
  2011-05-23 13:39   ` Jeremy Bush
@ 2011-05-23 14:08     ` Jeremy Bush
  0 siblings, 0 replies; 5+ messages in thread
From: Jeremy Bush @ 2011-05-23 14:08 UTC (permalink / raw)
  To: intel-gfx; +Cc: Wu Fengguang

More info below:

On May 23, 2011, at 8:39 AM, Jeremy Bush wrote:

> 
> On May 23, 2011, at 8:32 AM, Wu Fengguang wrote:
> 
>> Hi Jeremy,
>> 
>>> I have my machine hooked up to an Onkyo TX-SR607 7.2-Channel receiver. Yet when the machine boots,  HDMI detection mis-detects the hardware on the other end of the HDMI cable:
>>> 
>>> [ 2.090473] HDMI: detected monitor at connection type HDMI
>>> [ 2.090475] HDMI: available speakers: FL/FR
>>> [ 2.090477] HDMI: supports coding type LPCM: channels = 2, rates = 44100 48000 88200, bits = 16
>>> [ 2.090480] HDMI hot plug event: Pin=6 Presence_Detect=1 ELD_Valid=1
>> 
>> That information is filled by BIOS or VBIOS. There are 3 possibilities
>> 1) BIOS provides some dumb EDID-Like Data (ELD) regardless of the HDMI sink
>> 2) BIOS does not parse EDID correctly
>> 3) your TX-SR607 EDID data is broken
>> 
>> I'm writing a drm patch to do ELD for audio in the graphics driver,
>> which will address problems caused by (1) and (2). I've done the
>> scratch patch, but will need more tests before sending it out.
>> 
>> For now you may still manually correct ELD with this command:
>> 
>>       echo speakers 0 > '/proc/asound/card0/eld#3.0'
>> 
>> By clearing the speakers setting, the audio driver will assume your
>> HDMI sink supports all speakers.
> 
> 
> Hrm, just tried that, but speaker-test is still failing:
> 
> htpc ~ # echo speakers 0 > /proc/asound/card1/eld#3.0 
> htpc ~ # cat /proc/asound/card1/eld#3.0 
> monitor_present		1
> eld_valid		1
> monitor_name		
> connection_type		HDMI
> eld_version		[0x2] CEA-861D or below
> edid_version		[0x3] CEA-861-B, C or D
> manufacture_id		0x0
> product_id		0x0
> port_id			0x0
> support_hdcp		1
> support_ai		0
> audio_sync_delay	0
> speakers		[0x0]
> sad_count		1
> sad0_coding_type	[0x1] LPCM
> sad0_channels		2
> sad0_rates		[0xe0] 44100 48000 88200
> sad0_bits		[0x20000] 16
> htpc ~ # speaker-test -c 8 -t wav
> 
> speaker-test 1.0.23
> 
> Playback device is default
> Stream parameters are 48000Hz, S16_LE, 8 channels
> WAV file(s)
> Channels count (8) not available for playbacks: Invalid argument
> Setting of hwparams failed: Invalid argument

Setting sad0_channels to 8 makes speaker-test work. I'm remoting in via ssh right now, so I'll try more tests when I get home.

> 
>> 
>>> You can see my whole alsa info (including it actually detecting the hardware can do 7.1 [note Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP]) here: http://www.alsa-project.org/db/?f=5b55a63fea6580dfcbf1a85c7c734f977df798f1
>> 
>> This is the Intel HDMI port's audio capability and is always
>> 8-channels. In contrast the ELD describes how many speakers (and hence
>> channels) are attached to the HDMI sink device (TX-SR607 in your case).
>> 
>>> Is this a known problem?
>>> 
>>> My machine specs are as follows:
>>> 
>>> Intel i3 2100T
>>> MSI H67MA-E45 (with Realtek ALC892 audio chip)
>>> 
>>> I'm using HDMI output only.
>> 
>> Will you try the above workaround command first? For the long term
>> solution, if you are ready to compile new kernels, I can send you the
>> patch for testing.
> 
> I'm running gentoo, so I compile kernels regularly :)
> 
> Jeremy

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: HDMI Audio Channels mis-detected on i915
  2011-05-23 13:32 ` Wu Fengguang
  2011-05-23 13:39   ` Jeremy Bush
@ 2011-05-23 23:29   ` Jeremy Bush
  1 sibling, 0 replies; 5+ messages in thread
From: Jeremy Bush @ 2011-05-23 23:29 UTC (permalink / raw)
  To: Wu Fengguang; +Cc: intel-gfx

Hi Fengguang- 

On May 23, 2011, at 8:32 AM, Wu Fengguang wrote:

> Hi Jeremy,
> 
>> I have my machine hooked up to an Onkyo TX-SR607 7.2-Channel receiver. Yet when the machine boots,  HDMI detection mis-detects the hardware on the other end of the HDMI cable:
>> 
>> [ 2.090473] HDMI: detected monitor at connection type HDMI
>> [ 2.090475] HDMI: available speakers: FL/FR
>> [ 2.090477] HDMI: supports coding type LPCM: channels = 2, rates = 44100 48000 88200, bits = 16
>> [ 2.090480] HDMI hot plug event: Pin=6 Presence_Detect=1 ELD_Valid=1
> 
> That information is filled by BIOS or VBIOS. There are 3 possibilities
> 1) BIOS provides some dumb EDID-Like Data (ELD) regardless of the HDMI sink
> 2) BIOS does not parse EDID correctly
> 3) your TX-SR607 EDID data is broken
> 
> I'm writing a drm patch to do ELD for audio in the graphics driver,
> which will address problems caused by (1) and (2). I've done the
> scratch patch, but will need more tests before sending it out.
> 
> For now you may still manually correct ELD with this command:
> 
>        echo speakers 0 > '/proc/asound/card0/eld#3.0'
> 
> By clearing the speakers setting, the audio driver will assume your
> HDMI sink supports all speakers.

This worked. I also had to adjust the sad0_channels key. I was able to do speaker-test -c 8 and play 7.1 audio without bitstreaming.

> 
>> Is this a known problem?
>> 
>> My machine specs are as follows:
>> 
>> Intel i3 2100T
>> MSI H67MA-E45 (with Realtek ALC892 audio chip)
>> 
>> I'm using HDMI output only.
> 
> Will you try the above workaround command first? For the long term
> solution, if you are ready to compile new kernels, I can send you the
> patch for testing.

Please send it over :)

Thanks for the help,

Jeremy

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-05-23 23:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-21  1:06 HDMI Audio Channels mis-detected on i915 Jeremy Bush
2011-05-23 13:32 ` Wu Fengguang
2011-05-23 13:39   ` Jeremy Bush
2011-05-23 14:08     ` Jeremy Bush
2011-05-23 23:29   ` Jeremy Bush

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.