From: TsiChungLiew Date: Sun, 5 Aug 2007 08:58:52 +0000 (-0500) Subject: Changed CFG_CLK to gd->bus_clk for CFG_TIMER_PRESCALER. Added DECLARE_GLOBAL_DATA_PTR... X-Git-Tag: v1.3.0-rc1~19^2~2^2~17^2~5 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=99c03c175d2689093176facf17c58ce2cb320001;p=u-boot Changed CFG_CLK to gd->bus_clk for CFG_TIMER_PRESCALER. Added DECLARE_GLOBAL_DATA_PTR for time.c Signed-off-by: TsiChungLiew --- diff --git a/include/asm-m68k/immap.h b/include/asm-m68k/immap.h index 4e238c3f54..7c267af56e 100644 --- a/include/asm-m68k/immap.h +++ b/include/asm-m68k/immap.h @@ -41,7 +41,7 @@ #define CFG_TMRINTR_NO (INT0_HI_DTMR1) #define CFG_TMRINTR_MASK (INTC_IPRH_INT33) #define CFG_TMRINTR_PRI (6) -#define CFG_TIMER_PRESCALER (((CFG_CLK / 1000000) - 1) << 8) +#define CFG_TIMER_PRESCALER (((gd->bus_clk / 1000000) - 1) << 8) #endif #ifdef CONFIG_MCFPIT diff --git a/lib_m68k/time.c b/lib_m68k/time.c index 267a3cdbc7..3dbce07213 100644 --- a/lib_m68k/time.c +++ b/lib_m68k/time.c @@ -48,6 +48,8 @@ #include #endif +DECLARE_GLOBAL_DATA_PTR; + static ulong timestamp; #if defined(CONFIG_M5282) || defined(CONFIG_M5271) static unsigned short lastinc;