[U-Boot-Users] [PATCH] syscon3: changes to support FDT

Stefan Roese sr at denx.de
Fri May 9 14:38:56 CEST 2008


On Friday 09 May 2008, Wolfgang Denk wrote:
> From: Sergei Poselenov <sposelenov at emcraft.com>
>
> Signed-off-by: Sergei Poselenov <sposelenov at emcraft.com>
> Signed-off-by: Wolfgang Denk <wd at denx.de>
> ---
>  board/syscon3/syscon3.c   |   25 +++++++++++++++++++
>  include/configs/syscon3.h |   58
> +++++++++++++++++++------------------------- 2 files changed, 50
> insertions(+), 33 deletions(-)

I can't find this board support. And also no patches for it.

Please find some further comments below.

> diff --git a/board/syscon3/syscon3.c b/board/syscon3/syscon3.c
> index ea33f82..b814bae 100644
> --- a/board/syscon3/syscon3.c
> +++ b/board/syscon3/syscon3.c
> @@ -33,6 +33,8 @@
>  #include <asm/immap_85xx.h>
>  #include <ioports.h>
>  #include <flash.h>
> +#include <libfdt.h>
> +#include <fdt_support.h>
>
>  DECLARE_GLOBAL_DATA_PTR;
>
> @@ -184,3 +186,26 @@ int board_early_init_r (void)
>  	return (0);
>  }
>  #endif /* CONFIG_BOARD_EARLY_INIT_R */
> +
> +#if defined(CONFIG_OF_LIBFDT) && defined(CONFIG_OF_BOARD_SETUP)
> +void
> +ft_board_setup(void *blob, bd_t *bd)
> +{
> +	u32 val[4];
> +	int rc;
> +
> +	ft_cpu_setup(blob, bd);
> +
> +	/* Fixup NOR mapping */
> +	val[0] = 0;				/* chip select number */
> +	val[1] = 0;				/* always 0 */
> +	val[2] = gd->bd->bi_flashstart;
> +	val[3] = gd->bd->bi_flashsize;
> +
> +	rc = fdt_find_and_setprop(blob, "/localbus", "ranges",
> +				  val, sizeof(val), 1);
> +	if (rc)
> +		printf("Unable to update property NOR mapping, err=%s\n",
> +		       fdt_strerror(rc));
> +}
> +#endif /* defined(CONFIG_OF_LIBFDT) && defined(CONFIG_OF_BOARD_SETUP) */

This is not needed anymore. With my latest patch (available in the 
u-boot-ppc4xx repository, master branch for pulling):

[PATCH 2/3] ppc4xx: Add weak default  ft_board_setup() routine

this board specific code is not needed in this case, since it is an exact copy 
of the weak default routine. Please remove it in the next version of this 
patch.

Thanks.

Best regards,
Stefan

=====================================================================
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
=====================================================================




More information about the U-Boot mailing list