On Tue, Aug 06, 2013 at 09:57:39AM +0100, Alexander Shiyan wrote: > This patch adds support for multichip NAND devices controlled through GPIOs. > To implement this, the properties of tree have been renamed. All current > boards and DTS files converted to use an updated driver. Also driver > temporarily keep support for DTS files which use the previous names scheme. > > Signed-off-by: Alexander Shiyan <shc_work@xxxxxxx> > --- > .../devicetree/bindings/mtd/gpio-control-nand.txt | 16 +-- > arch/arm/boot/dts/picoxcell-pc7302-pc3x2.dts | 10 +- > arch/arm/boot/dts/picoxcell-pc7302-pc3x3.dts | 10 +- > arch/arm/mach-clps711x/board-autcpu12.c | 4 +- > arch/arm/mach-clps711x/board-p720t.c | 4 +- > arch/arm/mach-pxa/cm-x255.c | 10 +- > drivers/mtd/nand/gpio.c | 108 +++++++++++++++------ > include/linux/mtd/nand-gpio.h | 12 ++- > 8 files changed, 112 insertions(+), 62 deletions(-) > > diff --git a/Documentation/devicetree/bindings/mtd/gpio-control-nand.txt b/Documentation/devicetree/bindings/mtd/gpio-control-nand.txt > index 91070d0..c58210a 100644 > --- a/Documentation/devicetree/bindings/mtd/gpio-control-nand.txt > +++ b/Documentation/devicetree/bindings/mtd/gpio-control-nand.txt > @@ -11,8 +11,11 @@ Required properties: > are made in native endianness. Unrelated, but the above like sounds mighty suspicious and possibly meaningless... > - #address-cells, #size-cells : Must be present if the device has sub-nodes > representing partitions. > -- gpios : specifies the gpio pins to control the NAND device. nwp is an > - optional gpio and may be set to 0 if not present. I'm not against deprecating this property, as the new mechanism is far more flexible, and gets rid of the odd nwp case. However I think the documentation for the old property should be kept (though marked as deprecated). I'd be happy with a "Deprecated properties" section as with the regulator bindings. I'm not sure about changing the dts immediately as this prevents using them with an old kernel, and creates a lot of churn, given the existing binding will be supported for the transitionary period... > +- ale-gpios : specifies the ALE gpio pin. > +- cle-gpios : specifies the CLE gpio pin. > +- nwp-gpios : specifies the NWP gpio pin (Optional). > +- nce-gpios : specifies the NCE gpio pin or several NCE GPIOs for multichip NAND. > +- rdy-gpios : specifies the RDY gpio pin or several RDY GPIOs for multichip NAND. > > Optional properties: > - bank-width : Width (in bytes) of the device. If not present, the width > @@ -37,11 +40,10 @@ gpio-nand@1,0 { > reg = <1 0x0000 0x2>; > #address-cells = <1>; > #size-cells = <1>; > - gpios = <&banka 1 0 /* rdy */ > - &banka 2 0 /* nce */ > - &banka 3 0 /* ale */ > - &banka 4 0 /* cle */ > - 0 /* nwp */>; > + ale-gpios = <&banka 3 0>; > + cle-gpios = <&banka 4 0>; > + nce-gpios = <&banka 2 0>; > + rdy-gpios = <&banka 1 0>; It would be nice to have a multichip NAND example, also. Thanks, Mark. -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html