2021-01-03 10:22:33

by Aleksander Jan Bajkowski

[permalink] [raw]
Subject: [PATCH] dt-bindings: mips: lantiq: Document Lantiq Xway DMA bindings

Document the Lantiq Xway SoC DMA Controller DT bindings.

Signed-off-by: Aleksander Jan Bajkowski <[email protected]>
---
.../bindings/mips/lantiq/lantiq,dma-xway.yaml | 32 +++++++++++++++++++
1 file changed, 32 insertions(+)
create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml

diff --git a/Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml b/Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml
new file mode 100644
index 000000000000..40130fefa2b4
--- /dev/null
+++ b/Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml
@@ -0,0 +1,32 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/lantiq/lantiq,dma-xway.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Lantiq Xway SoCs DMA Controller DT bindings
+
+maintainers:
+ - John Crispin <[email protected]>
+
+properties:
+ compatible:
+ items:
+ - enum:
+ - lantiq,dma-xway
+
+ reg:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+
+additionalProperties: false
+
+examples:
+ - |
+ dma@e104100 {
+ compatible = "lantiq,dma-xway";
+ reg = <0xe104100 0x800>;
+ };
--
2.20.1


2021-01-12 09:56:13

by Rob Herring

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: mips: lantiq: Document Lantiq Xway DMA bindings

On Sun, 03 Jan 2021 11:18:03 +0100, Aleksander Jan Bajkowski wrote:
> Document the Lantiq Xway SoC DMA Controller DT bindings.
>
> Signed-off-by: Aleksander Jan Bajkowski <[email protected]>
> ---
> .../bindings/mips/lantiq/lantiq,dma-xway.yaml | 32 +++++++++++++++++++
> 1 file changed, 32 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml
>

Reviewed-by: Rob Herring <[email protected]>

2021-01-13 10:46:56

by Thomas Bogendoerfer

[permalink] [raw]
Subject: Re: [PATCH] dt-bindings: mips: lantiq: Document Lantiq Xway DMA bindings

On Sun, Jan 03, 2021 at 11:18:03AM +0100, Aleksander Jan Bajkowski wrote:
> Document the Lantiq Xway SoC DMA Controller DT bindings.
>
> Signed-off-by: Aleksander Jan Bajkowski <[email protected]>
> ---
> .../bindings/mips/lantiq/lantiq,dma-xway.yaml | 32 +++++++++++++++++++
> 1 file changed, 32 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,dma-xway.yaml

applied to mips-next.

Thomas.

--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]

2021-01-16 20:49:24

by Martin Blumenstingl

[permalink] [raw]
Subject: RE: [PATCH] dt-bindings: mips: lantiq: Document Lantiq Xway DMA bindings

(another late reply from me, sorry)

> +required:
> + - compatible
> + - reg
This is actually an older IP variant of what can be found in the Intel
LGM SoCs. The dt-bindings are currently being upstreamed for that newer
SoC in [0].

Based on "DOs and DON’Ts for designing and writing Devicetree bindings"
I think some more mandatory properties are needed, even though our
driver currently uses none of them:
- interrupts: as far as I know the IP on the Lantiq SoCs has (at least)
one interrupt for each DMA channel. That means: 28 interrupts on the
xRX200 SoCs
- I *assume* (but I have not researched if that's really the case) that
the Lantiq variant also has at least one clock input and a reset line
- since we don't have a proper DMA driver yet I can't comment what we
should use for #dma-cells

> +examples:
> + - |
> + dma@e104100 {
note to self: it seems that both dma@ and dma-controller@ are used in
existing schemas (the latter having twice as many occurrences though):
$ grep -R dma@ Documentation/devicetree/bindings/dma/* | wc -l
20
$ grep -R dma-controller@ Documentation/devicetree/bindings/dma/* | wc -l
45


Best regards,
Martin


[0] https://patchwork.ozlabs.org/project/devicetree-bindings/patch/0864b9bfa6e2b8b5e7ad9a7a739ca3274f66493c.1610703653.git.mallikarjunax.reddy@linux.intel.com/
[1] https://www.kernel.org/doc/html/latest/devicetree/bindings/writing-bindings.html