summaryrefslogtreecommitdiff
path: root/cpu/ppc4xx/speed.c
diff options
context:
space:
mode:
authorroy zang <tie-fei.zang@freescale.com>2007-02-28 16:46:48 +0800
committerZang Tiefei <roy@bus.ap.freescale.net>2007-02-28 16:46:48 +0800
commit00b574bdc8c54dbc9e03f63c24f62955d483e3ef (patch)
treedc49c4219bafd43c2ace6c5a3e6745d7b7264194 /cpu/ppc4xx/speed.c
parent30bddf2c46ab2e824f217a38db033118ac4622af (diff)
parentccbc7036648e465697ca298ba51e0e76dda352a0 (diff)
downloadu-boot-imx-00b574bdc8c54dbc9e03f63c24f62955d483e3ef.zip
u-boot-imx-00b574bdc8c54dbc9e03f63c24f62955d483e3ef.tar.gz
u-boot-imx-00b574bdc8c54dbc9e03f63c24f62955d483e3ef.tar.bz2
Merge branch 'master' into hpc2
Conflicts: drivers/Makefile Fix the merge conflict in file drivers/Makefile Signed-off-by: Roy Zang <tie-fei.zang@freescale.com>
Diffstat (limited to 'cpu/ppc4xx/speed.c')
-rw-r--r--cpu/ppc4xx/speed.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/cpu/ppc4xx/speed.c b/cpu/ppc4xx/speed.c
index 2d16a83..06220c3 100644
--- a/cpu/ppc4xx/speed.c
+++ b/cpu/ppc4xx/speed.c
@@ -331,7 +331,7 @@ void get_sys_info (sys_info_t * sysInfo)
unsigned long m;
unsigned long prbdv0;
-#if defined(CONFIG_440SPE)
+#if defined(CONFIG_YUCCA)
unsigned long sys_freq;
unsigned long sys_per=0;
unsigned long msr;
@@ -348,7 +348,7 @@ void get_sys_info (sys_info_t * sysInfo)
/*-------------------------------------------------------------------------+
| Calculate the system clock speed from the period.
+-------------------------------------------------------------------------*/
- sys_freq=(ONE_BILLION/sys_per)*1000;
+ sys_freq = (ONE_BILLION / sys_per) * 1000;
#endif
/* Extract configured divisors */
@@ -385,17 +385,17 @@ void get_sys_info (sys_info_t * sysInfo)
m = sysInfo->pllExtBusDiv * sysInfo->pllOpbDiv * sysInfo->pllFwdDivB;
/* Now calculate the individual clocks */
-#if defined(CONFIG_440SPE)
+#if defined(CONFIG_YUCCA)
sysInfo->freqVCOMhz = (m * sys_freq) ;
#else
- sysInfo->freqVCOMhz = (m * CONFIG_SYS_CLK_FREQ) + (m>>1);
+ sysInfo->freqVCOMhz = (m * CONFIG_SYS_CLK_FREQ) + (m >> 1);
#endif
sysInfo->freqProcessor = sysInfo->freqVCOMhz/sysInfo->pllFwdDivA;
sysInfo->freqPLB = sysInfo->freqVCOMhz/sysInfo->pllFwdDivB/prbdv0;
sysInfo->freqOPB = sysInfo->freqPLB/sysInfo->pllOpbDiv;
sysInfo->freqEPB = sysInfo->freqOPB/sysInfo->pllExtBusDiv;
-#if defined(CONFIG_440SPE)
+#if defined(CONFIG_YUCCA)
/* Determine PCI Clock Period */
pci_clock_per = determine_pci_clock_per();
sysInfo->freqPCI = (ONE_BILLION/pci_clock_per) * 1000;
@@ -408,7 +408,7 @@ void get_sys_info (sys_info_t * sysInfo)
#endif
-#if defined(CONFIG_440SPE)
+#if defined(CONFIG_YUCCA)
unsigned long determine_sysper(void)
{
unsigned int fpga_clocking_reg;
@@ -583,7 +583,6 @@ unsigned long determine_sysper(void)
}
return(sys_per);
-
}
/*-------------------------------------------------------------------------+