[U-Boot-Users] [PATCH] changes for support of IDS8247 board
Heiko Schocher
heiko.schocher at invitel.hu
Tue Aug 7 09:03:40 CEST 2007
Hello Sergej,
Sergej Stepanov wrote:
[...]
> #endif /* CFG_CMD_NAND */
> +
> +#if defined(CONFIG_OF_FLAT_TREE) && defined(CONFIG_OF_BOARD_SETUP)
> +void
> +ft_board_setup(void *blob, bd_t *bd)
> +{
> + u32 *p;
> + int len;
> + ulong clock;
> + /* do what ft_cpu_setup does */
> +
> + clock = bd->bi_busfreq;
> + p = ft_get_prop(blob, "/cpus/" OF_CPU "/bus-frequency", &len);
> + if (p != NULL)
> + *p = cpu_to_be32(clock);
This is valid for all MPC8260 processors. I think you should move this
to: cpu/mpc8260/cpu.c and make a ft_cpu_setup ():
#if defined(CONFIG_OF_FLAT_TREE)
void ft_cpu_setup (void *blob, bd_t *bd)
{
u32 *p;
ulong clock;
int len;
clock = bd->bi_busfreq;
p = ft_get_prop (blob, "/cpus/" OF_CPU "/bus-frequency", &len);
if (p != NULL)
*p = cpu_to_be32 (clock);
}
#endif
and call this function in ft_board_setup ().
Best regards
Heiko
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
More information about the U-Boot
mailing list