public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] mpc85xx: add function prototypes for sys and ddr clocks to speed.c
@ 2010-05-21 18:07 Timur Tabi
  2010-05-21 18:11 ` Scott Wood
  0 siblings, 1 reply; 8+ messages in thread
From: Timur Tabi @ 2010-05-21 18:07 UTC (permalink / raw)
  To: u-boot

On most Freescale 85xx boards, the CONFIG_SYS_CLK_FREQ and CONFIG_DDR_CLK_FREQ
macros are defined like this:

This means that in order to use these macros, the callers must have prototypes
for the corresponding functions.  On 85xx, only speed.c uses these macros, so
let's define the prototypes there.  This eliminates the need to define the
prototypes in the board config files.

Signed-off-by: Timur Tabi <timur@freescale.com>
---

I'm posting the patch for review, and if everyone likes it, inclusion in the
85xx repo.  Comments welcome.

 arch/powerpc/cpu/mpc85xx/speed.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/cpu/mpc85xx/speed.c b/arch/powerpc/cpu/mpc85xx/speed.c
index 8132115..724ce9d 100644
--- a/arch/powerpc/cpu/mpc85xx/speed.c
+++ b/arch/powerpc/cpu/mpc85xx/speed.c
@@ -31,6 +31,10 @@
 #include <asm/processor.h>
 #include <asm/io.h>
 
+/* Board-specific clock frequency functions. */
+unsigned long calculate_board_sys_clk(void);
+unsigned long calculate_board_ddr_clk(void);
+
 DECLARE_GLOBAL_DATA_PTR;
 
 /* --------------------------------------------------------------- */
-- 
1.6.5

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2010-05-21 18:44 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-21 18:07 [U-Boot] [PATCH] mpc85xx: add function prototypes for sys and ddr clocks to speed.c Timur Tabi
2010-05-21 18:11 ` Scott Wood
2010-05-21 18:18   ` Timur Tabi
2010-05-21 18:34     ` Scott Wood
2010-05-21 18:36       ` Timur Tabi
2010-05-21 18:40         ` Timur Tabi
2010-05-21 18:44         ` Scott Wood
2010-05-21 18:44       ` Peter Tyser

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox