All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joachim Eastwood <manabian@gmail.com>
To: Jyri Sarha <jsarha@ti.com>
Cc: alsa-devel@alsa-project.org, linux-fbdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-omap@vger.kernel.org,
	liam.r.girdwood@linux.intel.com, detheridge@ti.com,
	broonie@kernel.org, peter.ujfalusi@ti.com,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	Benoit Cousson <bcousson@baylibre.com>
Subject: Re: [alsa-devel] [PATCH 00/19] Rework OMAP4+ HDMI audio support
Date: Wed, 14 May 2014 18:25:47 +0200	[thread overview]
Message-ID: <CAGhQ9VzkGDPiQF7TiqiMgZY_oc9dyrW66yGsZR6ei2ejX-EXcw@mail.gmail.com> (raw)
In-Reply-To: <53733F2E.4030803@ti.com>

On 14 May 2014 12:02, Jyri Sarha <jsarha@ti.com> wrote:
> On 05/13/2014 12:13 AM, Joachim Eastwood wrote:
>>
>> On 12 May 2014 11:12, Jyri Sarha <jsarha@ti.com> wrote:
>
> ...
>
>>
>> hey, this worked straight away :)
>>
>> But there seems to be something wrong with the channel mapping.
>>
>> For stereo (speaker-test -c 2) the mapping is correct.
>>
>> But for -c 4 and -c 8 it gets weird:
>> speaker-test -c 4 -s X # where X is 1-4
>> 1: Front Left is Rear Left
>> 2: Front Right is Rear Right
>> 3: Rear Right is Front Right
>> 4: Rear Left is Front Left
>>
>> speaker-test -c 8 -s X # where X is 1-8
>> 1: Front Left is Rear Left
>> 2: Center is Rear Left
>> 3: Front Right is Rear Right
>> 4: Side Right is Front Right
>> 5: Rear Right is silent
>> 6: Rear Left is Center
>> 7: Side Left is Front Left
>> 8: LFE - Rear Right
>>
>> I think you need to check what channel order ALSA expects. I believe
>> speaker-test does the right thing on my HTPC normally connected to my
>> receiver.
>>
>
> I checked the implementation and there was indeed something weird there, but
> the implementation can not explain the FL and FR channels jumping around. FL
> and FL should always be the first two channels in all configurations and the
> implementation does not touch them.
>
> The implementation uses 8ch HDMI setup for anything above 2ch with "Audio
> InfoFrame Data Byte 4" set to 0x13. According to CEA-861 specs this means
> following channel order: FL, FR, LFE, FC, RL, RR, RLC, RRC
>
> This is a closest match to ALSA 8ch mapping (according to
> sound/core/pcm_lib.c) which is: FL, FR, FC, LFE, RL, RR, SL, SR

hm, okey. I haven't look at the code but it do seem strange. But with
speaker-test -c 4 the front and back are surely swapped here.

I'll do some more testing and also check with my HTPC. btw, I only
have a 5.1 setup over here so I can't test all the discrete channels.

> Current implementation has FLE and FC channels correctly swapped, but it
> shifts them to last two channels and RL, RR, SL, SR are shifted down to fill
> the place. This is all wrong and I'll try to come up with a fix for that.
> Unfortunately I can not test anything beyond 2 ch myself so I would need
> someone to volunteer to test my patch.

I have the dev kit setup up over here so I can test your patches.

regards
Joachim Eastwood

WARNING: multiple messages have this Message-ID (diff)
From: Joachim Eastwood <manabian@gmail.com>
To: Jyri Sarha <jsarha@ti.com>
Cc: alsa-devel@alsa-project.org, linux-fbdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-omap@vger.kernel.org,
	liam.r.girdwood@linux.intel.com, detheridge@ti.com,
	broonie@kernel.org, peter.ujfalusi@ti.com,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	Benoit Cousson <bcousson@baylibre.com>
Subject: Re: [alsa-devel] [PATCH 00/19] Rework OMAP4+ HDMI audio support
Date: Wed, 14 May 2014 16:25:47 +0000	[thread overview]
Message-ID: <CAGhQ9VzkGDPiQF7TiqiMgZY_oc9dyrW66yGsZR6ei2ejX-EXcw@mail.gmail.com> (raw)
In-Reply-To: <53733F2E.4030803@ti.com>

On 14 May 2014 12:02, Jyri Sarha <jsarha@ti.com> wrote:
> On 05/13/2014 12:13 AM, Joachim Eastwood wrote:
>>
>> On 12 May 2014 11:12, Jyri Sarha <jsarha@ti.com> wrote:
>
> ...
>
>>
>> hey, this worked straight away :)
>>
>> But there seems to be something wrong with the channel mapping.
>>
>> For stereo (speaker-test -c 2) the mapping is correct.
>>
>> But for -c 4 and -c 8 it gets weird:
>> speaker-test -c 4 -s X # where X is 1-4
>> 1: Front Left is Rear Left
>> 2: Front Right is Rear Right
>> 3: Rear Right is Front Right
>> 4: Rear Left is Front Left
>>
>> speaker-test -c 8 -s X # where X is 1-8
>> 1: Front Left is Rear Left
>> 2: Center is Rear Left
>> 3: Front Right is Rear Right
>> 4: Side Right is Front Right
>> 5: Rear Right is silent
>> 6: Rear Left is Center
>> 7: Side Left is Front Left
>> 8: LFE - Rear Right
>>
>> I think you need to check what channel order ALSA expects. I believe
>> speaker-test does the right thing on my HTPC normally connected to my
>> receiver.
>>
>
> I checked the implementation and there was indeed something weird there, but
> the implementation can not explain the FL and FR channels jumping around. FL
> and FL should always be the first two channels in all configurations and the
> implementation does not touch them.
>
> The implementation uses 8ch HDMI setup for anything above 2ch with "Audio
> InfoFrame Data Byte 4" set to 0x13. According to CEA-861 specs this means
> following channel order: FL, FR, LFE, FC, RL, RR, RLC, RRC
>
> This is a closest match to ALSA 8ch mapping (according to
> sound/core/pcm_lib.c) which is: FL, FR, FC, LFE, RL, RR, SL, SR

hm, okey. I haven't look at the code but it do seem strange. But with
speaker-test -c 4 the front and back are surely swapped here.

I'll do some more testing and also check with my HTPC. btw, I only
have a 5.1 setup over here so I can't test all the discrete channels.

> Current implementation has FLE and FC channels correctly swapped, but it
> shifts them to last two channels and RL, RR, SL, SR are shifted down to fill
> the place. This is all wrong and I'll try to come up with a fix for that.
> Unfortunately I can not test anything beyond 2 ch myself so I would need
> someone to volunteer to test my patch.

I have the dev kit setup up over here so I can test your patches.

regards
Joachim Eastwood

  reply	other threads:[~2014-05-14 16:25 UTC|newest]

Thread overview: 70+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-12  9:12 [PATCH 00/19] Rework OMAP4+ HDMI audio support Jyri Sarha
2014-05-12  9:12 ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 01/19] ASoC: omap-pcm: Move omap-pcm under include/sound Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 02/19] OMAPDSS: hdmi-common: Add hdmi_dss_audio_from_hw_params() Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 03/19] OMAPDSS: hdmi4: Remove callbacks for an external ASoC DAI driver Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 04/19] OMAPDSS: hdmi4: Integrated ASoC DAI component driver implementation Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
     [not found] ` <cover.1399884780.git.jsarha-l0cyMroinI0@public.gmane.org>
2014-05-12  9:12   ` [PATCH 05/19] OMAPDSS: Kconfig: Add depencies and help section to OMAP4_DSS_HDMI_AUDIO Jyri Sarha
2014-05-12  9:12     ` Jyri Sarha
2014-05-16 10:52     ` Tomi Valkeinen
2014-05-16 10:52       ` Tomi Valkeinen
2014-05-16 11:56       ` Jyri Sarha
2014-05-16 11:56         ` Jyri Sarha
2014-05-12  9:12   ` [PATCH 07/19] OMAPDSS: hdmi5_core: Fix compilation with OMAP5_DSS_HDMI_AUDIO Jyri Sarha
2014-05-12  9:12     ` Jyri Sarha
2014-05-16 10:31     ` Tomi Valkeinen
2014-05-16 10:31       ` Tomi Valkeinen
2014-05-12  9:12   ` [PATCH 13/19] ARM: omap4.dtsi: Add audio related parametes to hdmi node Jyri Sarha
2014-05-12  9:12     ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 06/19] OMAPDSS: hdmi.h: Add HDMI_AUDIO_LAYOUT_6CH enum value Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 08/19] OMAPDSS: hdmi5: Remove callbacks for an external ASoC DAI driver Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 09/19] OMAPDSS: hdmi5: Integrated ASoC DAI component driver implementation Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 10/19] OMAPDSS: Kconfig: Add depencies and help section to OMAP5_DSS_HDMI_AUDIO Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 11/19] ASoC: omap: Remove obsolete HDMI audio code and Kconfig options Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12 17:22   ` Mark Brown
2014-05-12 17:22     ` Mark Brown
2014-05-12  9:12 ` [PATCH 12/19] OMAPDSS: Remove obsolete audio code Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 14/19] ARM: omap4-panda-common.dtsi: Add HDMI audio nodes Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-16 11:04   ` Tomi Valkeinen
2014-05-16 11:04     ` Tomi Valkeinen
2014-05-16 11:08     ` Mark Brown
2014-05-16 11:08       ` Mark Brown
2014-05-12  9:12 ` [PATCH 15/19] ARM: omap5.dtsi: Add audio related parameters to hdmi node Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 16/19] ARM: omap5-uevm.dts: Add hdmi audio related nodes Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 17/19] ARM: omap2plus_defconfig: Build DSS HDMI support for OMAP4 in kernel Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 18/19] ARM: omap2plus_defconfig: Enable OMAP5 HDMI support Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12  9:12 ` [PATCH 19/19] ARM: omap2plus_defconfig: Enable OMAP4+ HDMI audio support Jyri Sarha
2014-05-12  9:12   ` Jyri Sarha
2014-05-12 15:06 ` [PATCH 00/19] Rework " Tony Lindgren
2014-05-12 15:06   ` Tony Lindgren
2014-05-23 11:02   ` Tomi Valkeinen
2014-05-23 11:02     ` Tomi Valkeinen
2014-05-23 14:46     ` Tony Lindgren
2014-05-23 14:46       ` Tony Lindgren
2014-05-12 21:13 ` [alsa-devel] " Joachim Eastwood
2014-05-12 21:13   ` Joachim Eastwood
2014-05-14 10:02   ` Jyri Sarha
2014-05-14 10:02     ` Jyri Sarha
2014-05-14 16:25     ` Joachim Eastwood [this message]
2014-05-14 16:25       ` Joachim Eastwood
2014-05-17  8:51       ` Joachim Eastwood
2014-05-17  8:51         ` Joachim Eastwood
2014-05-17  9:16         ` Joachim Eastwood
2014-05-17  9:16           ` Joachim Eastwood
2014-05-19 14:44           ` Jyri Sarha
2014-05-19 14:44             ` Jyri Sarha

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAGhQ9VzkGDPiQF7TiqiMgZY_oc9dyrW66yGsZR6ei2ejX-EXcw@mail.gmail.com \
    --to=manabian@gmail.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=bcousson@baylibre.com \
    --cc=broonie@kernel.org \
    --cc=detheridge@ti.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jsarha@ti.com \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=linux-fbdev@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=peter.ujfalusi@ti.com \
    --cc=tomi.valkeinen@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.