summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-07-15 10:51:12 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-07-15 10:52:40 +0200
commit93f5adb644363d321ddfcbf48586296ed7add189 (patch)
tree74cf38bc486ae690789d38028773f6badf8d2b4a
parentpowerpc: Fix _CPU_Counter_read() (diff)
downloadrtems-93f5adb644363d321ddfcbf48586296ed7add189.tar.bz2
powerpc: Do not use the ATB for e500 multilib
The e500v1 has no support for the ATB. Update #2369.
-rw-r--r--c/src/lib/libbsp/powerpc/qoriq/startup/bspstart.c8
-rw-r--r--cpukit/score/cpu/powerpc/rtems/score/cpu.h2
2 files changed, 8 insertions, 2 deletions
diff --git a/c/src/lib/libbsp/powerpc/qoriq/startup/bspstart.c b/c/src/lib/libbsp/powerpc/qoriq/startup/bspstart.c
index 724e5b3b73..6d121eaa0a 100644
--- a/c/src/lib/libbsp/powerpc/qoriq/startup/bspstart.c
+++ b/c/src/lib/libbsp/powerpc/qoriq/startup/bspstart.c
@@ -90,7 +90,13 @@ void bsp_start(void)
BSP_bus_frequency = bsp_uboot_board_info.bi_busfreq
/ QORIQ_BUS_CLOCK_DIVIDER;
bsp_clicks_per_usec = BSP_bus_frequency / 8000000;
- rtems_counter_initialize_converter(bsp_uboot_board_info.bi_intfreq);
+ rtems_counter_initialize_converter(
+ #ifdef __PPC_CPU_E6500__
+ bsp_uboot_board_info.bi_intfreq
+ #else
+ BSP_bus_frequency / 8
+ #endif
+ );
#endif /* HAS_UBOOT */
/* Initialize some console parameters */
diff --git a/cpukit/score/cpu/powerpc/rtems/score/cpu.h b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
index 45298a46dd..7fef878599 100644
--- a/cpukit/score/cpu/powerpc/rtems/score/cpu.h
+++ b/cpukit/score/cpu/powerpc/rtems/score/cpu.h
@@ -838,7 +838,7 @@ static inline CPU_Counter_ticks _CPU_Counter_read( void )
{
CPU_Counter_ticks value;
-#if defined(ppc8540) || defined(__PPC_CPU_E6500__)
+#if defined(__PPC_CPU_E6500__)
/* Use Alternate Time Base */
__asm__ volatile( "mfspr %0, 526" : "=r" (value) );
#else