On Thu, Jul 24, 2025 at 8:19 PM Yixun Lan <dlan@gentoo.org> wrote:
>
> Hi Guodong,
>
> On 17:39 Mon 14 Jul , Guodong Xu wrote:
> > Add PDMA0 dma-controller node under dma_bus for SpacemiT K1 SoC.
> >
> > The PDMA0 node is marked as disabled by default, allowing board-specific
> > device trees to enable it as needed.
> >
> > Signed-off-by: Guodong Xu <guodong@riscstar.com>
> > ---
> > v3:
> > - adjust pdma0 position, ordering by device address
> > - update properties according to the newly created schema binding
> > v2:
> > - Updated the compatible string.
> > - Rebased. Part of the changes in v1 is now in this patchset:
> > - "riscv: dts: spacemit: Add DMA translation buses for K1"
> > - Link: https://lore.kernel.org/all/20250623-k1-dma-buses-rfc-wip-v1-0-c0144082061f@iscas.ac.cn/
> > ---
> > arch/riscv/boot/dts/spacemit/k1.dtsi | 11 +++++++++++
> > 1 file changed, 11 insertions(+)
> >
> > diff --git a/arch/riscv/boot/dts/spacemit/k1.dtsi b/arch/riscv/boot/dts/spacemit/k1.dtsi
> > index abde8bb07c95c5a745736a2dd6f0c0e0d7c696e4..46dc002af947893cc2c234ee61e63c371cd966ca 100644
> > --- a/arch/riscv/boot/dts/spacemit/k1.dtsi
> > +++ b/arch/riscv/boot/dts/spacemit/k1.dtsi
> > @@ -660,6 +660,17 @@ dma-bus {
> > dma-ranges = <0x0 0x00000000 0x0 0x00000000 0x0 0x80000000>,
> > <0x1 0x00000000 0x1 0x80000000 0x3 0x00000000>;
> >
> > + pdma0: dma-controller@d4000000 {
> does K1 has more than one pdma controller? No? as I checked..
> so, I'd suggest simply naming it as 'pdma' - which clear the confusion
> that there will be more than one pdma nodes..
>
Thanks Yixun. I will name it 'pdma'.
> > + compatible = "spacemit,k1-pdma";
> > + reg = <0x0 0xd4000000 0x0 0x4000>;
> ..
> > + interrupts = <72>;
> for consistency in this dtsi file, I'd suggest moving "interrupts" after "clocks",
> or even after "resets"? leave "clocks & resets" together..
>
That makes sense. Will do.
Thanks.
Guodong
> > + clocks = <&syscon_apmu CLK_DMA>;
> > + resets = <&syscon_apmu RESET_DMA>;
> > + dma-channels = <16>;
> > + #dma-cells= <1>;
> > + status = "disabled";
> > + };
> > +
> > uart0: serial@d4017000 {
> > compatible = "spacemit,k1-uart",
> > "intel,xscale-uart";
> >
> > --
> > 2.43.0
> >
>
> --
> Yixun Lan (dlan)