summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/nios2
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2008-08-31 16:07:58 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2008-08-31 16:07:58 +0000
commit35f52a69829e2a1e3180949ca38592d2b13034de (patch)
tree30d9b664d846d95d42d7f86d17ddf0c0bd6e4744 /c/src/lib/libbsp/nios2
parent2008-08-31 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadrtems-35f52a69829e2a1e3180949ca38592d2b13034de.tar.bz2
2008-08-31 Joel Sherrill <joel.sherrill@oarcorp.com>
* timer/timer.c: Rename timer driver methods to follow RTEMS programming conventions.
Diffstat (limited to 'c/src/lib/libbsp/nios2')
-rw-r--r--c/src/lib/libbsp/nios2/nios2_iss/ChangeLog5
-rw-r--r--c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c20
2 files changed, 15 insertions, 10 deletions
diff --git a/c/src/lib/libbsp/nios2/nios2_iss/ChangeLog b/c/src/lib/libbsp/nios2/nios2_iss/ChangeLog
index 9c46ec8721..042d616a00 100644
--- a/c/src/lib/libbsp/nios2/nios2_iss/ChangeLog
+++ b/c/src/lib/libbsp/nios2/nios2_iss/ChangeLog
@@ -1,3 +1,8 @@
+2008-08-31 Joel Sherrill <joel.sherrill@oarcorp.com>
+
+ * timer/timer.c: Rename timer driver methods to follow RTEMS
+ programming conventions.
+
2008-05-15 Joel Sherrill <joel.sherrill@OARcorp.com>
* startup/bspstart.c: Add capability for bootcard.c BSP Initialization
diff --git a/c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c b/c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c
index 18ddb2bf4f..75588f8421 100644
--- a/c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c
+++ b/c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c
@@ -2,8 +2,8 @@
*
* This file manages the benchmark timer used by the RTEMS Timing Test
* Suite. Each measured time period is demarcated by calls to
- * Timer_initialize() and Read_timer(). Read_timer() usually returns
- * the number of microseconds since Timer_initialize() exitted.
+ * benchmark_timerinitialize() and benchmark_timerread(). benchmark_timerread() usually returns
+ * the number of microseconds since benchmark_timerinitialize() exitted.
*
* NOTE: It is important that the timer start/stop overhead be
* determined when porting or modifying this code.
@@ -27,7 +27,7 @@
#include <bsp.h>
volatile uint32_t Timer_interrupts;
-rtems_boolean Timer_driver_Find_average_overhead;
+rtems_boolean benchmark_timerfind_average_overhead;
#define TIMER_REGS ((altera_avalon_timer_regs*)NIOS2_IO_BASE(TIMER_BASE))
@@ -37,7 +37,7 @@ void timerisr( void )
Timer_interrupts++;
}
-void Timer_initialize( void )
+void benchmark_timerinitialize( void )
{
uint32_t old_ie;
@@ -83,7 +83,7 @@ void Timer_initialize( void )
}
/*
- * The following controls the behavior of Read_timer().
+ * The following controls the behavior of benchmark_timerread().
*
* AVG_OVEREHAD is the overhead for starting and stopping the timer. It
* is usually deducted from the number returned.
@@ -97,7 +97,7 @@ void Timer_initialize( void )
#define LEAST_VALID AVG_OVERHEAD /* Don't trust a value lower than this */
-int Read_timer( void )
+int benchmark_timerread( void )
{
uint32_t timer_wraps;
uint32_t timer_snap;
@@ -128,7 +128,7 @@ int Read_timer( void )
if(total < LEAST_VALID) return 0;
- if(Timer_driver_Find_average_overhead != TRUE) total-= AVG_OVERHEAD;
+ if(benchmark_timerfind_average_overhead != TRUE) total-= AVG_OVERHEAD;
return total;
}
@@ -138,14 +138,14 @@ int Read_timer( void )
* in Timing Test Suite.
*/
-rtems_status_code Empty_function( void )
+rtems_status_code benchmark_timerempty_function( void )
{
return RTEMS_SUCCESSFUL;
}
-void Set_find_average_overhead(
+void benchmark_timerdisable_subtracting_average_overhead(
rtems_boolean find_flag
)
{
- Timer_driver_Find_average_overhead = find_flag;
+ benchmark_timerfind_average_overhead = find_flag;
}