All of lore.kernel.org
 help / color / mirror / Atom feed
From: Herve Codina <herve.codina@bootlin.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
	linux-kernel@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>,
	Takashi Iwai <tiwai@suse.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Rob Herring <robh+dt@kernel.org>,
	linux-gpio@vger.kernel.org, Mark Brown <broonie@kernel.org>,
	Christophe Leroy <christophe.leroy@csgroup.eu>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>
Subject: Re: [PATCH 1/3] dt-bindings: sound: Add Renesas IDT821034 codec
Date: Wed, 11 Jan 2023 17:55:27 +0100	[thread overview]
Message-ID: <20230111175527.10289d16@bootlin.com> (raw)
In-Reply-To: <c4497bde-c1e0-1efc-7a46-233495f7760b@linaro.org>

On Wed, 11 Jan 2023 17:28:11 +0100
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:

> On 11/01/2023 14:49, Herve Codina wrote:
> > The Renesas IDT821034 codec is a quad PCM codec with
> > programmable gain.
> > 
> > Signed-off-by: Herve Codina <herve.codina@bootlin.com>
> > ---
> >  .../bindings/sound/renesas,idt821034.yaml     | 97 +++++++++++++++++++
> >  1 file changed, 97 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > 
> > diff --git a/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml b/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > new file mode 100644
> > index 000000000000..2c29b770e3f7
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > @@ -0,0 +1,97 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/sound/renesas,idt821034.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Renesas IDT821034 codec device
> > +
> > +maintainers:
> > +  - Herve Codina <herve.codina@bootlin.com>
> > +
> > +description: |
> > +  The IDT821034 codec is a four channel PCM codec with onchip filters and
> > +  programmable gain setting.
> > +
> > +  The time-slots used by the codec must be set and so, the properties
> > +  'dai-tdm-slot-num', 'dai-tdm-slot-width', 'dai-tdm-slot-tx-mask' and
> > +  'dai-tdm-slot-rx-mask' must be present in the ALSA sound card node for
> > +  sub-nodes that involve the codec. The codec uses one 8bit time-slot per
> > +  channel.
> > +  'dai-tdm-tdm-slot-with' must be set to 8.
> > +
> > +  The IDT821034 codec also supports 5 gpios (SLIC signals) per channel.
> > +
> > +allOf:
> > +  - $ref: /schemas/spi/spi-peripheral-props.yaml#
> > +  - $ref: /schemas/gpio/gpio.yaml#  
> 
> This one is never needed. Drop.

Ok, I will drop it in v2.

> 
> > +  - $ref: dai-common.yaml#
> > +
> > +properties:
> > +  compatible:
> > +    const: renesas,idt821034
> > +
> > +  reg:
> > +    description:
> > +      SPI device address.
> > +    maxItems: 1
> > +
> > +  spi-max-frequency:
> > +    maximum: 8192000
> > +
> > +  spi-cpha: true
> > +
> > +  '#sound-dai-cells':
> > +    const: 0
> > +
> > +  '#gpio-cells':
> > +    const: 2
> > +
> > +  gpio-controller: true
> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - spi-cpha
> > +  - '#sound-dai-cells'
> > +  - gpio-controller
> > +  - '#gpio-cells'
> > +
> > +additionalProperties: false  
> 
> This should be rather unevaluatedProperties: false, so other properties
> from spi-props and dai-common will work.

Ok, I will change in v2.

> 
> > +
> > +examples:
> > +  - |
> > +    #include <dt-bindings/gpio/gpio.h>
> > +    spi0 {
> > +        #address-cells = <1>;
> > +        #size-cells = <0>;
> > +        codec: idt821034@0 {  
> 
> Node names should be generic, so "audio-codec"
> https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation
> 
> > +            compatible = "renesas,idt821034";
> > +            reg = <0>;
> > +            spi-max-frequency = <8192000>;
> > +            spi-cpha;
> > +            #sound-dai-cells = <0>;
> > +            gpio-controller;
> > +            #gpio-cells = <2>;
> > +        };
> > +    };
> > +    sound {
> > +        compatible = "simple-audio-card";  
> 
> Drop sound{} node. Not relevant to the case here and it's the same in
> every case of audio codec... unless something here is specific. But even
> the dai-tdm properties are sound card specific.

Indeed, I wanted to show the dai-tdm properties.
But ok, I will drop the node.

> 
> 
> Best regards,
> Krzysztof
> 

Thanks for the review.

Best regards,
Hervé

-- 
Hervé Codina, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

WARNING: multiple messages have this Message-ID (diff)
From: Herve Codina <herve.codina@bootlin.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>, Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
	Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	alsa-devel@alsa-project.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, linux-gpio@vger.kernel.org,
	Christophe Leroy <christophe.leroy@csgroup.eu>,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Subject: Re: [PATCH 1/3] dt-bindings: sound: Add Renesas IDT821034 codec
Date: Wed, 11 Jan 2023 17:55:27 +0100	[thread overview]
Message-ID: <20230111175527.10289d16@bootlin.com> (raw)
In-Reply-To: <c4497bde-c1e0-1efc-7a46-233495f7760b@linaro.org>

On Wed, 11 Jan 2023 17:28:11 +0100
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> wrote:

> On 11/01/2023 14:49, Herve Codina wrote:
> > The Renesas IDT821034 codec is a quad PCM codec with
> > programmable gain.
> > 
> > Signed-off-by: Herve Codina <herve.codina@bootlin.com>
> > ---
> >  .../bindings/sound/renesas,idt821034.yaml     | 97 +++++++++++++++++++
> >  1 file changed, 97 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > 
> > diff --git a/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml b/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > new file mode 100644
> > index 000000000000..2c29b770e3f7
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/sound/renesas,idt821034.yaml
> > @@ -0,0 +1,97 @@
> > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/sound/renesas,idt821034.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Renesas IDT821034 codec device
> > +
> > +maintainers:
> > +  - Herve Codina <herve.codina@bootlin.com>
> > +
> > +description: |
> > +  The IDT821034 codec is a four channel PCM codec with onchip filters and
> > +  programmable gain setting.
> > +
> > +  The time-slots used by the codec must be set and so, the properties
> > +  'dai-tdm-slot-num', 'dai-tdm-slot-width', 'dai-tdm-slot-tx-mask' and
> > +  'dai-tdm-slot-rx-mask' must be present in the ALSA sound card node for
> > +  sub-nodes that involve the codec. The codec uses one 8bit time-slot per
> > +  channel.
> > +  'dai-tdm-tdm-slot-with' must be set to 8.
> > +
> > +  The IDT821034 codec also supports 5 gpios (SLIC signals) per channel.
> > +
> > +allOf:
> > +  - $ref: /schemas/spi/spi-peripheral-props.yaml#
> > +  - $ref: /schemas/gpio/gpio.yaml#  
> 
> This one is never needed. Drop.

Ok, I will drop it in v2.

> 
> > +  - $ref: dai-common.yaml#
> > +
> > +properties:
> > +  compatible:
> > +    const: renesas,idt821034
> > +
> > +  reg:
> > +    description:
> > +      SPI device address.
> > +    maxItems: 1
> > +
> > +  spi-max-frequency:
> > +    maximum: 8192000
> > +
> > +  spi-cpha: true
> > +
> > +  '#sound-dai-cells':
> > +    const: 0
> > +
> > +  '#gpio-cells':
> > +    const: 2
> > +
> > +  gpio-controller: true
> > +
> > +required:
> > +  - compatible
> > +  - reg
> > +  - spi-cpha
> > +  - '#sound-dai-cells'
> > +  - gpio-controller
> > +  - '#gpio-cells'
> > +
> > +additionalProperties: false  
> 
> This should be rather unevaluatedProperties: false, so other properties
> from spi-props and dai-common will work.

Ok, I will change in v2.

> 
> > +
> > +examples:
> > +  - |
> > +    #include <dt-bindings/gpio/gpio.h>
> > +    spi0 {
> > +        #address-cells = <1>;
> > +        #size-cells = <0>;
> > +        codec: idt821034@0 {  
> 
> Node names should be generic, so "audio-codec"
> https://devicetree-specification.readthedocs.io/en/latest/chapter2-devicetree-basics.html#generic-names-recommendation
> 
> > +            compatible = "renesas,idt821034";
> > +            reg = <0>;
> > +            spi-max-frequency = <8192000>;
> > +            spi-cpha;
> > +            #sound-dai-cells = <0>;
> > +            gpio-controller;
> > +            #gpio-cells = <2>;
> > +        };
> > +    };
> > +    sound {
> > +        compatible = "simple-audio-card";  
> 
> Drop sound{} node. Not relevant to the case here and it's the same in
> every case of audio codec... unless something here is specific. But even
> the dai-tdm properties are sound card specific.

Indeed, I wanted to show the dai-tdm properties.
But ok, I will drop the node.

> 
> 
> Best regards,
> Krzysztof
> 

Thanks for the review.

Best regards,
Hervé

-- 
Hervé Codina, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2023-01-11 16:56 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-11 13:49 [PATCH 0/3] Add the Renesas IDT821034 codec support Herve Codina
2023-01-11 13:49 ` Herve Codina
2023-01-11 13:49 ` [PATCH 1/3] dt-bindings: sound: Add Renesas IDT821034 codec Herve Codina
2023-01-11 13:49   ` Herve Codina
2023-01-11 16:28   ` Krzysztof Kozlowski
2023-01-11 16:28     ` Krzysztof Kozlowski
2023-01-11 16:55     ` Herve Codina [this message]
2023-01-11 16:55       ` Herve Codina
2023-01-11 13:49 ` [PATCH 2/3] ASoC: codecs: Add support for the " Herve Codina
2023-01-11 13:49   ` Herve Codina
2023-01-11 14:09   ` Mark Brown
2023-01-11 14:09     ` Mark Brown
2023-01-11 16:40     ` Herve Codina
2023-01-11 16:40       ` Herve Codina
2023-01-11 17:57       ` Mark Brown
2023-01-11 17:57         ` Mark Brown
2023-01-13  8:04         ` Herve Codina
2023-01-13  8:04           ` Herve Codina
2023-01-13 12:59           ` Mark Brown
2023-01-13 12:59             ` Mark Brown
2023-01-13 14:19             ` Herve Codina
2023-01-13 14:19               ` Herve Codina
2023-01-11 13:49 ` [PATCH 3/3] MAINTAINERS: add the Renesas IDT821034 codec entry Herve Codina
2023-01-11 13:49   ` Herve Codina

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=20230111175527.10289d16@bootlin.com \
    --to=herve.codina@bootlin.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=brgl@bgdev.pl \
    --cc=broonie@kernel.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=devicetree@vger.kernel.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=krzysztof.kozlowski@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=tiwai@suse.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.