2021-07-11 12:51:46

by Ban Tao

[permalink] [raw]
Subject: [PATCH v6 2/2] ASoC: sun50i-dmic: dt-bindings: add DT bindings for DMIC controller

From: Ban Tao <[email protected]>

DT binding documentation for this new ASoC driver.

Signed-off-by: Ban Tao <[email protected]>
Reviewed-by: Rob Herring <[email protected]>

---
v1->v2:
1.Fix some build errors.
---
v2->v3:
1.Fix some build errors.
---
v3->v4:
1.None.
---
v4->v5:
1.Add interrupt.
2.Keep clock and reset index.
---
v5->v6:
1.None.
---
.../sound/allwinner,sun50i-h6-dmic.yaml | 79 +++++++++++++++++++
1 file changed, 79 insertions(+)
create mode 100644 Documentation/devicetree/bindings/sound/allwinner,sun50i-h6-dmic.yaml

diff --git a/Documentation/devicetree/bindings/sound/allwinner,sun50i-h6-dmic.yaml b/Documentation/devicetree/bindings/sound/allwinner,sun50i-h6-dmic.yaml
new file mode 100644
index 000000000000..0cfc07f369bd
--- /dev/null
+++ b/Documentation/devicetree/bindings/sound/allwinner,sun50i-h6-dmic.yaml
@@ -0,0 +1,79 @@
+# SPDX-License-Identifier: (GPL-2.0+ OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/sound/allwinner,sun50i-h6-dmic.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Allwinner H6 DMIC Device Tree Bindings
+
+maintainers:
+ - Ban Tao <[email protected]>
+
+properties:
+ "#sound-dai-cells":
+ const: 0
+
+ compatible:
+ const: allwinner,sun50i-h6-dmic
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ maxItems: 1
+
+ clocks:
+ items:
+ - description: Bus Clock
+ - description: Module Clock
+
+ clock-names:
+ items:
+ - const: bus
+ - const: mod
+
+ dmas:
+ items:
+ - description: RX DMA Channel
+
+ dma-names:
+ items:
+ - const: rx
+
+ resets:
+ maxItems: 1
+
+required:
+ - "#sound-dai-cells"
+ - compatible
+ - reg
+ - interrupts
+ - clocks
+ - clock-names
+ - dmas
+ - dma-names
+ - resets
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+ #include <dt-bindings/interrupt-controller/irq.h>
+
+ #include <dt-bindings/clock/sun50i-h6-ccu.h>
+ #include <dt-bindings/reset/sun50i-h6-ccu.h>
+
+ dmic: dmic@5095000 {
+ #sound-dai-cells = <0>;
+ compatible = "allwinner,sun50i-h6-dmic";
+ reg = <0x05095000 0x400>;
+ interrupts = <GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&ccu CLK_BUS_DMIC>, <&ccu CLK_DMIC>;
+ clock-names = "bus", "mod";
+ dmas = <&dma 7>;
+ dma-names = "rx";
+ resets = <&ccu RST_BUS_DMIC>;
+ };
+
+...
--
2.17.1


2021-07-15 08:50:28

by Maxime Ripard

[permalink] [raw]
Subject: Re: [PATCH v6 2/2] ASoC: sun50i-dmic: dt-bindings: add DT bindings for DMIC controller

On Sun, Jul 11, 2021 at 08:48:26AM -0400, [email protected] wrote:
> From: Ban Tao <[email protected]>
>
> DT binding documentation for this new ASoC driver.
>
> Signed-off-by: Ban Tao <[email protected]>
> Reviewed-by: Rob Herring <[email protected]>

Reviewed-by: Maxime Ripard <[email protected]>

> ---
> v1->v2:
> 1.Fix some build errors.
> ---
> v2->v3:
> 1.Fix some build errors.
> ---
> v3->v4:
> 1.None.
> ---
> v4->v5:
> 1.Add interrupt.
> 2.Keep clock and reset index.
> ---
> v5->v6:
> 1.None.
> ---

Just as a general comment, you don't need to duplicate the --- all the
time, here something like the following would have been fine

---

v1->v2:
1.Fix some build errors.

v2->v3:
1.Fix some build errors.

v3->v4:
1.None

etc.

git will ignore anything after ---, so it doesn't matter whether there's
one or multiple.

Maxime