[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAEnQRZBsBOAHiwZDNKyPRinXdEOhdu2dBdGpMrq-e9kWasukSQ@mail.gmail.com>
Date: Tue, 4 Jun 2024 15:50:01 +0300
From: Daniel Baluta <daniel.baluta@...il.com>
To: Frank Li <Frank.li@....com>
Cc: Animesh Agarwal <animeshagarwal28@...il.com>, Vinod Koul <vkoul@...nel.org>,
Rob Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>, Conor Dooley <conor+dt@...nel.org>,
Shawn Guo <shawnguo@...nel.org>, Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>, Fabio Estevam <festevam@...il.com>, dmaengine@...r.kernel.org,
devicetree@...r.kernel.org, imx@...ts.linux.dev,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] dt-bindings: dma: fsl,imx-dma: Convert to dtschema
On Thu, May 30, 2024 at 7:06 PM Frank Li <Frank.li@....com> wrote:
>
> On Thu, May 30, 2024 at 12:51:07PM +0530, Animesh Agarwal wrote:
> > Convert the fsl i.MX DMA controller bindings to DT schema
>
> nit: need "." after sentence.
>
> >
> > Signed-off-by: Animesh Agarwal <animeshagarwal28@...il.com>
> > ---
> > .../devicetree/bindings/dma/fsl,imx-dma.yaml | 58 +++++++++++++++++++
> > .../devicetree/bindings/dma/fsl-imx-dma.txt | 50 ----------------
> > 2 files changed, 58 insertions(+), 50 deletions(-)
> > create mode 100644 Documentation/devicetree/bindings/dma/fsl,imx-dma.yaml
> > delete mode 100644 Documentation/devicetree/bindings/dma/fsl-imx-dma.txt
> >
> > diff --git a/Documentation/devicetree/bindings/dma/fsl,imx-dma.yaml b/Documentation/devicetree/bindings/dma/fsl,imx-dma.yaml
> > new file mode 100644
> > index 000000000000..f36ab5425bdb
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/dma/fsl,imx-dma.yaml
> > @@ -0,0 +1,58 @@
> > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/dma/fsl,imx-dma.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Freescale Direct Memory Access (DMA) Controller for i.MX
> > +
> > +maintainers:
> > + - Animesh Agarwal <animeshagarwal28@...il.com>
> > +
> > +allOf:
> > + - $ref: dma-controller.yaml#
> > +
> > +properties:
> > + compatible:
> > + enum:
> > + - fsl,imx1-dma
> > + - fsl,imx21-dma
> > + - fsl,imx27-dma
> > +
> > + reg:
> > + maxItems: 1
> > +
> > + interrupts:
> > + description: |
> > + First item should be DMA interrupt, second one is optional and
> > + should contain DMA Error interrupt.
>
> items:
> - description: DMA complete interrupt
> - description: DMA Error interrupt
>
> > + minItems: 1
> > + maxItems: 2
> > +
> > + "#dma-cells":
> > + const: 1
> > +
> > + dma-channels:
> > + const: 16
>
> I think it should be maximum: 16
As Krzysztof pointed out and looking at datasheet and driver implementation, we
always use 16 channels. Nothing less or variable.
So const: 16 I think it is correct!
Another, thing. Should we keep both
dma-channels
and
#dma-channels?
I wonder what is the correct way to put #dma-channels
Like this:
#dma-channels:
deprecated
or
'#dma-channels':
deprecated
The rest looks good to me.
Thanks for doing this Animesh!
Powered by blists - more mailing lists