[U-Boot] [PATCH v3 0/2] arm: marvell: sheevaplug: add FDT and fixes MTDPARTS

These series of patch : - fixes ENV and MTDPARTS for sheevaplug - add FDT support for sheevaplug - add the possibility to use a bootstrap from nand (bootscript)
Gerald Kerma (2): arm: marvell: add LIBFDT support to sheevaplug arm: marvell: fix ENV and MTDPARTS for sheevaplug
include/configs/sheevaplug.h | 62 ++++++++++++++++++++++++++++++-------------- 1 file changed, 42 insertions(+), 20 deletions(-)

This patch add LIBFDT support to Marvell Sheevaplug
Changes in v2: - mainline rebased Changes in v1: - add LIBFDT support
Signed-off-by: Gerald Kerma drEagle@doukki.net --- include/configs/sheevaplug.h | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/include/configs/sheevaplug.h b/include/configs/sheevaplug.h index 71be823..247789c 100644 --- a/include/configs/sheevaplug.h +++ b/include/configs/sheevaplug.h @@ -49,6 +49,12 @@ #define CONFIG_CMD_NAND #define CONFIG_CMD_PING #define CONFIG_CMD_USB + +/* +* Enable device tree support +*/ +#define CONFIG_OF_LIBFDT + /* * mv-common.h should be defined after CMD configs since it used them * to enable certain macros

Hi Prafulla,
Without LIBFDT feature, all newer kernel are unusable !
I agree with a review may be needed with : [PATCH v3 2/2] arm: marvell: fix ENV and MTDPARTS for sheevaplug is there any problem with : [PATCH v3 1/2] arm: marvell: add LIBFDT support to sheevaplug
Regards, Gérald
Le 25/10/2014 07:54, Gerald Kerma a écrit :
This patch add LIBFDT support to Marvell Sheevaplug
Changes in v2:
- mainline rebased
Changes in v1:
- add LIBFDT support
Signed-off-by: Gerald Kerma drEagle@doukki.net
include/configs/sheevaplug.h | 6 ++++++ 1 file changed, 6 insertions(+)
diff --git a/include/configs/sheevaplug.h b/include/configs/sheevaplug.h index 71be823..247789c 100644 --- a/include/configs/sheevaplug.h +++ b/include/configs/sheevaplug.h @@ -49,6 +49,12 @@ #define CONFIG_CMD_NAND #define CONFIG_CMD_PING #define CONFIG_CMD_USB
+/* +* Enable device tree support +*/ +#define CONFIG_OF_LIBFDT
/*
- mv-common.h should be defined after CMD configs since it used them
- to enable certain macros

This patch redefine ENV offset and MTDPARTS
Changes in v3: - add a bootstrap from nand - fix typo errors Changes in v2: - fix MTDPARTS typo errors Changes in v1: - define ENV offset to 0xe0000 - define MTDPARTS and BOOTARGS to stay backward compatibles
Signed-off-by: Gerald Kerma drEagle@doukki.net --- include/configs/sheevaplug.h | 56 ++++++++++++++++++++++++++++---------------- 1 file changed, 36 insertions(+), 20 deletions(-)
diff --git a/include/configs/sheevaplug.h b/include/configs/sheevaplug.h index 247789c..ef905bb 100644 --- a/include/configs/sheevaplug.h +++ b/include/configs/sheevaplug.h @@ -75,32 +75,48 @@ * it has to be rounded to sector size */ #define CONFIG_ENV_SIZE 0x20000 /* 128k */ -#define CONFIG_ENV_ADDR 0x80000 -#define CONFIG_ENV_OFFSET 0x80000 /* env starts here */ +#define CONFIG_ENV_ADDR 0xe0000 +#define CONFIG_ENV_OFFSET 0xe0000 /* env starts here */
/* * Default environment variables */ -#define CONFIG_BOOTCOMMAND "${x_bootcmd_kernel}; " \ - "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \ - "${x_bootcmd_usb}; bootm 0x6400000;"
#define CONFIG_MTDPARTS \ - "mtdparts=orion_nand:512K(uboot)," \ - "512K(env),1M(script),6M(kernel)," \ - "12M(ramdisk),4M(spare),-(rootfs)" - -#define CONFIG_EXTRA_ENV_SETTINGS "x_bootargs=console" \ - "=ttyS0,115200 mtdparts="CONFIG_MTDPARTS \ - "x_bootcmd_kernel=nand read 0x6400000 0x100000 0x300000\0" \ - "x_bootcmd_usb=usb start\0" \ - "x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2\0" - -#define MTDIDS_DEFAULT "nand0=orion_nand" - -#define MTDPARTS_DEFAULT \ - "mtdparts="CONFIG_MTDPARTS - + "mtdparts=orion_nand:" \ + "0xe0000@0x0(uboot)," \ + "0x20000@0xe0000(uboot_env)," \ + "3m@1m(kernel)," \ + "1m@4m(script)," \ + "-@5m(root)\0" + +#define MTDIDS_DEFAULT "nand0=orion_nand" + +#define MTDPARTS_DEFAULT CONFIG_MTDPARTS + +#define CONFIG_BOOTCOMMAND \ + "run z_bootcmd_script; run z_bootcmd_nand;" + +#define CONFIG_EXTRA_ENV_SETTINGS \ + "mtdparts="MTDPARTS_DEFAULT \ + "mtdids="MTDIDS_DEFAULT"\0" \ + "kernel=/boot/uImage\0" \ + "ramdisk=/boot/uInitrd\0" \ + "fdt=/boot/dtb\0" \ + "z_bootcmd_script=nand read 0x6400000 script;" \ + " setenv bootargs ${x_bootargs} ${x_bootargs_root};" \ + " run x_bootcmd_usb; run x_bootcmd_ide;" \ + " source 0x6400000;\0" \ + "z_bootcmd_nand=run x_bootcmd_nand_kernel;" \ + " setenv bootargs ${x_bootargs} ${x_bootargs_nand_root}; " \ + " run x_bootcmd_usb; bootm 0x6400000;\0" \ + "x_bootargs=console=ttyS0,115200 "CONFIG_MTDPARTS \ + "x_bootargs_root=root=LABEL=ROOTFS rw panic=5\0" \ + "x_bootcmd_usb=usb reset\0" \ + "x_bootcmd_ide=ide reset\0" \ + "x_bootargs_nand_root=root=/dev/mtdblock4 rw rootfstype=jffs2\0"\ + "x_bootcmd_nand_kernel=nand read 0x6400000 kernel\0" + /* * Ethernet Driver configuration */

Hi Prafulla,
Can anyone review these patches ?
Regards,
On 25/10/2014 07:54, Gerald Kerma wrote:
These series of patch :
- fixes ENV and MTDPARTS for sheevaplug
- add FDT support for sheevaplug
- add the possibility to use a bootstrap from nand (bootscript)
Gerald Kerma (2): arm: marvell: add LIBFDT support to sheevaplug arm: marvell: fix ENV and MTDPARTS for sheevaplug
include/configs/sheevaplug.h | 62 ++++++++++++++++++++++++++++++-------------- 1 file changed, 42 insertions(+), 20 deletions(-)
participants (2)
-
drEagle
-
Gerald Kerma