All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Jean-Francois Moine <moinejf@free.fr>
Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org,
	Takashi Iwai <tiwai@suse.de>, Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] ASoC: generic: Add generic DT based simple codec
Date: Mon, 23 Sep 2013 15:19:56 -0600	[thread overview]
Message-ID: <5240B07C.6080404@wwwdotorg.org> (raw)
In-Reply-To: <20130919105437.75e0f0a3@armhf>

On 09/19/2013 02:54 AM, Jean-Francois Moine wrote:
> This patch adds a simple sound codec which is described by the DT.
> This codec may be used when no specific codec action is needed.

> diff --git a/Documentation/devicetree/bindings/sound/simple-codec.txt b/Documentation/devicetree/bindings/sound/simple-codec.txt

> +Device-Tree bindings for the simple codec
> +
> +Required properties:
> +- compatible: should be "linux,simple-codec".

We shouldn't have any Linux-specific bindings. It might be reasonable to
define a binding for a "simple CODEC", but there's no reason it should
be Linux-specific.

> +- dai-name: name of the codec

That should be internal to the driver; it's Linux-specific.

> +Optional properties:
> +- capture: information about capture
> +- playback: information about playback
> +At least one of the 'capture' or 'playback' nodes must be present.

Judging by the example, those are nodes not properties.

> +Child 'capture' and 'playback' required properties:
> +- stream-name: name of the stream

Stream name is also probably too Linux-specific.

> +- formats: list of the supported formats (see below)
> +- rates: list of the supported rates (see below)
> +- #channels: minimum and maximum numbers of channels
> +
> +Formats:
> +	"s8"
> +	"u8"

I think the binding should specify on-the-wire formats, not in-memory
formats. For example, if this binding is used to represent an I2S CODEC,
it's more important to know whether it supports left-justified,
right-justified, DSP mode, etc., and the max number of bits (or perhaps
a list of supported numbers of bits) per channel in each case.

WARNING: multiple messages have this Message-ID (diff)
From: swarren@wwwdotorg.org (Stephen Warren)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ASoC: generic: Add generic DT based simple codec
Date: Mon, 23 Sep 2013 15:19:56 -0600	[thread overview]
Message-ID: <5240B07C.6080404@wwwdotorg.org> (raw)
In-Reply-To: <20130919105437.75e0f0a3@armhf>

On 09/19/2013 02:54 AM, Jean-Francois Moine wrote:
> This patch adds a simple sound codec which is described by the DT.
> This codec may be used when no specific codec action is needed.

> diff --git a/Documentation/devicetree/bindings/sound/simple-codec.txt b/Documentation/devicetree/bindings/sound/simple-codec.txt

> +Device-Tree bindings for the simple codec
> +
> +Required properties:
> +- compatible: should be "linux,simple-codec".

We shouldn't have any Linux-specific bindings. It might be reasonable to
define a binding for a "simple CODEC", but there's no reason it should
be Linux-specific.

> +- dai-name: name of the codec

That should be internal to the driver; it's Linux-specific.

> +Optional properties:
> +- capture: information about capture
> +- playback: information about playback
> +At least one of the 'capture' or 'playback' nodes must be present.

Judging by the example, those are nodes not properties.

> +Child 'capture' and 'playback' required properties:
> +- stream-name: name of the stream

Stream name is also probably too Linux-specific.

> +- formats: list of the supported formats (see below)
> +- rates: list of the supported rates (see below)
> +- #channels: minimum and maximum numbers of channels
> +
> +Formats:
> +	"s8"
> +	"u8"

I think the binding should specify on-the-wire formats, not in-memory
formats. For example, if this binding is used to represent an I2S CODEC,
it's more important to know whether it supports left-justified,
right-justified, DSP mode, etc., and the max number of bits (or perhaps
a list of supported numbers of bits) per channel in each case.

  parent reply	other threads:[~2013-09-23 21:20 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-19  8:54 [PATCH] ASoC: generic: Add generic DT based simple codec Jean-Francois Moine
2013-09-19  8:54 ` Jean-Francois Moine
2013-09-19 10:40 ` Mark Brown
2013-09-19 10:40   ` Mark Brown
     [not found]   ` <20130919104028.GI21013-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2013-09-19 17:34     ` Jean-Francois Moine
2013-09-19 17:34       ` Jean-Francois Moine
2013-09-19 17:49       ` Russell King - ARM Linux
2013-09-19 17:49         ` Russell King - ARM Linux
     [not found]         ` <20130919174952.GC12758-l+eeeJia6m9vn6HldHNs0ANdhmdF6hFW@public.gmane.org>
2013-09-19 18:12           ` Mark Brown
2013-09-19 18:12             ` Mark Brown
2013-09-19 18:05       ` Mark Brown
2013-09-19 18:05         ` Mark Brown
2013-09-23 21:19 ` Stephen Warren [this message]
2013-09-23 21:19   ` Stephen Warren
     [not found]   ` <5240B07C.6080404-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2013-09-23 23:26     ` Mark Brown
2013-09-23 23:26       ` Mark Brown
     [not found]       ` <20130923232648.GL21013-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2013-09-26 23:16         ` Stephen Warren
2013-09-26 23:16           ` Stephen Warren
2013-09-27  2:57     ` Rob Herring
2013-09-27  2:57       ` Rob Herring
2013-09-27  9:55       ` Mark Brown
2013-09-27  9:55         ` Mark Brown
     [not found]       ` <CAL_JsqKmfurrCqEYRNqcLRZMU-VjPin2dvK1Q6CMcK4i=+x-8w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-09-30 16:49         ` Stephen Warren
2013-09-30 16:49           ` Stephen Warren
     [not found]           ` <5249AB82.60701-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2013-09-30 17:43             ` Mark Brown
2013-09-30 17:43               ` 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=5240B07C.6080404@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=moinejf@free.fr \
    --cc=tiwai@suse.de \
    /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.