[U-Boot] [PATCH v11 18/30] nand: mxc: Switch NAND SPL to generic SPL
This also fixes support for mx31pdk and tx25, which had been broken by commit e05e5de7fae5bec79617e113916dac6631251156. Signed-off-by: Benoît Thébaudeau benoit.thebaud...@advansee.com Acked-by: Scott Wood scottw...@freescale.com Tested-by: Fabio Estevam fabio.este...@freescale.com --- Changes in v11: - mx31pdk: Rename u-boot-nand.bin to u-boot-with-spl.bin (new target binary name) in prg_uboot command. - mx31pdk: Enlarge CONFIG_SYS_NAND_U_BOOT_SIZE from 0x32000 to 0x3f800 (which corresponds to the size allocated for this purpose in NAND Flash) in order to leave enough room whatever the toolchain used. - mx31pdk: Set back CONFIG_SPL_TEXT_BASE and CONFIG_SYS_TEXT_BASE by 0x0010 because the original U-Boot at CONFIG_SYS_TEXT_BASE was overlapping the global data being written prior to relocation by arch/arm/lib/board.c:board_init_f(). Changes in v10: - Rebase on current u-boot-arm/master, especially following commits 3ebd1cb and 65cdd64, which make it necessary to change CONFIG_SPL_LDSCRIPT to arch/$(ARCH)/cpu/u-boot-spl.lds for mx31pdk.h and tx25.h. Changes in v9: None Changes in v8: - Update doc/README.arm-relocation. - Drop useless line feed at end of inline asm. - Set CONFIG_SYS_NAND_U_BOOT_OFFS to CONFIG_SPL_PAD_TO instead of CONFIG_SPL_MAX_SIZE (this is a cosmetic change since they now have the same value). - Enlarge CONFIG_SYS_NAND_U_BOOT_SIZE from 0x3 to 0x32000 to let u-boot.bin fit in for mx31pdk. Changes in v7: None Changes in v6: - Automate 'u-boot.imx' and 'SPL' make targets for all imx processors. - Move board_init_f() to board.c. - Get rid of board SPL linker scripts. - Define CONFIG_SYS_NAND_U_BOOT_OFFS as CONFIG_SPL_MAX_SIZE rather than duplicating the constant value. - Define CONFIG_SYS_NAND_U_BOOT_DST as CONFIG_SYS_TEXT_BASE rather than duplicating the constant value. - Pass 0 as the 1st argument to relocate_code() since it's unused. - Fix stack pointers. - Rebase on latest u-boot-imx/master. - Move unrelated changes to separate patches. Changes in v5: - Remove spaces between function name and open parenthesis. - Fix mx31pdk and tx25 Makefile-s and SPL linker scripts. - Remove the useless definition of CONFIG_SPL_LDSCRIPT. - Fix the call to nand_boot(). Changes in v4: - New patch. Changes in v3: None Changes in v2: None arch/arm/cpu/arm926ejs/start.S |3 +- board/freescale/mx31pdk/Makefile |3 + board/freescale/mx31pdk/config.mk |5 -- board/freescale/mx31pdk/mx31pdk.c |8 ++ board/karo/tx25/Makefile |4 +- board/karo/tx25/config.mk |5 -- board/karo/tx25/tx25.c |8 ++ boards.cfg |2 +- doc/README.arm-relocation | 14 ++-- drivers/mtd/nand/Makefile |1 + drivers/mtd/nand/mxc_nand.c| 10 +-- include/fsl_nfc.h = drivers/mtd/nand/mxc_nand.h | 10 +-- .../mtd/nand/mxc_nand_spl.c| 26 ++ include/configs/mx31pdk.h | 21 +++-- include/configs/tx25.h | 22 +++-- nand_spl/board/freescale/mx31pdk/Makefile | 63 -- nand_spl/board/freescale/mx31pdk/u-boot.lds| 87 nand_spl/board/karo/tx25/Makefile | 84 --- nand_spl/board/karo/tx25/config.mk |1 - nand_spl/board/karo/tx25/u-boot.lds| 87 20 files changed, 81 insertions(+), 383 deletions(-) delete mode 100644 board/freescale/mx31pdk/config.mk delete mode 100644 board/karo/tx25/config.mk rename include/fsl_nfc.h = drivers/mtd/nand/mxc_nand.h (98%) rename nand_spl/nand_boot_fsl_nfc.c = drivers/mtd/nand/mxc_nand_spl.c (92%) delete mode 100644 nand_spl/board/freescale/mx31pdk/Makefile delete mode 100644 nand_spl/board/freescale/mx31pdk/u-boot.lds delete mode 100644 nand_spl/board/karo/tx25/Makefile delete mode 100644 nand_spl/board/karo/tx25/config.mk delete mode 100644 nand_spl/board/karo/tx25/u-boot.lds diff --git a/arch/arm/cpu/arm926ejs/start.S b/arch/arm/cpu/arm926ejs/start.S index 552279f..0a9cf1d 100644 --- a/arch/arm/cpu/arm926ejs/start.S +++ b/arch/arm/cpu/arm926ejs/start.S @@ -200,7 +200,6 @@ reset: /*--*/ -#if !defined(CONFIG_SPL_BUILD) || defined(CONFIG_NAND_SPL) /* * void relocate_code (addr_sp, gd, addr_moni) * @@ -269,6 +268,8 @@ relocate_done: bx lr +#ifndef CONFIG_SPL_BUILD + _rel_dyn_start_ofs: .word __rel_dyn_start - _start _rel_dyn_end_ofs: diff --git a/board/freescale/mx31pdk/Makefile b/board/freescale/mx31pdk/Makefile index 5b7cafd..b910722 100644 --- a/board/freescale/mx31pdk/Makefile +++
Re: [U-Boot] [PATCH v11 18/30] nand: mxc: Switch NAND SPL to generic SPL
Hi Benoît, On Tue, 9 Apr 2013 21:48:47 +0200, Benoît Thébaudeau benoit.thebaud...@advansee.com wrote: This also fixes support for mx31pdk and tx25, which had been broken by commit e05e5de7fae5bec79617e113916dac6631251156. Signed-off-by: Benoît Thébaudeau benoit.thebaud...@advansee.com Acked-by: Scott Wood scottw...@freescale.com Tested-by: Fabio Estevam fabio.este...@freescale.com --- Changes in v11: - mx31pdk: Rename u-boot-nand.bin to u-boot-with-spl.bin (new target binary name) in prg_uboot command. - mx31pdk: Enlarge CONFIG_SYS_NAND_U_BOOT_SIZE from 0x32000 to 0x3f800 (which corresponds to the size allocated for this purpose in NAND Flash) in order to leave enough room whatever the toolchain used. - mx31pdk: Set back CONFIG_SPL_TEXT_BASE and CONFIG_SYS_TEXT_BASE by 0x0010 because the original U-Boot at CONFIG_SYS_TEXT_BASE was overlapping the global data being written prior to relocation by arch/arm/lib/board.c:board_init_f(). I gather this patch is exactly what finally worked for Fabio's mx31? Amicalement, -- Albert. ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v11 18/30] nand: mxc: Switch NAND SPL to generic SPL
Hi Albert, On Tuesday, April 9, 2013 10:17:04 PM, Albert ARIBAUD wrote: Hi Benoît, On Tue, 9 Apr 2013 21:48:47 +0200, Benoît Thébaudeau benoit.thebaud...@advansee.com wrote: This also fixes support for mx31pdk and tx25, which had been broken by commit e05e5de7fae5bec79617e113916dac6631251156. Signed-off-by: Benoît Thébaudeau benoit.thebaud...@advansee.com Acked-by: Scott Wood scottw...@freescale.com Tested-by: Fabio Estevam fabio.este...@freescale.com --- Changes in v11: - mx31pdk: Rename u-boot-nand.bin to u-boot-with-spl.bin (new target binary name) in prg_uboot command. - mx31pdk: Enlarge CONFIG_SYS_NAND_U_BOOT_SIZE from 0x32000 to 0x3f800 (which corresponds to the size allocated for this purpose in NAND Flash) in order to leave enough room whatever the toolchain used. - mx31pdk: Set back CONFIG_SPL_TEXT_BASE and CONFIG_SYS_TEXT_BASE by 0x0010 because the original U-Boot at CONFIG_SYS_TEXT_BASE was overlapping the global data being written prior to relocation by arch/arm/lib/board.c:board_init_f(). I gather this patch is exactly what finally worked for Fabio's mx31? Correct, apart from the file renaming in prg_uboot, which has no influence here. Best regards, Benoît ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v11 18/30] nand: mxc: Switch NAND SPL to generic SPL
On Tuesday, April 9, 2013 10:57:04 PM, Benoît Thébaudeau wrote: Hi Albert, On Tuesday, April 9, 2013 10:17:04 PM, Albert ARIBAUD wrote: Hi Benoît, On Tue, 9 Apr 2013 21:48:47 +0200, Benoît Thébaudeau benoit.thebaud...@advansee.com wrote: This also fixes support for mx31pdk and tx25, which had been broken by commit e05e5de7fae5bec79617e113916dac6631251156. Signed-off-by: Benoît Thébaudeau benoit.thebaud...@advansee.com Acked-by: Scott Wood scottw...@freescale.com Tested-by: Fabio Estevam fabio.este...@freescale.com --- Changes in v11: - mx31pdk: Rename u-boot-nand.bin to u-boot-with-spl.bin (new target binary name) in prg_uboot command. - mx31pdk: Enlarge CONFIG_SYS_NAND_U_BOOT_SIZE from 0x32000 to 0x3f800 (which corresponds to the size allocated for this purpose in NAND Flash) in order to leave enough room whatever the toolchain used. - mx31pdk: Set back CONFIG_SPL_TEXT_BASE and CONFIG_SYS_TEXT_BASE by 0x0010 because the original U-Boot at CONFIG_SYS_TEXT_BASE was overlapping the global data being written prior to relocation by arch/arm/lib/board.c:board_init_f(). I gather this patch is exactly what finally worked for Fabio's mx31? Correct, apart from the file renaming in prg_uboot, which has no influence here. And with: http://patchwork.ozlabs.org/patch/235173/ Best regards, Benoît ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot