summaryrefslogtreecommitdiff
path: root/common/image.c
diff options
context:
space:
mode:
authorStephan Linz <linz@li-pro.net>2010-06-25 18:04:59 +0200
committerWolfgang Denk <wd@denx.de>2010-08-08 22:16:05 +0200
commit958e120643e8b6765b3ff84dfcf57624076afd21 (patch)
treeed6dfa4c17cfd83b3ba796a237ad415432b800be /common/image.c
parentcd1535564c3d52d2bc063e54e7d11ace7aeb9f52 (diff)
downloadu-boot-imx-958e120643e8b6765b3ff84dfcf57624076afd21.zip
u-boot-imx-958e120643e8b6765b3ff84dfcf57624076afd21.tar.gz
u-boot-imx-958e120643e8b6765b3ff84dfcf57624076afd21.tar.bz2
fdt relocate: have more attention to use a bootmap or not
Platforms with flat device tree support can use a bootmap to relocate the fdt_blob. This is not a must. That's why the relocation function boot_relocate_fdt() should be use only if CONFIG_OF_LIBFDT was defined together with CONFIG_SYS_BOOTMAPSZ (see common/cmd_bootm.c). On MicroBlaze platforms there is no need to use a bootmap to relocate a fdt blob. So we need a more precise focus on the compilation and usage of boot_relocate_fdt(). In general it is valid to exclude the function boot_relocate_fdt() if the bootmap size CONFIG_SYS_BOOTMAPSZ is not defined. Signed-off-by: Stephan Linz <linz@li-pro.net>
Diffstat (limited to 'common/image.c')
-rw-r--r--common/image.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/common/image.c b/common/image.c
index ea59730..fcb938b 100644
--- a/common/image.c
+++ b/common/image.c
@@ -1184,6 +1184,7 @@ static int fit_check_fdt (const void *fit, int fdt_noffset, int verify)
* 0 - success
* 1 - failure
*/
+#if defined(CONFIG_SYS_BOOTMAPSZ)
int boot_relocate_fdt (struct lmb *lmb, ulong bootmap_base,
char **of_flat_tree, ulong *of_size)
{
@@ -1263,6 +1264,7 @@ int boot_relocate_fdt (struct lmb *lmb, ulong bootmap_base,
error:
return 1;
}
+#endif /* CONFIG_SYS_BOOTMAPSZ */
/**
* boot_get_fdt - main fdt handling routine