ARM device tree support improvements
Subsystems (4)
cover ARM device tree support improvements
Hi Jerry & Wolfgang,
The following series fixes a bug in the device tree code and eliminates the CONFIG_OF_LIBFDT dependency on CONFIG_SYS_BOOTMAPSZ. It also adds parsing of the reserved mem regions so that U-Boot doesn't decide to use a regions set aside for another purpose.
Finally, the last patch adds CONFIG_OF_LIBFDT to a bunch of boards. I'm not expecting the last patch to be picked up in mainline (yet), but it will be picked up into the Linaro tree for the 11.05 release.
John, this same series applies cleanly on the linaro-stable u-boot tree. Can you pick them up please? Or would you prefer me to send you a pull request?
g.
---
Grant Likely (6):
Stop passing around bootmem_base value.
Default to bootm_size() when CONFIG_SYS_BOOTMAPSZ is not defined Remove device tree booting dependency on CONFIG_SYS_BOOTMAPSZ Fix off-by-one error in passing initrd end address via device tree Respect memreserve regions specified in the device tree Add CONFIG_OF_LIBFDT to more boards.
README | 16 ++++++++- arch/arm/lib/bootm.c | 5 ++- arch/m68k/lib/bootm.c | 7 +--- arch/powerpc/lib/bootm.c | 19 +++++----- common/cmd_bootm.c | 7 ++-- common/fdt_support.c | 2 + common/image.c | 72 +++++++++++++++++++++++++++++---------- include/configs/ca9x4_ct_vxp.h | 2 + include/configs/devkit8000.h | 2 + include/configs/efikamx.h | 2 + include/configs/igep0020.h | 2 + include/configs/igep0030.h | 2 + include/configs/mx51evk.h | 2 + include/configs/mx53evk.h | 2 + include/configs/omap3_beagle.h | 7 ---- include/configs/omap3_overo.h | 2 + include/configs/omap3_pandora.h | 2 + include/configs/omap3_sdp3430.h | 2 + include/configs/omap3_zoom1.h | 2 + include/configs/omap3_zoom2.h | 2 + include/configs/omap4_panda.h | 2 + include/configs/omap4_sdp4430.h | 2 + include/configs/tegra2-common.h | 1 + include/image.h | 10 +++-- 24 files changed, 122 insertions(+), 52 deletions(-)
Signature · 1 line
Signature
PATCH 1/6 Stop passing around bootmem_base value.
From: Grant Likely <[email protected]>
For the calls to boot_relocate_fdt(), boot_get_cmdline(), and boot_get_kbd(), the value of bootmem_base is always obtained by calling getenv_bootm_low(). Since the value always comes from the same source, the calling signature for those functions can be simplified by making them call getenv_bootm_low() directly.
--- arch/arm/lib/bootm.c | 3 +-- arch/m68k/lib/bootm.c | 7 ++----- arch/powerpc/lib/bootm.c | 9 +++------ common/cmd_bootm.c | 3 +-- common/image.c | 25 +++++++++---------------- include/image.h | 8 +++----- 6 files changed, 19 insertions(+), 36 deletions(-)
arch/arm/lib/bootm.c +1 -2
@@ -178,7 +178,6 @@ static int bootm_linux_fdt(int machid, bootm_headers_t *images) {ulong rd_len;void (*kernel_entry)(int zero,int dt_machid,void *dtblob); -ulong bootmap_base =getenv_bootm_low ();ulong of_size = images->ft_len;char **of_flat_tree = &images->ft_addr;ulong *initrd_start = &images->initrd_start;
@@ -194,7 +193,7 @@ static int bootm_linux_fdt(int machid, bootm_headers_t *images)if (ret)return ret; - ret =boot_relocate_fdt (lmb, bootmap_base, of_flat_tree, &of_size); + ret =boot_relocate_fdt (lmb, of_flat_tree, &of_size);if (ret)return ret;
arch/m68k/lib/bootm.c +2 -5
@@ -71,7 +71,6 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imaint ret;ulong cmd_start, cmd_end; -ulong bootmap_base;bd_t *kbd;void (*kernel) (bd_t *,ulong ,ulong ,ulong ,ulong );struct lmb *lmb = &images->lmb;
@@ -79,17 +78,15 @@ int do_bootm_linux(int flag, int argc, char * const argv[], bootm_headers_t *imaif ((flag !=0 ) && (flag !=BOOTM_STATE_OS_GO ))return 1 ; - bootmap_base =getenv_bootm_low (); -/* allocate space and init command line */ - ret =boot_get_cmdline (lmb, &cmd_start, &cmd_end, bootmap_base); + ret =boot_get_cmdline (lmb, &cmd_start, &cmd_end);if (ret) {puts ("ERROR with allocation of cmdline\n" ); goto error; }/* allocate space for kernel copy of board info */ - ret =boot_get_kbd (lmb, &kbd, bootmap_base); + ret =boot_get_kbd (lmb, &kbd);if (ret) {puts ("ERROR with allocation of kernel bd\n" ); goto error;
arch/powerpc/lib/bootm.c +3 -6
@@ -181,7 +181,6 @@ static void boot_prep_linux(void)static int boot_cmdline_linux (bootm_headers_t *images) { -ulong bootmap_base =getenv_bootm_low ();ulong of_size = images->ft_len;struct lmb *lmb = &images->lmb;ulong *cmd_start = &images->cmdline_start;
@@ -191,7 +190,7 @@ static int boot_cmdline_linux(bootm_headers_t *images)if (!of_size) {/* allocate space and init command line */ - ret =boot_get_cmdline (lmb, cmd_start, cmd_end, bootmap_base); + ret =boot_get_cmdline (lmb, cmd_start, cmd_end);if (ret) {puts ("ERROR with allocation of cmdline\n" );return ret;
@@ -203,7 +202,6 @@ static int boot_cmdline_linux(bootm_headers_t *images)static int boot_bd_t_linux (bootm_headers_t *images) { -ulong bootmap_base =getenv_bootm_low ();ulong of_size = images->ft_len;struct lmb *lmb = &images->lmb;bd_t **kbd = &images->kbd;
@@ -212,7 +210,7 @@ static int boot_bd_t_linux(bootm_headers_t *images)if (!of_size) {/* allocate space for kernel copy of board info */ - ret =boot_get_kbd (lmb, kbd, bootmap_base); + ret =boot_get_kbd (lmb, kbd);if (ret) {puts ("ERROR with allocation of kernel bd\n" );return ret;
@@ -230,7 +228,6 @@ static int boot_body_linux(bootm_headers_t *images)ulong *initrd_start = &images->initrd_start;ulong *initrd_end = &images->initrd_end;#if defined(CONFIG_OF_LIBFDT ) -ulong bootmap_base =getenv_bootm_low ();ulong of_size = images->ft_len;char **of_flat_tree = &images->ft_addr;#endif
@@ -253,7 +250,7 @@ static int boot_body_linux(bootm_headers_t *images)return ret;#if defined(CONFIG_OF_LIBFDT ) && defined(CONFIG_SYS_BOOTMAPSZ ) - ret =boot_relocate_fdt (lmb, bootmap_base, of_flat_tree, &of_size); + ret =boot_relocate_fdt (lmb, of_flat_tree, &of_size);if (ret)return ret;
common/cmd_bootm.c +1 -2
@@ -547,8 +547,7 @@ int do_bootm_subcommand (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv#if defined(CONFIG_OF_LIBFDT ) && defined(CONFIG_SYS_BOOTMAPSZ )case BOOTM_STATE_FDT : { -ulong bootmap_base =getenv_bootm_low (); - ret =boot_relocate_fdt (&images.lmb, bootmap_base, + ret =boot_relocate_fdt (&images.lmb, &images.ft_addr, &images.ft_len);break ; }
common/image.c +9 -16
@@ -1172,7 +1172,6 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)/** * boot_relocate_fdt - relocate flat device tree * @lmb: pointer to lmb handle, will be used for memory mgmt -* @bootmap_base: base address of the bootmap region * @of_flat_tree: pointer to a char* variable, will hold fdt start address * @of_size: pointer to a ulong variable, will hold fdt length *
@@ -1188,8 +1187,7 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)* 1 - failure */ #if defined(CONFIG_SYS_BOOTMAPSZ ) -int boot_relocate_fdt (struct lmb *lmb,ulong bootmap_base, -char **of_flat_tree,ulong *of_size) +int boot_relocate_fdt (struct lmb *lmb,char **of_flat_tree,ulong *of_size) {void *fdt_blob = *of_flat_tree;void *of_start =0 ;
@@ -1209,7 +1207,7 @@ int boot_relocate_fdt (struct lmb *lmb, ulong bootmap_base,/* Pad the FDT by a specified amount */ of_len = *of_size +CONFIG_SYS_FDT_PAD ; of_start = (void *)(unsigned long )lmb_alloc_base (lmb, of_len,0x1000 , - (CONFIG_SYS_BOOTMAPSZ + bootmap_base)); +CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ());if (of_start ==0 ) {puts ("device tree - allocation error\n" );
@@ -1567,11 +1565,9 @@ error:* @lmb: pointer to lmb handle, will be used for memory mgmt * @cmd_start: pointer to a ulong variable, will hold cmdline start * @cmd_end: pointer to a ulong variable, will hold cmdline end -* @bootmap_base: ulong variable, holds offset in physical memory to -* base of bootmap * * boot_get_cmdline() allocates space for kernel command line below -* BOOTMAPSZ + bootmap_base address. If "bootargs" U-boot environemnt +* BOOTMAPSZ + getenv_bootm_low() address. If "bootargs" U-boot environemnt * variable is present its contents is copied to allocated kernel * command line. *
@@ -1579,14 +1575,13 @@ error:* 0 - success * -1 - failure */ -int boot_get_cmdline (struct lmb *lmb,ulong *cmd_start,ulong *cmd_end, -ulong bootmap_base) +int boot_get_cmdline (struct lmb *lmb,ulong *cmd_start,ulong *cmd_end) {char *cmdline;char *s; cmdline = (char *)(ulong )lmb_alloc_base (lmb,CONFIG_SYS_BARGSIZE ,0xf , -CONFIG_SYS_BOOTMAPSZ + bootmap_base); +CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ());if (cmdline ==NULL )return -1 ;
@@ -1610,21 +1605,19 @@ int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end,* boot_get_kbd - allocate and initialize kernel copy of board info * @lmb: pointer to lmb handle, will be used for memory mgmt * @kbd: double pointer to board info data -* @bootmap_base: ulong variable, holds offset in physical memory to -* base of bootmap * * boot_get_kbd() allocates space for kernel copy of board info data below -* BOOTMAPSZ + bootmap_base address and kernel board info is initialized with -* the current u-boot board info data. +* BOOTMAPSZ + getenv_bootm_low() address and kernel board info is initialized +* with the current u-boot board info data. * * returns: * 0 - success * -1 - failure */ -int boot_get_kbd (struct lmb *lmb,bd_t **kbd,ulong bootmap_base) +int boot_get_kbd (struct lmb *lmb,bd_t **kbd) { *kbd = (bd_t *)(ulong )lmb_alloc_base (lmb,sizeof (bd_t),0xf , -CONFIG_SYS_BOOTMAPSZ + bootmap_base); +CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ());if (*kbd ==NULL )return -1 ;
include/image.h +3 -5
@@ -336,8 +336,7 @@ int boot_get_ramdisk (int argc, char * const argv[], bootm_headers_t *images,#ifdef CONFIG_OF_LIBFDT int boot_get_fdt (int flag,int argc,char *const argv[],bootm_headers_t *images,char **of_flat_tree,ulong *of_size); -int boot_relocate_fdt (struct lmb *lmb,ulong bootmap_base, -char **of_flat_tree,ulong *of_size); +int boot_relocate_fdt (struct lmb *lmb,char **of_flat_tree,ulong *of_size);#endif #ifdef CONFIG_SYS_BOOT_RAMDISK_HIGH
@@ -345,11 +344,10 @@ int boot_ramdisk_high (struct lmb *lmb, ulong rd_data, ulong rd_len, ulong *initrd_start, ulong *initrd_end);#endif /* CONFIG_SYS_BOOT_RAMDISK_HIGH */ #ifdef CONFIG_SYS_BOOT_GET_CMDLINE -int boot_get_cmdline (struct lmb *lmb,ulong *cmd_start,ulong *cmd_end, -ulong bootmap_base); +int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end)#endif /* CONFIG_SYS_BOOT_GET_CMDLINE */ #ifdef CONFIG_SYS_BOOT_GET_KBD -int boot_get_kbd (struct lmb *lmb,bd_t **kbd,ulong bootmap_base); +int boot_get_kbd (struct lmb *lmb,bd_t **kbd);#endif /* CONFIG_SYS_BOOT_GET_KBD */ #endif /* !USE_HOSTCC */
PATCH 1/6 Stop passing around bootmem_base value.
Hi Grant,
Quoted 9 lines · Grant Likely
From: Grant Likely<[email protected]>
For the calls to
boot_relocate_fdt(),boot_get_cmdline(), andboot_get_kbd(), the value ofbootmem_baseis always obtained by callinggetenv_bootm_low(). Since the value always comes from the same source, the calling signature for those functions can be simplified by making them callgetenv_bootm_low()directly.Signed-off-by Grant Likely<[email protected]>
[snip]
Quoted 4 lines
include/image.h +0
-0
[snip]
include/image.h int boot_ramdisk_high (struct lmb *lmb, ulong rd_data, ulong rd_len, · line 347
Quoted 7 lines
include/image.h +1
-2@@ -345,11 +344,10 @@ int boot_ramdisk_high (struct lmb *lmb, ulong rd_data, ulong rd_len, ulong *initrd_start, ulong *initrd_end);#endif /* CONFIG_SYS_BOOT_RAMDISK_HIGH */ #ifdef CONFIG_SYS_BOOT_GET_CMDLINE -int boot_get_cmdline (struct lmb *lmb,ulong *cmd_start,ulong *cmd_end, -ulong bootmap_base); +int boot_get_cmdline (struct lmb *lmb,ulong *cmd_start,ulong *cmd_end)
___________________________________________________________________________^
D'oh, you lost a semicolon. Compiles for ARM, not so well for PowerPC.
Took me a bit of staring and head scratching to see the missing piece
(the hardest thing to see is the thing that isn't there).
I'm having a problem with patch 2 of 6 as well, getenv_bootm_base() not found for PowerPC, apparently the code isn't used in ARM.
Thanks,
gvb
PATCH 2/6 Default to bootm_size() when CONFIG_SYS_BOOTMAPSZ is not defined
In reply to Grant LikelyFrom: Grant Likely <[email protected]>
This patch adds a function getenv_bootm_mapsize() for obtaining the size of the early mapped region accessible by the kernel during early boot. It defaults to CONFIG_SYS_BOOTMAPSZ, or if not defined, defaults to getenv_bootm_size(), which in turn defaults to the size of RAM.
getenv_bootm_mapsize() can also be overridden with a "bootm_mapsize" environmental variable.
--- README | 16 ++++++++++++++-- arch/powerpc/lib/bootm.c | 2 +- common/image.c | 22 +++++++++++++++++++--- include/image.h | 1 + 4 files changed, 35 insertions(+), 6 deletions(-)
README +14 -2
@@ -2311,7 +2311,10 @@ Configuration Settings: used) must be put below this limit, unless "bootm_low" enviroment variable is defined and non-zero. In such case all data for the Linux kernel must be between "bootm_low" - and "bootm_low" + CONFIG_SYS_BOOTMAPSZ. + and "bootm_low" + CONFIG_SYS_BOOTMAPSZ. The environment + variable "bootm_mapsize" will override the value of + CONFIG_SYS_BOOTMAPSZ. If CONFIG_SYS_BOOTMAPSZ is undefined, + then the value in "bootm_size" will be used instead. - CONFIG_SYS_BOOT_RAMDISK_HIGH: Enable initrd_high functionality. If defined then the
@@ -3147,7 +3150,16 @@ List of environment variables (most likely not complete): for use by the bootm command. See also "bootm_size" environment variable. Address defined by "bootm_low" is also the base of the initial memory mapping for the Linux - kernel -- see the description of CONFIG_SYS_BOOTMAPSZ. + kernel -- see the description of CONFIG_SYS_BOOTMAPSZ and + bootm_mapsize. + + bootm_mapsize - Size of the initial memory mapping for the Linux kernel. + This variable is given as a hexadecimal number and it + defines the size of the memory region starting at base + address bootm_low that is accessible by the Linux kernel + during early boot. If unset, CONFIG_SYS_BOOTMAPSZ is used + as the default value if it is defined, and bootm_size is + used otherwise. bootm_size - Memory range available for image processing in the bootm command can be restricted. This variable is given as
arch/powerpc/lib/bootm.c +1 -1
@@ -95,7 +95,7 @@ static void boot_jump_linux(bootm_headers_t *images)debug (" Booting using OF flat tree...\n" );WATCHDOG_RESET (); (*kernel) ((bd_t *)of_flat_tree,0 ,0 ,EPAPR_MAGIC , -CONFIG_SYS_BOOTMAPSZ ,0 ,0 ); +getenv_bootm_mapsize (),0 ,0 );/* does not return */ } else#endif
common/image.c +19 -3
@@ -454,6 +454,22 @@ phys_size_t getenv_bootm_size(void)#endif } +phys_size_t getenv_bootm_mapsize (void ) +{ +phys_size_t tmp; +char *s =getenv ("bootm_mapsize" ); +if (s) { + tmp = (phys_size_t )simple_strtoull (s,NULL ,16 ); +return tmp; + } + +#if defined(CONFIG_SYS_BOOTMAPSZ ) +return CONFIG_SYS_BOOTMAPSZ ; +#else +return getenv_bootm_size (); +#endif +} +void memmove_wd (void *to,void *from,size_t len,ulong chunksz) {if (to == from)
@@ -1207,7 +1223,7 @@ int boot_relocate_fdt (struct lmb *lmb, char **of_flat_tree, ulong *of_size)/* Pad the FDT by a specified amount */ of_len = *of_size +CONFIG_SYS_FDT_PAD ; of_start = (void *)(unsigned long )lmb_alloc_base (lmb, of_len,0x1000 , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_low ());if (of_start ==0 ) {puts ("device tree - allocation error\n" );
@@ -1581,7 +1597,7 @@ int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end)char *s; cmdline = (char *)(ulong )lmb_alloc_base (lmb,CONFIG_SYS_BARGSIZE ,0xf , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_base ());if (cmdline ==NULL )return -1 ;
@@ -1617,7 +1633,7 @@ int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end)int boot_get_kbd (struct lmb *lmb,bd_t **kbd) { *kbd = (bd_t *)(ulong )lmb_alloc_base (lmb,sizeof (bd_t),0xf , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_low ());if (*kbd ==NULL )return -1 ;
include/image.h +1 -0
@@ -451,6 +451,7 @@ int image_check_dcrc (const image_header_t *hdr);int getenv_yesno (char *var);ulong getenv_bootm_low (void );phys_size_t getenv_bootm_size (void ); +phys_size_t getenv_bootm_mapsize (void );void memmove_wd (void *to,void *from,size_t len,ulong chunksz);#endif
PATCH 2/6 Default to bootm_size() when CONFIG_SYS_BOOTMAPSZ is not defined
Hi Grant,
Quoted 18 lines · Grant Likely
From: Grant Likely<[email protected]>
This patch adds a function
getenv_bootm_mapsize()for obtaining the size of the early mapped region accessible by the kernel during early boot. It defaults toCONFIG_SYS_BOOTMAPSZ, or if not defined, defaults togetenv_bootm_size(), which in turn defaults to the size of RAM.
getenv_bootm_mapsize()can also be overridden with a "bootm_mapsize" environmental variable.Signed-off-by Grant Likely<[email protected]>--- README | 16 ++++++++++++++-- arch/powerpc/lib/bootm.c | 2 +- common/image.c | 22 +++++++++++++++++++--- include/image.h | 1 + 4 files changed, 35 insertions(+), 6 deletions(-)
[snip]
common/image.c int boot_relocate_fdt (struct lmb *lmb, char **of_flat_tree, ulong *of_size) · line 1226
Quoted 6 lines
common/image.c +1
-1@@ -1207,7 +1223,7 @@ int boot_relocate_fdt (struct lmb *lmb, char **of_flat_tree, ulong *of_size)/* Pad the FDT by a specified amount */ of_len = *of_size +CONFIG_SYS_FDT_PAD ; of_start = (void *)(unsigned long )lmb_alloc_base (lmb, of_len,0x1000 , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_low ());
_________________________________________________^^^^^^^^^^^^^^^^^^
common/image.c int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end) · line 1600
Quoted 9 lines
common/image.c +1
-1if (of_start ==0 ) {puts ("device tree - allocation error\n" );@@ -1581,7 +1597,7 @@ int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end)char *s; cmdline = (char *)(ulong )lmb_alloc_base (lmb,CONFIG_SYS_BARGSIZE ,0xf , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_base ());
_________________________________________________________^^^^^^^^^^^^^^^^^^
getenv_bootm_base() doesn't exist in my tree, should it have been getenv_bootm_low()?
common/image.c int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end) · line 1636
Quoted 8 lines
common/image.c +1
-1if (cmdline ==NULL )return -1 ;@@ -1617,7 +1633,7 @@ int boot_get_cmdline (struct lmb *lmb, ulong *cmd_start, ulong *cmd_end)int boot_get_kbd (struct lmb *lmb,bd_t **kbd) { *kbd = (bd_t *)(ulong )lmb_alloc_base (lmb,sizeof (bd_t),0xf , -CONFIG_SYS_BOOTMAPSZ +getenv_bootm_low ()); +getenv_bootm_mapsize () +getenv_bootm_low ());
_________________________________________________________^^^^^^^^^^^^^^^^^^
I don't have access to my 8360 board at the moment to execute test the code. :-/
[snip]
Thanks,
gvb
PATCH 3/6 Remove device tree booting dependency on CONFIG_SYS_BOOTMAPSZ
In reply to Grant LikelyFrom: Grant Likely <[email protected]>
The previous patch makes u-boot use the full accessible size of ram as the default boot mapped size if CONFIG_SYS_BOOTMAPSZ is not defined, which means boot_relocate_fdt() can be changed to depend solely on CONFIG_OF_LIBFDT.
--- arch/powerpc/lib/bootm.c | 4 ++-- common/cmd_bootm.c | 2 +- common/image.c | 4 ++-- include/configs/omap3_beagle.h | 7 ------- 4 files changed, 5 insertions(+), 12 deletions(-)
arch/powerpc/lib/bootm.c +2 -2
@@ -249,7 +249,7 @@ static int boot_body_linux(bootm_headers_t *images)if (ret)return ret; -#if defined(CONFIG_OF_LIBFDT ) && defined(CONFIG_SYS_BOOTMAPSZ ) +#if defined(CONFIG_OF_LIBFDT ) ret =boot_relocate_fdt (lmb, of_flat_tree, &of_size);if (ret)return ret;
@@ -288,7 +288,7 @@ static int boot_body_linux(bootm_headers_t *images)if (*initrd_start && *initrd_end) fdt_initrd(*of_flat_tree, *initrd_start, *initrd_end, 1); } -#endif /* CONFIG_OF_LIBFDT && CONFIG_SYS_BOOTMAPSZ */ +#endif /* CONFIG_OF_LIBFDT */ return 0 ; }
common/cmd_bootm.c +1 -1
@@ -544,7 +544,7 @@ int do_bootm_subcommand (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv }break ;#endif -#if defined(CONFIG_OF_LIBFDT ) && defined(CONFIG_SYS_BOOTMAPSZ ) +#if defined(CONFIG_OF_LIBFDT )case BOOTM_STATE_FDT : { ret = boot_relocate_fdt(&images.lmb,
common/image.c +2 -2
@@ -1202,7 +1202,7 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)* 0 - success * 1 - failure */ -#if defined(CONFIG_SYS_BOOTMAPSZ ) +#if defined(CONFIG_OF_LIBFDT )int boot_relocate_fdt (struct lmb *lmb,char **of_flat_tree,ulong *of_size) {void *fdt_blob = *of_flat_tree;
@@ -1252,7 +1252,7 @@ int boot_relocate_fdt (struct lmb *lmb, char **of_flat_tree, ulong *of_size) error: return 1; } -#endif /* CONFIG_SYS_BOOTMAPSZ */ +#endif /* CONFIG_OF_LIBFDT */ /** * boot_get_fdt - main fdt handling routine
include/configs/omap3_beagle.h +0 -7
@@ -56,13 +56,6 @@#define CONFIG_MISC_INIT_R #define CONFIG_OF_LIBFDT 1 -/* -* The early kernel mapping on ARM currently only maps from the base of DRAM -* to the end of the kernel image. The kernel is loaded at DRAM base + 0x8000. -* The early kernel pagetable uses DRAM base + 0x4000 to DRAM base + 0x8000, -* so that leaves DRAM base to DRAM base + 0x4000 available. -*/ -#define CONFIG_SYS_BOOTMAPSZ 0x4000#define CONFIG_CMDLINE_TAG 1/* enable passing of ATAGs */ #define CONFIG_SETUP_MEMORY_TAGS 1
PATCH 4/6 Fix off-by-one error in passing initrd end address via device tree
In reply to Grant LikelyFrom: Grant Likely <[email protected]>
The initrd_end variable contains the address immediately *after* the initrd blob, not the last address containing data. This patch fixes an inadvertent off-by-one when setting up the initrd reserved map.
--- common/fdt_support.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
common/fdt_support.c +1 -1
@@ -183,7 +183,7 @@ int fdt_initrd(void *fdt, ulong initrd_start, ulong initrd_end, int force) } } - err =fdt_add_mem_rsv (fdt, initrd_start, initrd_end - initrd_start +1 ); + err =fdt_add_mem_rsv (fdt, initrd_start, initrd_end - initrd_start);if (err <0 ) {printf ("fdt_initrd: %s\n" ,fdt_strerror (err));return err;
PATCH 5/6 Respect memreserve regions specified in the device tree
In reply to Grant LikelyFrom: Grant Likely <[email protected]>
If a regions is reserved in the fdt, then it should not be used. Add the memreserve regions to the lmb so that u-boot doesn't use them to store the initrd.
--- arch/arm/lib/bootm.c | 2 ++ arch/powerpc/lib/bootm.c | 4 ++++ common/cmd_bootm.c | 2 ++ common/image.c | 29 ++++++++++++++++++++++++++++- include/image.h | 1 + 5 files changed, 37 insertions(+), 1 deletions(-)
arch/arm/lib/bootm.c +2 -0
@@ -187,6 +187,8 @@ static int bootm_linux_fdt(int machid, bootm_headers_t *images) kernel_entry = (void (*)(int ,int ,void *))images->ep; +boot_fdt_add_mem_rsv_regions (lmb, *of_flat_tree); + rd_len = images->rd_end - images->rd_start; ret =boot_ramdisk_high (lmb, images->rd_start, rd_len, initrd_start, initrd_end);
arch/powerpc/lib/bootm.c +4 -0
@@ -234,6 +234,10 @@ static int boot_body_linux(bootm_headers_t *images)int ret; +#if defined(CONFIG_OF_LIBFDT ) +boot_fdt_add_mem_rsv_regions (lmb, *of_flat_tree); +#endif +/* allocate space and init command line */ ret =boot_cmdline_linux (images);if (ret)
common/cmd_bootm.c +2 -0
@@ -547,6 +547,8 @@ int do_bootm_subcommand (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv#if defined(CONFIG_OF_LIBFDT )case BOOTM_STATE_FDT : { +boot_fdt_add_mem_rsv_regions (&images.lmb, + images.ft_addr); ret =boot_relocate_fdt (&images.lmb, &images.ft_addr, &images.ft_len);break ;
common/image.c +28 -1
@@ -1185,6 +1185,34 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)#define CONFIG_SYS_FDT_PAD 0x3000#endif +#if defined(CONFIG_OF_LIBFDT ) +/** +* boot_fdt_add_mem_rsv_regions - Mark the memreserve sections as unusable +* @lmb: pointer to lmb handle, will be used for memory mgmt +* @fdt_blob: pointer to fdt blob base address +* +* Adds the memreserve regions in the dtb to the lmb block. Adding the +* memreserve regions prevents u-boot from using them to store the initrd +* or the fdt blob. +*/ +void boot_fdt_add_mem_rsv_regions (struct lmb *lmb,void *fdt_blob) +{ +uint64_t addr, size; +int i, total; + +if (fdt_check_header (fdt_blob) !=0 ) +return ; + + total =fdt_num_mem_rsv (fdt_blob); +for (i =0 ; i < total; i++) { +if (fdt_get_mem_rsv (fdt_blob, i, &addr, &size) !=0 ) +continue ; +printf (" reserving fdt memory region: addr=%llx size=%llx\n" , + (unsigned long long )addr, (unsigned long long )size); +lmb_reserve (lmb, addr, size); + } +} +/** * boot_relocate_fdt - relocate flat device tree * @lmb: pointer to lmb handle, will be used for memory mgmt
@@ -1202,7 +1230,6 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)* 0 - success * 1 - failure */ -#if defined(CONFIG_OF_LIBFDT )int boot_relocate_fdt (struct lmb *lmb,char **of_flat_tree,ulong *of_size) {void *fdt_blob = *of_flat_tree;
include/image.h +1 -0
@@ -336,6 +336,7 @@ int boot_get_ramdisk (int argc, char * const argv[], bootm_headers_t *images,#ifdef CONFIG_OF_LIBFDT int boot_get_fdt (int flag,int argc,char *const argv[],bootm_headers_t *images,char **of_flat_tree,ulong *of_size); +void boot_fdt_add_mem_rsv_regions (struct lmb *lmb,void *fdt_blob);int boot_relocate_fdt (struct lmb *lmb,char **of_flat_tree,ulong *of_size);#endif
PATCH 6/6 Add CONFIG_OF_LIBFDT to more boards.
In reply to Grant LikelyFrom: Grant Likely <[email protected]>
The following boards gain device tree support with this patch:
ca9x4_ct_vxp - Versatile Express
i.mx5 boards:
efikamx
mx51evk
mx53evk
OMAP boards:
devkit8000
igep0020
igep0030omap3_overoomap3_pandoraomap4_sdp3430omap3_zoom1omap3_zoom2omap4_pandaomap4_sdp4430
Tegra boards:
Harmony
--- include/configs/ca9x4_ct_vxp.h | 2 ++ include/configs/devkit8000.h | 2 ++ include/configs/efikamx.h | 2 ++ include/configs/igep0020.h | 2 ++ include/configs/igep0030.h | 2 ++ include/configs/mx51evk.h | 2 ++ include/configs/mx53evk.h | 2 ++ include/configs/omap3_overo.h | 2 ++ include/configs/omap3_pandora.h | 2 ++ include/configs/omap3_sdp3430.h | 2 ++ include/configs/omap3_zoom1.h | 2 ++ include/configs/omap3_zoom2.h | 2 ++ include/configs/omap4_panda.h | 2 ++ include/configs/omap4_sdp4430.h | 2 ++ include/configs/tegra2-common.h | 1 + 15 files changed, 29 insertions(+), 0 deletions(-)
include/configs/ca9x4_ct_vxp.h +2 -0
@@ -43,6 +43,8 @@#define CONFIG_L2_OFF 1#define CONFIG_INITRD_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* Size of malloc() pool */ #define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 128 * 1024)
include/configs/devkit8000.h +2 -0
@@ -61,6 +61,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* Size of malloc() pool */ #define CONFIG_ENV_SIZE (128 << 10)/* 128 KiB */ /* Sector */
include/configs/efikamx.h +2 -0
@@ -66,6 +66,8 @@#define CONFIG_SETUP_MEMORY_TAGS #define CONFIG_INITRD_TAG +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/igep0020.h +2 -0
@@ -53,6 +53,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * NS16550 Configuration */
include/configs/igep0030.h +2 -0
@@ -53,6 +53,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * NS16550 Configuration */
include/configs/mx51evk.h +2 -0
@@ -46,6 +46,8 @@#define CONFIG_SETUP_MEMORY_TAGS 1#define CONFIG_INITRD_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/mx53evk.h +2 -0
@@ -38,6 +38,8 @@#define CONFIG_SETUP_MEMORY_TAGS 1#define CONFIG_INITRD_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* Size of malloc() pool */ #define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 2 * 1024 * 1024)
include/configs/omap3_overo.h +2 -0
@@ -52,6 +52,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/omap3_pandora.h +2 -0
@@ -55,6 +55,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/omap3_sdp3430.h +2 -0
@@ -71,6 +71,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool * Total Size Environment - 256k
include/configs/omap3_zoom1.h +2 -0
@@ -61,6 +61,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/omap3_zoom2.h +2 -0
@@ -62,6 +62,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool */
include/configs/omap4_panda.h +2 -0
@@ -60,6 +60,8 @@#define CONFIG_INITRD_TAG 1#define CONFIG_REVISION_TAG 1 +#define CONFIG_OF_LIBFDT 1 +/* * Size of malloc() pool * Total Size Environment - 256k
include/configs/omap4_sdp4430.h +2 -0
@@ -56,6 +56,8 @@#undef CONFIG_USE_IRQ/* no support for IRQs */ #define CONFIG_MISC_INIT_R +#define CONFIG_OF_LIBFDT 1 +#define CONFIG_CMDLINE_TAG 1/* enable passing of ATAGs */ #define CONFIG_SETUP_MEMORY_TAGS 1#define CONFIG_INITRD_TAG 1
include/configs/tegra2-common.h +1 -0
@@ -45,6 +45,7 @@#define CONFIG_SKIP_LOWLEVEL_INIT #define CONFIG_CMDLINE_TAG /* enable passing of ATAGs */ +#define CONFIG_OF_LIBFDT /* enable passing of devicetree */ /* Environment */ #define CONFIG_ENV_IS_NOWHERE
Re: [PATCH 6/6] Add CONFIG_OF_LIBFDT to more boards.
Dear Albert,
Quoted 23 lines · In message <20110328195906.10235.68517.stgit@ponder> Grant Likely wrote:
From: Grant Likely <[email protected]>
The following boards gain device tree support with this patch:
ca9x4_ct_vxp- Versatile Expressi.mx5 boards:
efikamx
mx51evk
mx53evkOMAP boards:
devkit8000
igep0020
igep0030omap3_overoomap3_pandoraomap4_sdp3430omap3_zoom1omap3_zoom2omap4_pandaomap4_sdp4430
Quoted 4 lines
Tegra boards:
HarmonySigned-off-by Grant Likely <[email protected]>
Could you please pull this through your tree (or ACK that I do this) ?
Thanks.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: [email protected] If I have seen further it is by standing on the shoulders of giants. - Isaac Newton, Letter to Robert Hooke, 5 February 1676
Re: [PATCH 6/6] Add CONFIG_OF_LIBFDT to more boards.
Hi Wolfgang,
Quoted 26 lines · Wolfgang Denk
Dear Albert,
Quoted 23 lines · In message<20110328195906.10235.68517.stgit@ponder> Grant Likely wrote:
From: Grant Likely<[email protected]>
The following boards gain device tree support with this patch:
ca9x4_ct_vxp- Versatile Expressi.mx5 boards:
efikamx
mx51evk
mx53evkOMAP boards:
devkit8000
igep0020
igep0030omap3_overoomap3_pandoraomap4_sdp3430omap3_zoom1omap3_zoom2omap4_pandaomap4_sdp4430
Quoted 6 lines
Quoted 4 lines
Tegra boards:
HarmonySigned-off-by Grant Likely<[email protected]>Could you please pull this through your tree (or ACK that I do this) ?
I'll pull this and send a new pull request with it and Po-Yu Chuang's fixes today.
Quoted 5 lines
Thanks.
Best regards,
Wolfgang Denk
Amicalement,
Signature · 1 line
Albert.
Re: [PATCH 6/6] Add CONFIG_OF_LIBFDT to more boards.
In reply to Grant LikelyHi Grant,
Quoted 36 lines · Grant Likely
From: Grant Likely<grant.likely-QSEj5FYQhm4dnm+yROfE0A-XMD5yJDbdMReXY1tMh2IBg@public.gmane.org>
The following boards gain device tree support with this patch:
ca9x4_ct_vxp- Versatile Expressi.mx5 boards:
efikamx
mx51evk
mx53evkOMAP boards:
devkit8000
igep0020
igep0030omap3_overoomap3_pandoraomap4_sdp3430omap3_zoom1omap3_zoom2omap4_pandaomap4_sdp4430Tegra boards:
Harmony--- include/configs/ca9x4_ct_vxp.h | 2 ++ include/configs/devkit8000.h | 2 ++ include/configs/efikamx.h | 2 ++ include/configs/igep0020.h | 2 ++ include/configs/igep0030.h | 2 ++ include/configs/mx51evk.h | 2 ++ include/configs/mx53evk.h | 2 ++ include/configs/omap3_overo.h | 2 ++
Quoted 8 lines
include/configs/omap3_pandora.h | 2 ++ include/configs/omap3_sdp3430.h | 2 ++ include/configs/omap3_zoom1.h | 2 ++ include/configs/omap3_zoom2.h | 2 ++ include/configs/omap4_panda.h | 2 ++ include/configs/omap4_sdp4430.h | 2 ++ include/configs/tegra2-common.h | 1 + 15 files changed, 29 insertions(+), 0 deletions(-)
Applied to u-boot-arm/master, thanks.
Amicalement,
Signature · 1 line
Albert.
PATCH 6/6 Add CONFIG_OF_LIBFDT to more boards.
In reply to Grant LikelyHi Grant,
Le 28/03/2011 21:59, Grant Likely a ?crit :
Quoted 36 lines
From: Grant Likely<[email protected]>
The following boards gain device tree support with this patch:
ca9x4_ct_vxp- Versatile Expressi.mx5 boards:
efikamx
mx51evk
mx53evkOMAP boards:
devkit8000
igep0020
igep0030omap3_overoomap3_pandoraomap4_sdp3430omap3_zoom1omap3_zoom2omap4_pandaomap4_sdp4430Tegra boards:
HarmonySigned-off-by Grant Likely<[email protected]>--- include/configs/ca9x4_ct_vxp.h | 2 ++ include/configs/devkit8000.h | 2 ++ include/configs/efikamx.h | 2 ++ include/configs/igep0020.h | 2 ++ include/configs/igep0030.h | 2 ++ include/configs/mx51evk.h | 2 ++ include/configs/mx53evk.h | 2 ++ include/configs/omap3_overo.h | 2 ++
Quoted 8 lines
include/configs/omap3_pandora.h | 2 ++ include/configs/omap3_sdp3430.h | 2 ++ include/configs/omap3_zoom1.h | 2 ++ include/configs/omap3_zoom2.h | 2 ++ include/configs/omap4_panda.h | 2 ++ include/configs/omap4_sdp4430.h | 2 ++ include/configs/tegra2-common.h | 1 + 15 files changed, 29 insertions(+), 0 deletions(-)
Applied to u-boot-arm/master, thanks.
Amicalement,
Signature · 1 line
Albert.
Quoted 19 lines · Grant Likely
Hi Jerry & Wolfgang,
The following series fixes a bug in the device tree code and eliminates the
CONFIG_OF_LIBFDTdependency onCONFIG_SYS_BOOTMAPSZ. It also adds parsing of the reserved mem regions so that U-Boot doesn't decide to use a regions set aside for another purpose.Finally, the last patch adds
CONFIG_OF_LIBFDTto a bunch of boards. I'm not expecting the last patch to be picked up in mainline (yet), but it will be picked up into the Linaro tree for the 11.05 release.John, this same series applies cleanly on the linaro-stable u-boot tree. Can you pick them up please? Or would you prefer me to send you a pull request?
g.
---
Quoted 8 lines
Grant Likely (6):
Stop passing aroundbootmem_basevalue.
Default tobootm_size()whenCONFIG_SYS_BOOTMAPSZis not defined Remove device tree booting dependency onCONFIG_SYS_BOOTMAPSZFix off-by-one error in passing initrd end address via device tree Respect memreserve regions specified in the device tree AddCONFIG_OF_LIBFDTto more boards.
On mx51evk (babbage) board:
Signature · 2 lines
Regards, Shawn
PATCH 1/2 Remove unnecessary CONFIG_SYS_BOOTMAPSZ definition
In reply to Grant LikelySince the following commit, definition CONFIG_SYS_BOOTMAPSZ is not needed any more.
7a02a39babb44f2ca2777db9b3a93be79111bba8
Remove device tree booting dependency on CONFIG_SYS_BOOTMAPSZ
--- include/configs/mx51evk.h | 1 - include/configs/mx53evk.h | 1 - include/configs/mx53loco.h | 1 - 3 files changed, 0 insertions(+), 3 deletions(-)
include/configs/mx51evk.h +0 -1
@@ -227,6 +227,5 @@#define CONFIG_SYS_MMC_ENV_DEV 0#define CONFIG_OF_LIBFDT -#define CONFIG_SYS_BOOTMAPSZ 0x800000#endif
include/configs/mx53evk.h +0 -1
@@ -193,6 +193,5 @@#define CONFIG_SYS_MMC_ENV_DEV 0#define CONFIG_OF_LIBFDT -#define CONFIG_SYS_BOOTMAPSZ 0x800000#endif /* __CONFIG_H */
include/configs/mx53loco.h +0 -1
@@ -194,6 +194,5 @@#define CONFIG_SYS_MMC_ENV_DEV 0#define CONFIG_OF_LIBFDT -#define CONFIG_SYS_BOOTMAPSZ 0x800000#endif /* __CONFIG_H */
Signature · 1 line
1.7.4.1
PATCH 2/2 Fix CONFIG_OF_LIBFDT redefined warning
With the following commit, CONFIG_OF_LIBFDT was redefined.
a8f88eedb2c4df472e512db58dfcaafd82c68b86
Add CONFIG_OF_LIBFDT to more boards.
Remove the duplicated definition to fix CONFIG_OF_LIBFDT redefined warning.
--- include/configs/mx51evk.h | 2 -- include/configs/mx53evk.h | 2 -- 2 files changed, 0 insertions(+), 4 deletions(-)
include/configs/mx51evk.h +0 -2
@@ -226,6 +226,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT -#endif
include/configs/mx53evk.h +0 -2
@@ -192,6 +192,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT -#endif /* __CONFIG_H */
Signature · 1 line
1.7.4.1
PATCH RESEND 1/2 mx5: Remove unnecessary CONFIG_SYS_BOOTMAPSZ definition
In reply to Grant LikelySince the following commit, definition CONFIG_SYS_BOOTMAPSZ is not needed any more.
ed59e58786cae9f8afcb575649afc65985beed4d
Remove device tree booting dependency on CONFIG_SYS_BOOTMAPSZ
---
Why resend?
The previous post does not apply on u-boot mainline, so rebase and resend.
include/configs/mx51evk.h | 1 - include/configs/mx53evk.h | 1 - 2 files changed, 0 insertions(+), 2 deletions(-)
include/configs/mx51evk.h +0 -1
@@ -227,6 +227,5 @@#define CONFIG_SYS_MMC_ENV_DEV 0#define CONFIG_OF_LIBFDT -#define CONFIG_SYS_BOOTMAPSZ 0x800000#endif
include/configs/mx53evk.h +0 -1
@@ -193,6 +193,5 @@#define CONFIG_SYS_MMC_ENV_DEV 0#define CONFIG_OF_LIBFDT -#define CONFIG_SYS_BOOTMAPSZ 0x800000#endif /* __CONFIG_H */
Signature · 1 line
1.7.4.1
PATCH RESEND 2/2 mx5: Fix CONFIG_OF_LIBFDT redefined warning
With the following commit, CONFIG_OF_LIBFDT is redefined.
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
Add CONFIG_OF_LIBFDT to more boards.
Remove the duplicated definition to fix CONFIG_OF_LIBFDT redefined warning.
--- include/configs/mx51evk.h | 2 -- include/configs/mx53evk.h | 2 -- 2 files changed, 0 insertions(+), 4 deletions(-)
include/configs/mx51evk.h +0 -2
@@ -226,6 +226,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT -#endif
include/configs/mx53evk.h +0 -2
@@ -192,6 +192,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT -#endif /* __CONFIG_H */
Signature · 1 line
1.7.4.1
PATCH RESEND 2/2 mx5: Fix CONFIG_OF_LIBFDT redefined warning
Quoted 9 lines · Shawn Guo
With the following commit,
CONFIG_OF_LIBFDTis redefined.
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
AddCONFIG_OF_LIBFDTto more boards.Remove the duplicated definition to fix
CONFIG_OF_LIBFDTredefined warning.Signed-off-by Shawn Guo <[email protected]>
Hi Shawn,
Quoted 10 lines
--- include/configs/mx51evk.h | 2 -- include/configs/mx53evk.h | 2 -- 2 files changed, 0 insertions(+), 4 deletions(-)include/configs/mx51evk.h +0
-0
include/configs/mx51evk.h line 229
Quoted 4 lines
include/configs/mx51evk.h +0
-1@@ -226,6 +226,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT
Thanks to clean up this. Could you also drop the not needed "1" to the other define ?
#define CONFIG_OF_LIBFDT 1
Should be:
#define CONFIG_OF_LIBFDT
Regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de =====================================================================
PATCH RESEND 2/2 mx5: Fix CONFIG_OF_LIBFDT redefined warning
Quoted 31 lines · Stefano Babic
Quoted 9 lines · Shawn Guo
With the following commit,
CONFIG_OF_LIBFDTis redefined.
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
AddCONFIG_OF_LIBFDTto more boards.Remove the duplicated definition to fix
CONFIG_OF_LIBFDTredefined warning.Signed-off-by Shawn Guo <[email protected]>Hi Shawn,
Quoted 10 lines
--- include/configs/mx51evk.h | 2 -- include/configs/mx53evk.h | 2 -- 2 files changed, 0 insertions(+), 4 deletions(-)include/configs/mx51evk.h +0
-0include/configs/mx51evk.h line 229
Quoted 4 lines
include/configs/mx51evk.h +0
-1@@ -226,6 +226,4 @@#define CONFIG_ENV_IS_IN_MMC #define CONFIG_SYS_MMC_ENV_DEV 0 -#define CONFIG_OF_LIBFDT Thanks to clean up this. Could you also drop the not needed "1" to the other define ?
Quoted 5 lines
#define
CONFIG_OF_LIBFDT1Should be:
#defineCONFIG_OF_LIBFDT
As you can see from the commit below,
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
Add CONFIG_OF_LIBFDT to more boards.
CONFIG_OF_LIBFDT was defined with '1' in all those files.
--- include/configs/ca9x4_ct_vxp.h | 2 ++ include/configs/devkit8000.h | 2 ++ include/configs/efikamx.h | 2 ++ include/configs/igep0020.h | 2 ++ include/configs/igep0030.h | 2 ++ include/configs/mx51evk.h | 2 ++ include/configs/mx53evk.h | 2 ++ include/configs/omap3_overo.h | 2 ++ include/configs/omap3_pandora.h | 2 ++ include/configs/omap3_sdp3430.h | 2 ++ include/configs/omap3_zoom1.h | 2 ++ include/configs/omap3_zoom2.h | 2 ++ include/configs/omap4_panda.h | 2 ++ include/configs/omap4_sdp4430.h | 2 ++ include/configs/tegra2-common.h | 1 + 15 files changed, 29 insertions(+), 0 deletions(-)
If you really want to get this '1' removed, I would prefer to do it globally with another patch.
Signature · 2 lines
Regards, Shawn
PATCH RESEND 2/2 mx5: Fix CONFIG_OF_LIBFDT redefined warning
Quoted 25 lines · Shawn Guo
As you can see from the commit below,
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
AddCONFIG_OF_LIBFDTto more boards.
CONFIG_OF_LIBFDTwas defined with '1' in all those files.--- include/configs/ca9x4_ct_vxp.h | 2 ++ include/configs/devkit8000.h | 2 ++ include/configs/efikamx.h | 2 ++ include/configs/igep0020.h | 2 ++ include/configs/igep0030.h | 2 ++ include/configs/mx51evk.h | 2 ++ include/configs/mx53evk.h | 2 ++ include/configs/omap3_overo.h | 2 ++ include/configs/omap3_pandora.h | 2 ++ include/configs/omap3_sdp3430.h | 2 ++ include/configs/omap3_zoom1.h | 2 ++ include/configs/omap3_zoom2.h | 2 ++ include/configs/omap4_panda.h | 2 ++ include/configs/omap4_sdp4430.h | 2 ++ include/configs/tegra2-common.h | 1 + 15 files changed, 29 insertions(+), 0 deletions(-)
Quoted 2 lines
If you really want to get this '1' removed, I would prefer to do it globally with another patch.
No, I agree with you. Better to fix globally in another patch.
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de =====================================================================
PATCH RESEND 2/2 mx5: Fix CONFIG_OF_LIBFDT redefined warning
In reply to Shawn GuoQuoted 9 lines · Shawn Guo
With the following commit,
CONFIG_OF_LIBFDTis redefined.
2fa8ca98c37d5b1bb0328b19ddb7e9d162cd9683
AddCONFIG_OF_LIBFDTto more boards.Remove the duplicated definition to fix
CONFIG_OF_LIBFDTredefined warning.Signed-off-by Shawn Guo <[email protected]>
Applied to u-boot-imx, thanks.
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de =====================================================================
PATCH RESEND 1/2 mx5: Remove unnecessary CONFIG_SYS_BOOTMAPSZ definition
In reply to Shawn GuoQuoted 8 lines · Shawn Guo
Since the following commit, definition
CONFIG_SYS_BOOTMAPSZis not needed any more.
ed59e58786cae9f8afcb575649afc65985beed4d
Remove device tree booting dependency onCONFIG_SYS_BOOTMAPSZSigned-off-by Shawn Guo <[email protected]>---
Applied to -u-boot-imx, thanks.
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de =====================================================================