Re: [PATCH 1/2] dt-bindings: dmaengine: Add SpacemiT K1 PDMA request numbers
Conor Dooley <[email protected]>
| Newsgroups | dev.linux.lists.spacemit,org.infradead.lists.linux-riscv,org.kernel.vger.dmaengine,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <20260609-freeload-luckiness-7a143eae62f4@spud> |
On Tue, Jun 09, 2026 at 02:55:59PM -0400, Guodong Xu wrote: > Hi, Conor > > On 2026-06-08 18:33, Conor Dooley wrote: > > On Sun, Jun 07, 2026 at 01:41:30PM -0400, Guodong Xu wrote: > > > Add a dt-bindings header that gives symbolic names to the SpacemiT K1 > > > PDMA request lines of the non-secure peripherals. Device trees can use > > > these K1_PDMA_* macros instead of magic numbers. > > > > > > Point the spacemit,k1-pdma binding's #dma-cells description at the new > > > header. > > > > > > Signed-off-by: Guodong Xu <[email protected]> > > > --- > > > .../devicetree/bindings/dma/spacemit,k1-pdma.yaml | 4 +- > > > include/dt-bindings/dma/spacemit,k1-pdma.h | 56 ++++++++++++++++++++++ > > > 2 files changed, 59 insertions(+), 1 deletion(-) > > > > > > diff --git a/Documentation/devicetree/bindings/dma/spacemit,k1-pdma.yaml b/Documentation/devicetree/bindings/dma/spacemit,k1-pdma.yaml > > > index ec06235baf5ca..0d4ac9849e27b 100644 > > > --- a/Documentation/devicetree/bindings/dma/spacemit,k1-pdma.yaml > > > +++ b/Documentation/devicetree/bindings/dma/spacemit,k1-pdma.yaml > > > @@ -35,7 +35,9 @@ properties: > > > '#dma-cells': > > > const: 1 > > > description: > > > - The DMA request number for the peripheral device. > > > + The single cell is the DMA request number for the peripheral device. > > > + See <dt-bindings/dma/spacemit,k1-pdma.h> for the list of valid request > > > + numbers. > > > > > > required: > > > - compatible > > > diff --git a/include/dt-bindings/dma/spacemit,k1-pdma.h b/include/dt-bindings/dma/spacemit,k1-pdma.h > > > > Why does this need to be in a binding when there is no use of this in > > the driver? May as well be a header, particularly if these are numbers > > Thanks for the review. You are correct that these are not referenced in the > driver. My change to k1-pdma.yaml should be dropped. > > > with a set meaning that are lifted from the TRM, rather than made up > > numbers to make a driver work. The former seems likely, given you're > > indexing from 3 not 0. > > Yes, it is defined in the K1 manual [1], see 9.4.3 DMA Connectivity & > Assignments > > Link: https://www.spacemit.com/community/document/info?lang=en&nodepath=hardware/key_stone/k1/k1_docs/k1_usermanual/9.Top_System.md [1] > > I will fix that in v2. Just in case I wasn't clear (and I think I wasn't), when I said "may as well be a header" I meant a header in arch/riscv/boot/dts/spacemit.
signature.asc
(application/pgp-signature, 228 B)
-----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCaihvkwAKCRB4tDGHoIJi 0quDAP9NVs88iuV9CNHJrkUTyg0JS0+g4jZfML658Gh5VCV4AQD9HAvgmQaWFy28 V+fx0E0a2bXDRTY3o0eZOk3dv/55WQg= =3h5W -----END PGP SIGNATURE-----