Message ID | 20220815151451.23293-1-prabhakar.mahadev-lad.rj@bp.renesas.com |
---|---|
Headers | show |
Series | Add support for Renesas RZ/Five SoC | expand |
On 15/08/2022 18:14, Lad Prabhakar wrote: > Document Renesas RZ/Five (R9A07G043) SoC. > > More info about RZ/Five SoC: > https://www.renesas.com/us/en/products/microcontrollers-microprocessors/rz-mpus/rzfive-risc-v-general-purpose-microprocessors-risc-v-cpu-core-andes-ax45mp-single-10-ghz-2ch-gigabit-ethernet > > Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Best regards, Krzysztof
Hi Conor, On Fri, Aug 19, 2022 at 8:40 PM <Conor.Dooley@microchip.com> wrote: > On 15/08/2022 16:14, Lad Prabhakar wrote: > > Add initial device tree for Renesas RZ/Five RISC-V CPU Core (AX45MP > > Single). > > > > Below is the list of IP blocks added in the initial SoC DTSI which can be > > used to boot via initramfs on RZ/Five SMARC EVK: > > - AX45MP CPU > > - CPG > > - PINCTRL > > - PLIC > > - SCIF0 > > - SYSC > > > > Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> > > --- > > v1->v2 > > * Dropped including makefile change > > * Updated ndev count > > --- > > arch/riscv/boot/dts/renesas/r9a07g043.dtsi | 121 +++++++++++++++++++++ > > 1 file changed, 121 insertions(+) > > create mode 100644 arch/riscv/boot/dts/renesas/r9a07g043.dtsi > > > > diff --git a/arch/riscv/boot/dts/renesas/r9a07g043.dtsi b/arch/riscv/boot/dts/renesas/r9a07g043.dtsi > > new file mode 100644 > > index 000000000000..b288d2607796 > > --- /dev/null > > +++ b/arch/riscv/boot/dts/renesas/r9a07g043.dtsi > > @@ -0,0 +1,121 @@ > > +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > > +/* > > + * Device Tree Source for the RZ/Five SoC > > + * > > + * Copyright (C) 2022 Renesas Electronics Corp. > > + */ > > + > > +#include <dt-bindings/interrupt-controller/irq.h> > > +#include <dt-bindings/clock/r9a07g043-cpg.h> > > + > > +/ { > > + compatible = "renesas,r9a07g043"; > > + #address-cells = <2>; > > + #size-cells = <2>; > > + > > + /* clock can be either from exclk or crystal oscillator (XIN/XOUT) */ > > + extal_clk: extal-clk { > > + compatible = "fixed-clock"; > > + #clock-cells = <0>; > > + /* This value must be overridden by the board */ > > + clock-frequency = <0>; > > What's the value in having the clock-frequency here if the board .dtsi > overwrites it? dtbs_check will complain if someone forgets to fill it > IIUC & what the missing frequency means is also kinda obvious, no? Some external clocks may be optional. Hence "dtbs_check" will complain if no "clock-frequency" is missing. > > That aside, by convention so far we have put things like extals or > reference clocks below the /cpus node. Could you do the same here too > please? Really? We've been putting them at the root node for a long time, since the separate "clocks" grouping subnode was deprecated. The extal-clk is not even part of the SoC, so it should definitely not be under the /cpus node. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
On 20/08/2022 09:45, Geert Uytterhoeven wrote: > Hi Conor, > > On Fri, Aug 19, 2022 at 8:40 PM <Conor.Dooley@microchip.com> wrote: >> On 15/08/2022 16:14, Lad Prabhakar wrote: >>> Add initial device tree for Renesas RZ/Five RISC-V CPU Core (AX45MP >>> Single). >>> >>> Below is the list of IP blocks added in the initial SoC DTSI which can be >>> used to boot via initramfs on RZ/Five SMARC EVK: >>> - AX45MP CPU >>> - CPG >>> - PINCTRL >>> - PLIC >>> - SCIF0 >>> - SYSC >>> >>> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> >>> --- >>> v1->v2 >>> * Dropped including makefile change >>> * Updated ndev count >>> --- >>> arch/riscv/boot/dts/renesas/r9a07g043.dtsi | 121 +++++++++++++++++++++ >>> 1 file changed, 121 insertions(+) >>> create mode 100644 arch/riscv/boot/dts/renesas/r9a07g043.dtsi >>> >>> diff --git a/arch/riscv/boot/dts/renesas/r9a07g043.dtsi b/arch/riscv/boot/dts/renesas/r9a07g043.dtsi >>> new file mode 100644 >>> index 000000000000..b288d2607796 >>> --- /dev/null >>> +++ b/arch/riscv/boot/dts/renesas/r9a07g043.dtsi >>> @@ -0,0 +1,121 @@ >>> +// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) >>> +/* >>> + * Device Tree Source for the RZ/Five SoC >>> + * >>> + * Copyright (C) 2022 Renesas Electronics Corp. >>> + */ >>> + >>> +#include <dt-bindings/interrupt-controller/irq.h> >>> +#include <dt-bindings/clock/r9a07g043-cpg.h> >>> + >>> +/ { >>> + compatible = "renesas,r9a07g043"; >>> + #address-cells = <2>; >>> + #size-cells = <2>; >>> + >>> + /* clock can be either from exclk or crystal oscillator (XIN/XOUT) */ >>> + extal_clk: extal-clk { >>> + compatible = "fixed-clock"; >>> + #clock-cells = <0>; >>> + /* This value must be overridden by the board */ >>> + clock-frequency = <0>; >> >> What's the value in having the clock-frequency here if the board .dtsi >> overwrites it? dtbs_check will complain if someone forgets to fill it >> IIUC & what the missing frequency means is also kinda obvious, no? > > Some external clocks may be optional. Hence "dtbs_check" will complain > if no "clock-frequency" is missing. Right, seems reasonable enough. > >> >> That aside, by convention so far we have put things like extals or >> reference clocks below the /cpus node. Could you do the same here too >> please? > > Really? We've been putting them at the root node for a long time, > since the separate "clocks" grouping subnode was deprecated. > The extal-clk is not even part of the SoC, so it should definitely > not be under the /cpus node. Under may have been a confusing choice of words, I meant "physically" under it in the file. Maybe after would have been a better choice of words? I wasn't suggesting you put it inside the CPUs node. Does that make more sense? Conor.
Hi Conor, On Sat, Aug 20, 2022 at 10:49 AM <Conor.Dooley@microchip.com> wrote: > On 20/08/2022 09:45, Geert Uytterhoeven wrote: > > On Fri, Aug 19, 2022 at 8:40 PM <Conor.Dooley@microchip.com> wrote: > >> On 15/08/2022 16:14, Lad Prabhakar wrote: > >>> Add initial device tree for Renesas RZ/Five RISC-V CPU Core (AX45MP > >>> Single). > >>> > >>> Below is the list of IP blocks added in the initial SoC DTSI which can be > >>> used to boot via initramfs on RZ/Five SMARC EVK: > >>> - AX45MP CPU > >>> - CPG > >>> - PINCTRL > >>> - PLIC > >>> - SCIF0 > >>> - SYSC > >>> > >>> Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@bp.renesas.com> > >> That aside, by convention so far we have put things like extals or > >> reference clocks below the /cpus node. Could you do the same here too > >> please? > > > > Really? We've been putting them at the root node for a long time, > > since the separate "clocks" grouping subnode was deprecated. > > The extal-clk is not even part of the SoC, so it should definitely > > not be under the /cpus node. > > Under may have been a confusing choice of words, I meant "physically" > under it in the file. Maybe after would have been a better choice of > words? I wasn't suggesting you put it inside the CPUs node. > Does that make more sense? Oh right, you mean the order of the nodes. Yes, "extal-clk" should be after "cpus", following alphabetical sort order, as the nodes have no unit addresses. Sorry for missing that in my review. I also misread "below" (in Dutch there is only a single word for "below" and "under" ;-) Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds