Message ID | 1768974.jEFIAaInqd@wasted.cogentembedded.com (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Simon Horman |
Headers | show |
Hi Sergei, On Sun, Aug 9, 2015 at 12:27 AM, Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> wrote: > Define the SILK board dependent part of the QSPI device node. > Add device nodes for Spansion S25FL512S SPI flash and MTD partitions on it. > > Based on the original patch by Vladimir Barinov > <vladimir.barinov@cogentembedded.com>. > > Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> > --- renesas.orig/arch/arm/boot/dts/r8a7794-silk.dts > +++ renesas/arch/arm/boot/dts/r8a7794-silk.dts > +&qspi { > + pinctrl-0 = <&qspi_pins>; > + pinctrl-names = "default"; > + > + status = "okay"; > + > + flash@0 { > + #address-cells = <1>; > + #size-cells = <1>; > + compatible = "spansion,s25fl512s"; Please add the "jedec,spi-nor" fallback. > + reg = <0>; > + spi-max-frequency = <30000000>; > + spi-tx-bus-width = <4>; > + spi-rx-bus-width = <4>; > + m25p,fast-read; Please keep all "spi-*" properties together. > + spi-cpol; > + spi-cpha; > + partition@0 { > + label = "loader"; > + reg = <0x00000000 0x00040000>; > + read-only; > + }; > + partition@40000 { > + label = "user"; > + reg = <0x00040000 0x00400000>; > + read-only; > + }; > + partition@440000 { > + label = "flash"; > + reg = <0x00440000 0x03bc0000>; > + }; The above part I cannot verify, so I have to trust you. 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 -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 08/10/2015 05:38 PM, Geert Uytterhoeven wrote: >> Define the SILK board dependent part of the QSPI device node. >> Add device nodes for Spansion S25FL512S SPI flash and MTD partitions on it. >> Based on the original patch by Vladimir Barinov >> <vladimir.barinov@cogentembedded.com>. >> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> >> --- renesas.orig/arch/arm/boot/dts/r8a7794-silk.dts >> +++ renesas/arch/arm/boot/dts/r8a7794-silk.dts > >> +&qspi { >> + pinctrl-0 = <&qspi_pins>; >> + pinctrl-names = "default"; >> + >> + status = "okay"; >> + >> + flash@0 { >> + #address-cells = <1>; >> + #size-cells = <1>; >> + compatible = "spansion,s25fl512s"; > Please add the "jedec,spi-nor" fallback. Hm, spi-nor.c alone can't control this device, it's rather m25p80.c that's the real driver. So if a fallback needs to be added indeed it should be "st,m25p80" I think... [...] > Gr{oetje,eeting}s, MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Sergei, On Mon, Aug 10, 2015 at 8:18 PM, Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> wrote: > On 08/10/2015 05:38 PM, Geert Uytterhoeven wrote: >>> +&qspi { >>> + pinctrl-0 = <&qspi_pins>; >>> + pinctrl-names = "default"; >>> + >>> + status = "okay"; >>> + >>> + flash@0 { >>> + #address-cells = <1>; >>> + #size-cells = <1>; >>> + compatible = "spansion,s25fl512s"; > >> Please add the "jedec,spi-nor" fallback. > > Hm, spi-nor.c alone can't control this device, it's rather m25p80.c > that's the real driver. So if a fallback needs to be added indeed it should > be "st,m25p80" I think... Please have a look at Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt. 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 -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Index: renesas/arch/arm/boot/dts/r8a7794-silk.dts =================================================================== --- renesas.orig/arch/arm/boot/dts/r8a7794-silk.dts +++ renesas/arch/arm/boot/dts/r8a7794-silk.dts @@ -65,6 +65,11 @@ renesas,groups = "mmc_data8", "mmc_ctrl"; renesas,function = "mmc"; }; + + qspi_pins: spi0 { + renesas,groups = "qspi_ctrl", "qspi_data4"; + renesas,function = "qspi"; + }; }; &scif2 { @@ -100,3 +105,38 @@ non-removable; status = "okay"; }; + +&qspi { + pinctrl-0 = <&qspi_pins>; + pinctrl-names = "default"; + + status = "okay"; + + flash@0 { + #address-cells = <1>; + #size-cells = <1>; + compatible = "spansion,s25fl512s"; + reg = <0>; + spi-max-frequency = <30000000>; + spi-tx-bus-width = <4>; + spi-rx-bus-width = <4>; + m25p,fast-read; + spi-cpol; + spi-cpha; + + partition@0 { + label = "loader"; + reg = <0x00000000 0x00040000>; + read-only; + }; + partition@40000 { + label = "user"; + reg = <0x00040000 0x00400000>; + read-only; + }; + partition@440000 { + label = "flash"; + reg = <0x00440000 0x03bc0000>; + }; + }; +};
Define the SILK board dependent part of the QSPI device node. Add device nodes for Spansion S25FL512S SPI flash and MTD partitions on it. Based on the original patch by Vladimir Barinov <vladimir.barinov@cogentembedded.com>. Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> --- arch/arm/boot/dts/r8a7794-silk.dts | 40 +++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html