ARM: dts: armada-38x: update NAND node with new bindings
authorMiquel Raynal <miquel.raynal@bootlin.com>
Wed, 25 Apr 2018 14:48:01 +0000 (16:48 +0200)
committerGregory CLEMENT <gregory.clement@bootlin.com>
Fri, 18 May 2018 16:36:57 +0000 (18:36 +0200)
Use the new bindings of the Marvell NAND controller driver. Also adapt
the NAND controller node organization to distinguish which property is
relevant for the controller, and which one is NAND chip specific. Expose
the partitions as a subnode of the NAND chip.

Remove the 'marvell,nand-enable-arbiter' property, not needed anymore
as the new driver activates the arbiter by default for all boards which
is either needed or harmless.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Signed-off-by: Gregory CLEMENT <gregory.clement@bootlin.com>
arch/arm/boot/dts/armada-385-db-ap.dts
arch/arm/boot/dts/armada-385-linksys-caiman.dts
arch/arm/boot/dts/armada-385-linksys-cobra.dts
arch/arm/boot/dts/armada-385-linksys-rango.dts
arch/arm/boot/dts/armada-385-linksys-shelby.dts
arch/arm/boot/dts/armada-385-linksys.dtsi
arch/arm/boot/dts/armada-388-db.dts
arch/arm/boot/dts/armada-38x.dtsi

index d294f24281a51c481c68c14c5ad1f82cc6ad946d..0e4613bb56eeae02d496be3784517760cf425537 100644 (file)
                                status = "okay";
                        };
 
-                       nfc: flash@d0000 {
-                               status = "okay";
-                               num-cs = <1>;
-                               nand-ecc-strength = <4>;
-                               nand-ecc-step-size = <512>;
-                               marvell,nand-keep-config;
-                               marvell,nand-enable-arbiter;
-                               nand-on-flash-bbt;
-
-                               partitions {
-                                       compatible = "fixed-partitions";
-                                       #address-cells = <1>;
-                                       #size-cells = <1>;
-
-                                       partition@0 {
-                                               label = "U-Boot";
-                                               reg = <0x00000000 0x00800000>;
-                                               read-only;
-                                       };
-
-                                       partition@800000 {
-                                               label = "uImage";
-                                               reg = <0x00800000 0x00400000>;
-                                               read-only;
-                                       };
-
-                                       partition@c00000 {
-                                               label = "Root";
-                                               reg = <0x00c00000 0x3f400000>;
-                                       };
-                               };
-                       };
-
                        usb3@f0000 {
                                status = "okay";
                                usb-phy = <&usb3_phy>;
                spi-max-frequency = <54000000>;
        };
 };
+
+&nand_controller {
+       status = "okay";
+
+       nand@0 {
+               reg = <0>;
+               label = "pxa3xx_nand-0";
+               nand-rb = <0>;
+               nand-on-flash-bbt;
+               nand-ecc-strength = <4>;
+               nand-ecc-step-size = <512>;
+
+               partitions {
+                       compatible = "fixed-partitions";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+
+                       partition@0 {
+                               label = "U-Boot";
+                               reg = <0x00000000 0x00800000>;
+                               read-only;
+                       };
+
+                       partition@800000 {
+                               label = "uImage";
+                               reg = <0x00800000 0x00400000>;
+                               read-only;
+                       };
+
+                       partition@c00000 {
+                               label = "Root";
+                               reg = <0x00c00000 0x3f400000>;
+                       };
+               };
+       };
+};
index 1f30993af405ede14c7bde3b5db0e31aa4999861..a03050c97084c5c809a2834d70452deb8767b58b 100644 (file)
 
 &nand {
        /* 128MiB */
-
-       partition@0 {
-               label = "u-boot";
-               reg = <0x0000000 0x200000>;  /* 2MiB */
-               read-only;
-       };
-
-       partition@100000 {
-               label = "u_env";
-               reg = <0x200000 0x40000>;    /* 256KiB */
-       };
-
-       partition@140000 {
-               label = "s_env";
-               reg = <0x240000 0x40000>;    /* 256KiB */
-       };
-
-       partition@900000 {
-               label = "devinfo";
-               reg = <0x900000 0x100000>;   /* 1MiB */
-               read-only;
-       };
-
-       /* kernel1 overlaps with rootfs1 by design */
-       partition@a00000 {
-               label = "kernel1";
-               reg = <0xa00000 0x2800000>;  /* 40MiB */
-       };
-
-       partition@1000000 {
-               label = "rootfs1";
-               reg = <0x1000000 0x2200000>;  /* 34MiB */
-       };
-
-       /* kernel2 overlaps with rootfs2 by design */
-       partition@3200000 {
-               label = "kernel2";
-               reg = <0x3200000 0x2800000>; /* 40MiB */
-       };
-
-       partition@3800000 {
-               label = "rootfs2";
-               reg = <0x3800000 0x2200000>; /* 34MiB */
-       };
-
-       /*
-        * 38MiB, last MiB is for the BBT, not writable
-        */
-       partition@5a00000 {
-               label = "syscfg";
-               reg = <0x5a00000 0x2600000>;
-       };
-
-       /*
-        * Unused area between "s_env" and "devinfo".
-        * Moved here because otherwise the renumbered
-        * partitions would break the bootloader
-        * supplied bootargs
-        */
-       partition@180000 {
-               label = "unused_area";
-               reg = <0x280000 0x680000>;   /* 6.5MiB */
+       partitions {
+               compatible = "fixed-partitions";
+               #address-cells = <1>;
+               #size-cells = <1>;
+
+               partition@0 {
+                       label = "u-boot";
+                       reg = <0x0000000 0x200000>;  /* 2MiB */
+                       read-only;
+               };
+
+               partition@100000 {
+                       label = "u_env";
+                       reg = <0x200000 0x40000>;    /* 256KiB */
+               };
+
+               partition@140000 {
+                       label = "s_env";
+                       reg = <0x240000 0x40000>;    /* 256KiB */
+               };
+
+               partition@900000 {
+                       label = "devinfo";
+                       reg = <0x900000 0x100000>;   /* 1MiB */
+                       read-only;
+               };
+
+               /* kernel1 overlaps with rootfs1 by design */
+               partition@a00000 {
+                       label = "kernel1";
+                       reg = <0xa00000 0x2800000>;  /* 40MiB */
+               };
+
+               partition@1000000 {
+                       label = "rootfs1";
+                       reg = <0x1000000 0x2200000>;  /* 34MiB */
+               };
+
+               /* kernel2 overlaps with rootfs2 by design */
+               partition@3200000 {
+                       label = "kernel2";
+                       reg = <0x3200000 0x2800000>; /* 40MiB */
+               };
+
+               partition@3800000 {
+                       label = "rootfs2";
+                       reg = <0x3800000 0x2200000>; /* 34MiB */
+               };
+
+               /*
+                * 38MiB, last MiB is for the BBT, not writable
+                */
+               partition@5a00000 {
+                       label = "syscfg";
+                       reg = <0x5a00000 0x2600000>;
+               };
+
+               /*
+                * Unused area between "s_env" and "devinfo".
+                * Moved here because otherwise the renumbered
+                * partitions would break the bootloader
+                * supplied bootargs
+                */
+               partition@180000 {
+                       label = "unused_area";
+                       reg = <0x280000 0x680000>;   /* 6.5MiB */
+               };
        };
 };
index bc34802ce6bc4084d0125dbe7f93e37ff4e663f2..e3e4877a6f4957ccc9802edac5b86faa5fcfae95 100644 (file)
 
 &nand {
        /* 128MiB */
-
-       partition@0 {
-               label = "u-boot";
-               reg = <0x0000000 0x200000>;  /* 2MiB */
-               read-only;
-       };
-
-       partition@100000 {
-               label = "u_env";
-               reg = <0x200000 0x40000>;    /* 256KiB */
-       };
-
-       partition@140000 {
-               label = "s_env";
-               reg = <0x240000 0x40000>;    /* 256KiB */
-       };
-
-       partition@900000 {
-               label = "devinfo";
-               reg = <0x900000 0x100000>;   /* 1MiB */
-               read-only;
-       };
-
-       /* kernel1 overlaps with rootfs1 by design */
-       partition@a00000 {
-               label = "kernel1";
-               reg = <0xa00000 0x2800000>;  /* 40MiB */
-       };
-
-       partition@1000000 {
-               label = "rootfs1";
-               reg = <0x1000000 0x2200000>;  /* 34MiB */
-       };
-
-       /* kernel2 overlaps with rootfs2 by design */
-       partition@3200000 {
-               label = "kernel2";
-               reg = <0x3200000 0x2800000>; /* 40MiB */
-       };
-
-       partition@3800000 {
-               label = "rootfs2";
-               reg = <0x3800000 0x2200000>; /* 34MiB */
-       };
-
-       /*
-        * 38MiB, last MiB is for the BBT, not writable
-        */
-       partition@5a00000 {
-               label = "syscfg";
-               reg = <0x5a00000 0x2600000>;
-       };
-
-       /*
-        * Unused area between "s_env" and "devinfo".
-        * Moved here because otherwise the renumbered
-        * partitions would break the bootloader
-        * supplied bootargs
-        */
-       partition@180000 {
-               label = "unused_area";
-               reg = <0x280000 0x680000>;   /* 6.5MiB */
+       partitions {
+               compatible = "fixed-partitions";
+               #address-cells = <1>;
+               #size-cells = <1>;
+
+               partition@0 {
+                       label = "u-boot";
+                       reg = <0x0000000 0x200000>;  /* 2MiB */
+                       read-only;
+               };
+
+               partition@100000 {
+                       label = "u_env";
+                       reg = <0x200000 0x40000>;    /* 256KiB */
+               };
+
+               partition@140000 {
+                       label = "s_env";
+                       reg = <0x240000 0x40000>;    /* 256KiB */
+               };
+
+               partition@900000 {
+                       label = "devinfo";
+                       reg = <0x900000 0x100000>;   /* 1MiB */
+                       read-only;
+               };
+
+               /* kernel1 overlaps with rootfs1 by design */
+               partition@a00000 {
+                       label = "kernel1";
+                       reg = <0xa00000 0x2800000>;  /* 40MiB */
+               };
+
+               partition@1000000 {
+                       label = "rootfs1";
+                       reg = <0x1000000 0x2200000>;  /* 34MiB */
+               };
+
+               /* kernel2 overlaps with rootfs2 by design */
+               partition@3200000 {
+                       label = "kernel2";
+                       reg = <0x3200000 0x2800000>; /* 40MiB */
+               };
+
+               partition@3800000 {
+                       label = "rootfs2";
+                       reg = <0x3800000 0x2200000>; /* 34MiB */
+               };
+
+               /*
+                * 38MiB, last MiB is for the BBT, not writable
+                */
+               partition@5a00000 {
+                       label = "syscfg";
+                       reg = <0x5a00000 0x2600000>;
+               };
+
+               /*
+                * Unused area between "s_env" and "devinfo".
+                * Moved here because otherwise the renumbered
+                * partitions would break the bootloader
+                * supplied bootargs
+                */
+               partition@180000 {
+                       label = "unused_area";
+                       reg = <0x280000 0x680000>;   /* 6.5MiB */
+               };
        };
 };
index 5b745a0ccce513d18173ad965a0fc88add4658a2..3c4af57ec2b9e03a407f416a1208a657b0da3dfc 100644 (file)
 
 &nand {
        /* AMD/Spansion S34ML02G2 256MiB, OEM Layout */
-
-       partition@0 {
-               label = "u-boot";
-               reg = <0x0000000 0x200000>;  /* 2MiB */
-               read-only;
-       };
-
-       partition@200000 {
-               label = "u_env";
-               reg = <0x200000 0x20000>;    /* 128KiB */
-       };
-
-       partition@220000 {
-               label = "s_env";
-               reg = <0x220000 0x40000>;    /* 256KiB */
-       };
-
-       partition@7e0000 {
-               label = "devinfo";
-               reg = <0x7e0000 0x40000>;   /* 256KiB */
-               read-only;
-       };
-
-       partition@820000 {
-               label = "sysdiag";
-               reg = <0x820000 0x1e0000>;   /* 1920KiB */
-               read-only;
-       };
-
-       /* kernel1 overlaps with rootfs1 by design */
-       partition@a00000 {
-               label = "kernel1";
-               reg = <0xa00000 0x5000000>;  /* 80MiB */
-       };
-
-       partition@1000000 {
-               label = "rootfs1";
-               reg = <0x1000000 0x4a00000>;  /* 74MiB */
-       };
-
-       /* kernel2 overlaps with rootfs2 by design */
-       partition@5a00000 {
-               label = "kernel2";
-               reg = <0x5a00000 0x5000000>; /* 80MiB */
-       };
-
-       partition@6000000 {
-               label = "rootfs2";
-               reg = <0x6000000 0x4a00000>; /* 74MiB */
-       };
-
-       /*
-        * 86MiB, last MiB is for the BBT, not writable
-        */
-       partition@aa00000 {
-               label = "syscfg";
-               reg = <0xaa00000 0x5600000>;
-       };
-
-       /*
-        * Unused area between "s_env" and "devinfo".
-        * Moved here because otherwise the renumbered
-        * partitions would break the bootloader
-        * supplied bootargs
-        */
-       partition@180000 {
-               label = "unused_area";
-               reg = <0x260000 0x5c0000>;   /* 5.75MiB */
+       partitions {
+               compatible = "fixed-partitions";
+               #address-cells = <1>;
+               #size-cells = <1>;
+
+               partition@0 {
+                       label = "u-boot";
+                       reg = <0x0000000 0x200000>;  /* 2MiB */
+                       read-only;
+               };
+
+               partition@200000 {
+                       label = "u_env";
+                       reg = <0x200000 0x20000>;    /* 128KiB */
+               };
+
+               partition@220000 {
+                       label = "s_env";
+                       reg = <0x220000 0x40000>;    /* 256KiB */
+               };
+
+               partition@7e0000 {
+                       label = "devinfo";
+                       reg = <0x7e0000 0x40000>;   /* 256KiB */
+                       read-only;
+               };
+
+               partition@820000 {
+                       label = "sysdiag";
+                       reg = <0x820000 0x1e0000>;   /* 1920KiB */
+                       read-only;
+               };
+
+               /* kernel1 overlaps with rootfs1 by design */
+               partition@a00000 {
+                       label = "kernel1";
+                       reg = <0xa00000 0x5000000>;  /* 80MiB */
+               };
+
+               partition@1000000 {
+                       label = "rootfs1";
+                       reg = <0x1000000 0x4a00000>;  /* 74MiB */
+               };
+
+               /* kernel2 overlaps with rootfs2 by design */
+               partition@5a00000 {
+                       label = "kernel2";
+                       reg = <0x5a00000 0x5000000>; /* 80MiB */
+               };
+
+               partition@6000000 {
+                       label = "rootfs2";
+                       reg = <0x6000000 0x4a00000>; /* 74MiB */
+               };
+
+               /*
+                * 86MiB, last MiB is for the BBT, not writable
+                */
+               partition@aa00000 {
+                       label = "syscfg";
+                       reg = <0xaa00000 0x5600000>;
+               };
+
+               /*
+                * Unused area between "s_env" and "devinfo".
+                * Moved here because otherwise the renumbered
+                * partitions would break the bootloader
+                * supplied bootargs
+                */
+               partition@180000 {
+                       label = "unused_area";
+                       reg = <0x260000 0x5c0000>;   /* 5.75MiB */
+               };
        };
 };
 
index 44f5aeb5fc33e824d2fb9c81e8ad16ba7fb13b1f..3451cd3e5dff9d47cf8a83190447d81ee81b2818 100644 (file)
 
 &nand {
        /* 128MiB */
-
-       partition@0 {
-               label = "u-boot";
-               reg = <0x0000000 0x200000>;  /* 2MiB */
-               read-only;
-       };
-
-       partition@100000 {
-               label = "u_env";
-               reg = <0x200000 0x40000>;    /* 256KiB */
-       };
-
-       partition@140000 {
-               label = "s_env";
-               reg = <0x240000 0x40000>;    /* 256KiB */
-       };
-
-       partition@900000 {
-               label = "devinfo";
-               reg = <0x900000 0x100000>;   /* 1MiB */
-               read-only;
-       };
-
-       /* kernel1 overlaps with rootfs1 by design */
-       partition@a00000 {
-               label = "kernel1";
-               reg = <0xa00000 0x2800000>;  /* 40MiB */
-       };
-
-       partition@1000000 {
-               label = "rootfs1";
-               reg = <0x1000000 0x2200000>;  /* 34MiB */
-       };
-
-       /* kernel2 overlaps with rootfs2 by design */
-       partition@3200000 {
-               label = "kernel2";
-               reg = <0x3200000 0x2800000>; /* 40MiB */
-       };
-
-       partition@3800000 {
-               label = "rootfs2";
-               reg = <0x3800000 0x2200000>; /* 34MiB */
-       };
-
-       /*
-        * 38MiB, last MiB is for the BBT, not writable
-        */
-       partition@5a00000 {
-               label = "syscfg";
-               reg = <0x5a00000 0x2600000>;
-       };
-
-       /*
-        * Unused area between "s_env" and "devinfo".
-        * Moved here because otherwise the renumbered
-        * partitions would break the bootloader
-        * supplied bootargs
-        */
-       partition@180000 {
-               label = "unused_area";
-               reg = <0x280000 0x680000>;   /* 6.5MiB */
+       partitions {
+               compatible = "fixed-partitions";
+               #address-cells = <1>;
+               #size-cells = <1>;
+
+               partition@0 {
+                       label = "u-boot";
+                       reg = <0x0000000 0x200000>;  /* 2MiB */
+                       read-only;
+               };
+
+               partition@100000 {
+                       label = "u_env";
+                       reg = <0x200000 0x40000>;    /* 256KiB */
+               };
+
+               partition@140000 {
+                       label = "s_env";
+                       reg = <0x240000 0x40000>;    /* 256KiB */
+               };
+
+               partition@900000 {
+                       label = "devinfo";
+                       reg = <0x900000 0x100000>;   /* 1MiB */
+                       read-only;
+               };
+
+               /* kernel1 overlaps with rootfs1 by design */
+               partition@a00000 {
+                       label = "kernel1";
+                       reg = <0xa00000 0x2800000>;  /* 40MiB */
+               };
+
+               partition@1000000 {
+                       label = "rootfs1";
+                       reg = <0x1000000 0x2200000>;  /* 34MiB */
+               };
+
+               /* kernel2 overlaps with rootfs2 by design */
+               partition@3200000 {
+                       label = "kernel2";
+                       reg = <0x3200000 0x2800000>; /* 40MiB */
+               };
+
+               partition@3800000 {
+                       label = "rootfs2";
+                       reg = <0x3800000 0x2200000>; /* 34MiB */
+               };
+
+               /*
+                * 38MiB, last MiB is for the BBT, not writable
+                */
+               partition@5a00000 {
+                       label = "syscfg";
+                       reg = <0x5a00000 0x2600000>;
+               };
+
+               /*
+                * Unused area between "s_env" and "devinfo".
+                * Moved here because otherwise the renumbered
+                * partitions would break the bootloader
+                * supplied bootargs
+                */
+               partition@180000 {
+                       label = "unused_area";
+                       reg = <0x280000 0x680000>;   /* 6.5MiB */
+               };
        };
 };
index 4a0d7360110b128f586aa67064ab2be618f60d60..827e82be220151ce8e74abdad5eea69061484cb4 100644 (file)
        };
 };
 
-&nand {
+&nand_controller {
        /* 128MiB or 256MiB */
        status = "okay";
-       num-cs = <1>;
-       marvell,nand-keep-config;
-       marvell,nand-enable-arbiter;
-       nand-on-flash-bbt;
+       #address-cells = <1>;
+       #size-cells = <0>;
+
+       nand: nand@0 {
+               reg = <0>;
+               label = "pxa3xx_nand-0";
+               nand-rb = <0>;
+               marvell,nand-keep-config;
+               nand-on-flash-bbt;
+       };
 };
 
 &mdio {
index 05250d426dc40e395bb3b375c1db8420d42facd5..a2bec07bf4c55190707952545e911b932954b9cd 100644 (file)
                                status = "okay";
                        };
 
-                       flash@d0000 {
-                               status = "okay";
-                               num-cs = <1>;
-                               marvell,nand-keep-config;
-                               marvell,nand-enable-arbiter;
-                               nand-on-flash-bbt;
-                               nand-ecc-strength = <4>;
-                               nand-ecc-step-size = <512>;
-
-                               partition@0 {
-                                       label = "U-Boot";
-                                       reg = <0 0x800000>;
-                               };
-                               partition@800000 {
-                                       label = "Linux";
-                                       reg = <0x800000 0x800000>;
-                               };
-                               partition@1000000 {
-                                       label = "Filesystem";
-                                       reg = <0x1000000 0x3f000000>;
-                               };
-                       };
-
                        sdhci@d8000 {
                                broken-cd;
                                wp-inverted;
        };
 };
 
+&nand_controller {
+       status = "okay";
+
+       nand@0 {
+               reg = <0>;
+               label = "pxa3xx_nand-0";
+               nand-rb = <0>;
+               marvell,nand-keep-config;
+               nand-on-flash-bbt;
+               nand-ecc-strength = <4>;
+               nand-ecc-step-size = <512>;
+
+               partitions {
+                       compatible = "fixed-partitions";
+                       #address-cells = <1>;
+                       #size-cells = <1>;
+
+                       partition@0 {
+                               label = "U-Boot";
+                               reg = <0 0x800000>;
+                       };
+                       partition@800000 {
+                               label = "Linux";
+                               reg = <0x800000 0x800000>;
+                       };
+                       partition@1000000 {
+                               label = "Filesystem";
+                               reg = <0x1000000 0x3f000000>;
+                       };
+               };
+       };
+};
index 4cc09e43eea22e65cd10be3503a84379d2f4e4a3..651d9edb91e6fac15fc702294655b997f04ad0b2 100644 (file)
                                status = "okay";
                        };
 
-                       nand: flash@d0000 {
-                               compatible = "marvell,armada370-nand";
+                       nand_controller: nand-controller@d0000 {
+                               compatible = "marvell,armada370-nand-controller";
                                reg = <0xd0000 0x54>;
                                #address-cells = <1>;
-                               #size-cells = <1>;
+                               #size-cells = <0>;
                                interrupts = <GIC_SPI 84 IRQ_TYPE_LEVEL_HIGH>;
                                clocks = <&coredivclk 0>;
                                status = "disabled";