From: Ryan Lee <[email protected]>
This patch adds dt-bindings information for Analog Devices MAX98363
SoundWire Amplifier.
Signed-off-by: Ryan Lee <[email protected]>
---
.../bindings/sound/adi,max98363.yaml | 53 +++++++++++++++++++
1 file changed, 53 insertions(+)
create mode 100644 Documentation/devicetree/bindings/sound/adi,max98363.yaml
diff --git a/Documentation/devicetree/bindings/sound/adi,max98363.yaml b/Documentation/devicetree/bindings/sound/adi,max98363.yaml
new file mode 100644
index 000000000000..fda571d04a64
--- /dev/null
+++ b/Documentation/devicetree/bindings/sound/adi,max98363.yaml
@@ -0,0 +1,53 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sound/adi,max98363.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Analog Devices MAX98363 SoundWire Amplifier
+
+maintainers:
+ - Ryan Lee <[email protected]>
+
+description:
+ The MAX98363 is a SoundWire input Class D mono amplifier that
+ supports MIPI SoundWire v1.2-compatible digital interface for
+ audio and control data.
+
+properties:
+ compatible:
+ enum:
+ - adi,max98363
+
+ reg:
+ maxItems: 1
+ description: Peripheral-device unique ID decoded from pin
+
+ vdd-supply:
+ description:
+ A 2.5V to 5.5V supply that powers up the VDD pin.
+
+ dvddio-supply:
+ description:
+ A 1.7V or 1.9V supply that powers up the DVDDIO pin.
+ This property is only needed for MAX98363A/B.
+
+required:
+ - compatible
+ - reg
+ - vdd-supply
+ - dvddio-supply
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/gpio/gpio.h>
+ soundwire {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ max98363: amplifier@3 {
+ compatible = "adi,max98363";
+ reg = <0x3>;
+ vdd-supply = <®ulator_vdd>;
+ dvddio-supply = <®ulator_1v8>;
+ };
+ };
--
2.34.1
On 24/02/2023 02:08, “Ryan wrote:
> From: Ryan Lee <[email protected]>
Thank you for your patch. There is something to discuss/improve.
Your patch is corrupted because you modified it after creating it. It
won't apply correctly and won't work. The bot's response with error is
about this.
Except broken patch, here are some more comments:
>
> This patch adds dt-bindings information for Analog Devices MAX98363
Do not use "This commit/patch".
https://elixir.bootlin.com/linux/v5.17.1/source/Documentation/process/submitting-patches.rst#L95
> SoundWire Amplifier.
>
Subject: drop driver. Bindings are about hardware, not drivers.
> Signed-off-by: Ryan Lee <[email protected]>
> ---
> .../bindings/sound/adi,max98363.yaml | 53 +++++++++++++++++++
> 1 file changed, 53 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/sound/adi,max98363.yaml
>
> diff --git a/Documentation/devicetree/bindings/sound/adi,max98363.yaml b/Documentation/devicetree/bindings/sound/adi,max98363.yaml
> new file mode 100644
> index 000000000000..fda571d04a64
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/sound/adi,max98363.yaml
> @@ -0,0 +1,53 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/sound/adi,max98363.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Analog Devices MAX98363 SoundWire Amplifier
> +
> +maintainers:
> + - Ryan Lee <[email protected]>
> +
> +description:
> + The MAX98363 is a SoundWire input Class D mono amplifier that
> + supports MIPI SoundWire v1.2-compatible digital interface for
> + audio and control data.
> +
> +properties:
> + compatible:
> + enum:
> + - adi,max98363
> +
> + reg:
> + maxItems: 1
> + description: Peripheral-device unique ID decoded from pin
> +
> + vdd-supply:
> + description:
> + A 2.5V to 5.5V supply that powers up the VDD pin.
> +
> + dvddio-supply:
> + description:
> + A 1.7V or 1.9V supply that powers up the DVDDIO pin.
> + This property is only needed for MAX98363A/B.
It's not a DAI?
> +
> +required:
> + - compatible
> + - reg
> + - vdd-supply
> + - dvddio-supply
> +
> +additionalProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/gpio/gpio.h>
Drop the header, you do not use it.
> + soundwire {
> + #address-cells = <1>;
> + #size-cells = <0>;
> + max98363: amplifier@3 {
also drop label (max98363).
> + compatible = "adi,max98363";
> + reg = <0x3>;
> + vdd-supply = <®ulator_vdd>;
> + dvddio-supply = <®ulator_1v8>;
> + };
> + };
Best regards,
Krzysztof
> -----Original Message-----
> From: Rob Herring <[email protected]>
> Sent: Thursday, February 23, 2023 8:30 PM
> To: “Ryan <[email protected]>
> Cc: Lee, RyanS <[email protected]>; [email protected];
> [email protected]; [email protected];
> [email protected]; [email protected]; [email protected];
> [email protected]; [email protected]; [email protected];
> [email protected]; [email protected]; [email protected];
> [email protected]; [email protected];
> [email protected]; [email protected];
> [email protected]; [email protected];
> [email protected]
> Subject: Re: [PATCH 2/2] ASoC: dt-bindings: max98363: add soundwire
> amplifier driver
>
> [External]
>
>
> On Thu, 23 Feb 2023 17:08:14 -0800, “Ryan wrote:
> > From: Ryan Lee <[email protected]>
> >
> > This patch adds dt-bindings information for Analog Devices MAX98363
> > SoundWire Amplifier.
> >
> > Signed-off-by: Ryan Lee <[email protected]>
> > ---
> > .../bindings/sound/adi,max98363.yaml | 53 +++++++++++++++++++
> > 1 file changed, 53 insertions(+)
> > create mode 100644
> > Documentation/devicetree/bindings/sound/adi,max98363.yaml
> >
>
> My bot found errors running 'make DT_CHECKER_FLAGS=-m
> dt_binding_check'
> on your patch (DT_CHECKER_FLAGS is new in v5.13):
>
> yamllint warnings/errors:
>
> dtschema/dtc warnings/errors:
> Error:
> Documentation/devicetree/bindings/sound/adi,max98363.example.dts:29.3
> -30.1 syntax error FATAL ERROR: Unable to parse input tree
> make[1]: *** [scripts/Makefile.lib:434:
> Documentation/devicetree/bindings/sound/adi,max98363.example.dtb]
> Error 1
> make[1]: *** Waiting for unfinished jobs....
> make: *** [Makefile:1508: dt_binding_check] Error 2
>
> doc reference errors (make refcheckdocs):
>
> See
> https://urldefense.com/v3/__https://patchwork.ozlabs.org/project/devicet
> ree-bindings/patch/20230224010814.504016-2-
> [email protected]__;!!A3Ni8CS0y2Y!7mTDqdmHdbwbp5Dxm5RJ60i
> TMlM6mf6W3Z9PQwXMB92aBcnAkwZODw5olBaFKtmbimORUpXmQ2j2$
>
> The base for the series is generally the latest rc1. A different dependency
> should be noted in *this* patch.
>
> If you already ran 'make dt_binding_check' and didn't see the above error(s),
> then make sure 'yamllint' is installed and dt-schema is up to
> date:
>
> pip3 install dtschema --upgrade
Thank you. I did run the 'dt_binding_check' build, but some module was not installed.
I shall modify the error and submit it again.
>
> Please check and re-submit after running the above command yourself. Note
> that DT_SCHEMA_FILES can be set to your schema file to speed up checking
> your schema. However, it must be unset to test all examples with your
> schema.