add ft_cpu_setup(..)-function for mpc8260
PATCH 1/1 add ft_cpu_setup(..)-function for mpc8260
Hello everybody.
On proposal from Heiko Schocher:
This patch adds ft_cpu_setup(..) - function for mpc8260.
--
cpu/mpc8260/cpu.c +15 -0
@@ -294,3 +294,18 @@ void watchdog_reset (void)#endif /* CONFIG_WATCHDOG */ /* ------------------------------------------------------------------------- */ + +#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 /* CONFIG_OF_FLAT_TREE */ +/* ------------------------------------------------------------------------- */
Signature · 8 lines
Sergej I. Stepanov IDS GmbH Nobelstr. 18, Zim. 2.1.05 D-76275 Ettlingen T +49 (0) 72 43/2 18-615 F +49 (0) 72 43/2 18-400 http://www.ids.de Email: Sergej.Stepanov at ids.de
PATCH 1/1 add ft_cpu_setup(..)-function for mpc8260
Dear Sergei,
Quoted 11 lines · in message <[email protected]> you wrote:
On proposal from Heiko Schocher:
This patch addsft_cpu_setup(..)- function for mpc8260.Signed-off-by Sergej Stepanov <[email protected]>--
diff -pruN --exclude='\.svn'
u-boot-1.2.0-orig/cpu/mpc8260/cpu.cu-boot-1.2.0/cpu/mpc8260/cpu.c
cpu/mpc8260/cpu.c void watchdog_reset (void) · line 298
Quoted 5 lines
cpu/mpc8260/cpu.c +2
-0@@ -294,3 +294,18 @@ void watchdog_reset (void)#endif /* CONFIG_WATCHDOG */ /* ------------------------------------------------------------------------- */ + +#if defined(CONFIG_OF_FLAT_TREE )
CONFIG_OF_FLAT_TREE is deprecated, as it is going to be replaced by CONFIG_OF_LIBFDT.
Please change your code to use the new style and resubmit. Thanks.
Best regards,
Wolfgang Denk
Signature · 7 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: wd at denx.de There is an old custom among my people. When a woman saves a man's life, he is grateful. -- Nona, the Kanuto which woman, "A Private Little War", stardate 4211.8.
PATCH 1/1 add ft_cpu_setup(..)-function for mpc8260
Quoted 22 lines · Wolfgang Denk
Dear Sergei,
Quoted 10 lines · in message <[email protected]> you wrote:
On proposal from Heiko Schocher:
This patch addsft_cpu_setup(..)- function for mpc8260.Signed-off-by Sergej Stepanov <[email protected]>--
diff -pruN --exclude='\.svn'
u-boot-1.2.0-orig/cpu/mpc8260/cpu.cu-boot-1.2.0/cpu/mpc8260/cpu.ccpu/mpc8260/cpu.c void watchdog_reset (void) · line 298
Quoted 5 lines
cpu/mpc8260/cpu.c +2
-0@@ -294,3 +294,18 @@ void watchdog_reset (void)#endif /* CONFIG_WATCHDOG */ /* ------------------------------------------------------------------------- */ + +#if defined(CONFIG_OF_FLAT_TREE )
CONFIG_OF_FLAT_TREEis deprecated, as it is going to be replaced byCONFIG_OF_LIBFDT.
Quoted 5 lines
Please change your code to use the new style and resubmit. Thanks.
Best regards,
Wolfgang Denk
...and use Grant's 5xxx code as the model of how to do it the New Improved LIBFDT Way.
<http://www.denx.de/cgi-bin/gitweb.cgi?p=u-boot/u-boot-mpc5xxx.git;a=blob;f=cpu/mpc5xxx/cpu.c;h=7f16b92a6cac06af26f00a9a267f7bd6c371323a;hb=cf2817a84c2e9bea2c5dfc084bce2f2d2563ac43>
On the 83xx family, I did a table-based fixup which turned out uglier than what Grant did and I intend to switch over to Grant's methodology when I get some breathing room.
Best regards,
gvb