From: "Guido Günther" <guido.gunther@puri.sm>
To: David Heidelberg <david@ixit.cz>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Conor Dooley <conor+dt@kernel.org>, - <kernel@puri.sm>,
alsa-devel@alsa-project.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4] dt-bindings: sound: gtm601: convert to YAML
Date: Mon, 31 Jul 2023 14:11:13 +0200 [thread overview]
Message-ID: <ZMek4XHZQ/HVahKV@qwark.sigxcpu.org> (raw)
In-Reply-To: <20230730191742.117013-1-david@ixit.cz>
Hi,
On Sun, Jul 30, 2023 at 10:17:42PM +0300, David Heidelberg wrote:
> Convert GTM601 binding to the YAML format.
>
> Signed-off-by: David Heidelberg <david@ixit.cz>
> ---
> v4:
> - added missing required property
> v3:
> - incorporated feedback from Krzysztof
> v2:
> - add #sound-dai-cells
> - put kernel@puri.sm into maintainers
>
> .../devicetree/bindings/sound/gtm601.txt | 19 ---------
> .../bindings/sound/option,gtm601.yaml | 40 +++++++++++++++++++
> 2 files changed, 40 insertions(+), 19 deletions(-)
> delete mode 100644 Documentation/devicetree/bindings/sound/gtm601.txt
> create mode 100644 Documentation/devicetree/bindings/sound/option,gtm601.yaml
>
> diff --git a/Documentation/devicetree/bindings/sound/gtm601.txt b/Documentation/devicetree/bindings/sound/gtm601.txt
> deleted file mode 100644
> index efa32a486c4a..000000000000
> --- a/Documentation/devicetree/bindings/sound/gtm601.txt
> +++ /dev/null
> @@ -1,19 +0,0 @@
> -GTM601 UMTS modem audio interface CODEC
> -
> -This device has no configuration interface. The sample rate and channels are
> -based on the compatible string
> - "option,gtm601" = 8kHz mono
> - "broadmobi,bm818" = 48KHz stereo
> -
> -Required properties:
> -
> - - compatible : one of
> - "option,gtm601"
> - "broadmobi,bm818"
> -
> -
> -Example:
> -
> -codec: gtm601_codec {
> - compatible = "option,gtm601";
> -};
> diff --git a/Documentation/devicetree/bindings/sound/option,gtm601.yaml b/Documentation/devicetree/bindings/sound/option,gtm601.yaml
> new file mode 100644
> index 000000000000..69c2ccc79dc5
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/sound/option,gtm601.yaml
> @@ -0,0 +1,40 @@
> +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/sound/option,gtm601.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: GTM601 UMTS modem audio interface CODEC
> +
> +maintainers:
> + - kernel@puri.sm
> +
> +description: >
> + This device has no configuration interface. The sample rate and channels are
> + based on the compatible string
> +
> +properties:
> + compatible:
> + oneOf:
> + - items: # 48 kHz stereo
> + - const: broadmobi,bm818
> + - const: option,gtm601
> + - const: option,gtm601 # 8 kHz mono
This looks good to me. I just wonder if it makes sense to use a description
instead of comments to make the sampling rate/channel requirements a bit
more obvious:
- description: Broadmobi BM818 (48kHz stereo)
items:
- const: broadmobi,bm818
- const: option,gtm601
- description: Option GTM601 audio code (8kHz mono)
const: option,gtm601
Cheers,
-- Guido
> +
> + '#sound-dai-cells':
> + const: 0
> +
> +required:
> + - compatible
> +
> +allOf:
> + - $ref: dai-common.yaml#
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + codec {
> + compatible = "option,gtm601";
> + #sound-dai-cells = <0>;
> + };
> --
> 2.40.1
>
next prev parent reply other threads:[~2023-07-31 12:11 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-30 19:17 David Heidelberg
2023-07-30 19:20 ` Krzysztof Kozlowski
2023-07-31 12:11 ` Guido Günther [this message]
2023-07-31 16:00 ` 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=ZMek4XHZQ/HVahKV@qwark.sigxcpu.org \
--to=guido.gunther@puri.sm \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=david@ixit.cz \
--cc=devicetree@vger.kernel.org \
--cc=kernel@puri.sm \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®