summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libcpu/a29k/clock
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2000-09-25 19:06:25 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2000-09-25 19:06:25 +0000
commit2a1ca73cbc1d68420c676f744da7ccd2d2f9e0f6 (patch)
tree6bf65fec4ffc80b5021dddc43412bf92bdb0d097 /c/src/lib/libcpu/a29k/clock
parent2000-09-25 Joel Sherrill <joel@OARcorp.com> (diff)
downloadrtems-2a1ca73cbc1d68420c676f744da7ccd2d2f9e0f6.tar.bz2
2000-09-25 Joel Sherrill <joel@OARcorp.com>
* clock/ckinit.c: Removed include of <bsp.h>. Also switch to macros to get configuration data. * timer/timer.c: Removed include of <bsp.h>. Fixed comment that said 4650 (a mips part).
Diffstat (limited to 'c/src/lib/libcpu/a29k/clock')
-rw-r--r--c/src/lib/libcpu/a29k/clock/ckinit.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/c/src/lib/libcpu/a29k/clock/ckinit.c b/c/src/lib/libcpu/a29k/clock/ckinit.c
index b52c7aaa63..0108401ed4 100644
--- a/c/src/lib/libcpu/a29k/clock/ckinit.c
+++ b/c/src/lib/libcpu/a29k/clock/ckinit.c
@@ -21,10 +21,12 @@ static char _sccsid[] = "@(#)ckinit.c 03/15/96 1.1\n";
#include <rtems.h>
#include <rtems/libio.h>
-#include <bsp.h>
+/* #include <bsp.h> */
#include "clock.h"
+extern int CPU_CLOCK_RATE_MHZ; /* provided in bsp */
+
#define CLOCKS_PER_MICROSECOND ( CPU_CLOCK_RATE_MHZ ) /* equivalent to CPU clock speed in MHz */
void Clock_exit( void );
@@ -123,13 +125,13 @@ void Install_clock(
* wants a clock tick.
*/
- if ( BSP_Configuration.ticks_per_timeslice ) {
+ if ( rtems_configuration_get_ticks_per_timeslice() ) {
Old_ticker = (rtems_isr_entry) set_vector( clock_isr, CLOCK_VECTOR, 1 );
/*
* Hardware specific initialize goes here
*/
- a29k_timer_rate = BSP_Configuration.microseconds_per_tick * CLOCKS_PER_MICROSECOND;
+ a29k_timer_rate = rtems_configuration_get_microseconds_per_tick() * CLOCKS_PER_MICROSECOND;
a29k_init_timer( a29k_timer_rate );
}
@@ -146,7 +148,7 @@ void Install_clock(
void Clock_exit( void )
{
- if ( BSP_Configuration.ticks_per_timeslice ) {
+ if ( rtems_configuration_get_ticks_per_timeslice() ) {
/* a29k: turn off the timer interrupts */
a29k_disable_timer();