All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Eric Millbrandt <emillbrandt@dekaresearch.com>
Cc: alsa-devel@alsa-project.org,
	Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Grant Likely <grant.likely@secretlab.ca>,
	Anatolij Gustschin <agust@denx.de>,
	linuxppc-dev@lists.ozlabs.org, Liam Girdwood <lrg@ti.com>
Subject: Re: [PATCH 4/5] arch/powerpc/boot/dts pcm030 add mpc5200-soc-audio node
Date: Tue, 11 Sep 2012 20:41:47 -0600	[thread overview]
Message-ID: <504FF66B.8020009@wwwdotorg.org> (raw)
In-Reply-To: <1347416089-23393-5-git-send-email-emillbrandt@dekaresearch.com>

On 09/11/2012 08:14 PM, Eric Millbrandt wrote:
> Describe the audio codec on the pcm030 baseboard.

> +++ b/arch/powerpc/boot/dts/pcm030.dts

> +	sound {
> +		compatible = "fsl,mpc5200b-soc-audio","fsl,mpc5200-soc-audio";
> +		card-name = "pcm030";
> +		audio-platform = <&audio_platform>;
> +		number-of-dais = <2>;
> +
> +		analog@0 {

Purely from a DT perspective (i.e. I didn't look at the code that parses
this), you don't need to include the "@0" and "@1" in the node names,
because the two node names "analog" and "digital" are already unique.

However, in general I can see that you might want multiple analog DAIs.
There are a couple choices for differentiating the node names in that case:

1) If you want to use the "@0" unit address syntax in the node names to
differentiate them, each child node needs a reg property containing the
same value, and the parent node needs properties #address-cells=<1>,
#size-cells=<0>;

2) Or, since this is within an individual device binding rather than
something within a standardized bus, you can simply choose to make the
node names unique in some other way, such as "analog0", "analog1", i.e.
without the "@"; I believe the "@" syntax would be explicitly reserved
for representing a unit address as in (1).

Of course, I could be wrong about this assertion that the "@n" is
reserved for the unit address even with the privacy of an individual
binding; it'd be best to validate it by posting to the
devicetree-discuss mailing list.

> +			stream-name = "AC97 Analog";
> +			codec-name = "wm9712-codec.0";
> +			codec-dai-name = "wm9712-hifi";
> +			cpu-dai-name = "mpc5200-psc-ac97.0";
> +		};
> +
> +		digital@1 {
> +			stream-name = "AC97 IEC958";
> +			codec-name = "wm9712-codec.0";
> +			codec-dai-name = "wm9712-aux";
> +			cpu-dai-name = "mpc5200-psc-ac97.0";
> +		};
> +	};
>  };

WARNING: multiple messages have this Message-ID (diff)
From: Stephen Warren <swarren@wwwdotorg.org>
To: Eric Millbrandt <emillbrandt@dekaresearch.com>
Cc: alsa-devel@alsa-project.org,
	Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Anatolij Gustschin <agust@denx.de>,
	linuxppc-dev@lists.ozlabs.org, Liam Girdwood <lrg@ti.com>
Subject: Re: [alsa-devel] [PATCH 4/5] arch/powerpc/boot/dts pcm030 add mpc5200-soc-audio node
Date: Tue, 11 Sep 2012 20:41:47 -0600	[thread overview]
Message-ID: <504FF66B.8020009@wwwdotorg.org> (raw)
In-Reply-To: <1347416089-23393-5-git-send-email-emillbrandt@dekaresearch.com>

On 09/11/2012 08:14 PM, Eric Millbrandt wrote:
> Describe the audio codec on the pcm030 baseboard.

> +++ b/arch/powerpc/boot/dts/pcm030.dts

> +	sound {
> +		compatible = "fsl,mpc5200b-soc-audio","fsl,mpc5200-soc-audio";
> +		card-name = "pcm030";
> +		audio-platform = <&audio_platform>;
> +		number-of-dais = <2>;
> +
> +		analog@0 {

Purely from a DT perspective (i.e. I didn't look at the code that parses
this), you don't need to include the "@0" and "@1" in the node names,
because the two node names "analog" and "digital" are already unique.

However, in general I can see that you might want multiple analog DAIs.
There are a couple choices for differentiating the node names in that case:

1) If you want to use the "@0" unit address syntax in the node names to
differentiate them, each child node needs a reg property containing the
same value, and the parent node needs properties #address-cells=<1>,
#size-cells=<0>;

2) Or, since this is within an individual device binding rather than
something within a standardized bus, you can simply choose to make the
node names unique in some other way, such as "analog0", "analog1", i.e.
without the "@"; I believe the "@" syntax would be explicitly reserved
for representing a unit address as in (1).

Of course, I could be wrong about this assertion that the "@n" is
reserved for the unit address even with the privacy of an individual
binding; it'd be best to validate it by posting to the
devicetree-discuss mailing list.

> +			stream-name = "AC97 Analog";
> +			codec-name = "wm9712-codec.0";
> +			codec-dai-name = "wm9712-hifi";
> +			cpu-dai-name = "mpc5200-psc-ac97.0";
> +		};
> +
> +		digital@1 {
> +			stream-name = "AC97 IEC958";
> +			codec-name = "wm9712-codec.0";
> +			codec-dai-name = "wm9712-aux";
> +			cpu-dai-name = "mpc5200-psc-ac97.0";
> +		};
> +	};
>  };

  reply	other threads:[~2012-09-12  2:41 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-12  2:14 [RFC PATCH 0/5] mpc5200 asoc fixups Eric Millbrandt
2012-09-12  2:14 ` [PATCH 1/5] ASoC: fsl: mpc5200 multi-codec fixups Eric Millbrandt
2012-09-12  3:04   ` Mark Brown
2012-09-12  3:04     ` Mark Brown
2012-09-12 14:29     ` Eric Millbrandt
2012-09-12 14:29       ` Eric Millbrandt
2012-09-12  2:14 ` [PATCH 2/5] ASoC: fsl: mpc5200 combine psc_dma platform data Eric Millbrandt
2012-09-12 13:54   ` Mark Brown
2012-09-12 13:54     ` Mark Brown
2012-09-12 17:15     ` Eric Millbrandt
2012-09-12 17:15       ` [alsa-devel] " Eric Millbrandt
2012-09-12  2:14 ` [PATCH 3/5] ASoC: fsl: mpc5200-soc-audio driver Eric Millbrandt
2012-09-12  2:33   ` Stephen Warren
2012-09-12  2:33     ` [alsa-devel] " Stephen Warren
2012-09-12  3:11   ` Mark Brown
2012-09-12  3:11     ` Mark Brown
2012-09-12  2:14 ` [PATCH 4/5] arch/powerpc/boot/dts pcm030 add mpc5200-soc-audio node Eric Millbrandt
2012-09-12  2:41   ` Stephen Warren [this message]
2012-09-12  2:41     ` [alsa-devel] " Stephen Warren
2012-09-12  3:17   ` Mark Brown
2012-09-12  3:17     ` Mark Brown
2012-09-12  2:14 ` [PATCH 5/5] ASoC: fsl: mpc5200 remove pcm030 and efika audio fabric Eric Millbrandt
2012-09-12  3:20   ` Mark Brown
2012-09-12  3:20     ` Mark Brown
2012-09-12 14:05     ` Eric Millbrandt
2012-09-12 14:05       ` Eric Millbrandt
2012-09-13  4:27       ` Mark Brown
2012-09-13  4:27         ` Mark Brown

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=504FF66B.8020009@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=agust@denx.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=emillbrandt@dekaresearch.com \
    --cc=grant.likely@secretlab.ca \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=lrg@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.