summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sh
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2007-12-11 15:49:53 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2007-12-11 15:49:53 +0000
commit12bd47efc0f50d673c10528ed601eaf8b54f182b (patch)
treed775bb30121bac016ab20aa95e4b3d40ba205a0a /c/src/lib/libbsp/sh
parent2007-12-11 Joel Sherrill <joel.sherrill@OARcorp.com> (diff)
downloadrtems-12bd47efc0f50d673c10528ed601eaf8b54f182b.tar.bz2
2007-12-11 Joel Sherrill <joel.sherrill@OARcorp.com>
* clock/ckinit.c, include/bsp.h, startup/bspstart.c: Eliminate copies of the Configuration Table. Use the RTEMS provided accessor macros to obtain configuration fields.
Diffstat (limited to 'c/src/lib/libbsp/sh')
-rw-r--r--c/src/lib/libbsp/sh/simsh4/ChangeLog6
-rw-r--r--c/src/lib/libbsp/sh/simsh4/clock/ckinit.c6
-rw-r--r--c/src/lib/libbsp/sh/simsh4/include/bsp.h1
-rw-r--r--c/src/lib/libbsp/sh/simsh4/startup/bspstart.c13
4 files changed, 11 insertions, 15 deletions
diff --git a/c/src/lib/libbsp/sh/simsh4/ChangeLog b/c/src/lib/libbsp/sh/simsh4/ChangeLog
index e084a2ada7..cc0de4cedb 100644
--- a/c/src/lib/libbsp/sh/simsh4/ChangeLog
+++ b/c/src/lib/libbsp/sh/simsh4/ChangeLog
@@ -1,3 +1,9 @@
+2007-12-11 Joel Sherrill <joel.sherrill@OARcorp.com>
+
+ * clock/ckinit.c, include/bsp.h, startup/bspstart.c: Eliminate copies
+ of the Configuration Table. Use the RTEMS provided accessor macros to
+ obtain configuration fields.
+
2007-12-04 Joel Sherrill <joel.sherrill@OARcorp.com>
* include/bsp.h, startup/bspstart.c: Move interrupt_stack_size field
diff --git a/c/src/lib/libbsp/sh/simsh4/clock/ckinit.c b/c/src/lib/libbsp/sh/simsh4/clock/ckinit.c
index 69d22948df..4246e176a1 100644
--- a/c/src/lib/libbsp/sh/simsh4/clock/ckinit.c
+++ b/c/src/lib/libbsp/sh/simsh4/clock/ckinit.c
@@ -77,7 +77,7 @@ Clock_isr (rtems_vector_number vector)
void
Clock_exit(void)
{
- if (BSP_Configuration.ticks_per_timeslice)
+ if (rtems_configuration_get_ticks_per_timeslice())
{
/* disable all timer1 interrupts */
set_clock_period(0);
@@ -100,9 +100,9 @@ Install_clock(rtems_isr_entry clock_isr)
uint32_t period;
Clock_driver_ticks = 0;
- if (BSP_Configuration.ticks_per_timeslice) {
+ if (rtems_configuration_get_ticks_per_timeslice()) {
rtems_isr_entry old_isr;
- period = bsp_clicks_per_second / BSP_Configuration.ticks_per_timeslice;
+ period = bsp_clicks_per_second / rtems_configuration_get_ticks_per_timeslice();
/* Configure timer interrupts */
set_clock_period(period);
diff --git a/c/src/lib/libbsp/sh/simsh4/include/bsp.h b/c/src/lib/libbsp/sh/simsh4/include/bsp.h
index 9b72c24710..4e3081ad21 100644
--- a/c/src/lib/libbsp/sh/simsh4/include/bsp.h
+++ b/c/src/lib/libbsp/sh/simsh4/include/bsp.h
@@ -87,7 +87,6 @@ extern void *CPU_Interrupt_stack_high ;
/* miscellaneous stuff assumed to exist */
-extern rtems_configuration_table BSP_Configuration;
extern void bsp_cleanup( void );
/*
diff --git a/c/src/lib/libbsp/sh/simsh4/startup/bspstart.c b/c/src/lib/libbsp/sh/simsh4/startup/bspstart.c
index 3d86bcd6b4..bcd6c6e616 100644
--- a/c/src/lib/libbsp/sh/simsh4/startup/bspstart.c
+++ b/c/src/lib/libbsp/sh/simsh4/startup/bspstart.c
@@ -36,17 +36,8 @@
*/
uint32_t bsp_clicks_per_second;
-/*
- * The original table from the application and our copy of it with
- * some changes.
- */
-
extern void bsp_hw_init(void);
-extern rtems_configuration_table Configuration;
-rtems_configuration_table BSP_Configuration;
-char *rtems_progname;
-
/*
* Use the shared implementations of the following routines
*/
@@ -111,8 +102,8 @@ void bsp_start(void)
* not malloc'ed. It is just "pulled from the air".
*/
- BSP_Configuration.work_space_start = (void *) &WorkSpaceStart ;
- BSP_Configuration.work_space_size =
+ Configuration.work_space_start = (void *) &WorkSpaceStart ;
+ rtems_configuration_get_work_space_size() =
(uint32_t) &WorkSpaceEnd -
(uint32_t) &WorkSpaceStart ;