Convert to "bool".

This commit is contained in:
Ralf Corsepius
2008-09-05 08:08:39 +00:00
parent 4d4c81262e
commit 14d7c5a7b5
4 changed files with 9 additions and 9 deletions

View File

@@ -23,7 +23,7 @@
#include <rtems/tic4x/c4xio.h> #include <rtems/tic4x/c4xio.h>
uint32_t Timer_interrupts; uint32_t Timer_interrupts;
rtems_boolean benchmark_timer_find_average_overhead; bool benchmark_timer_find_average_overhead;
static uint32_t start; static uint32_t start;
@@ -83,7 +83,7 @@ int benchmark_timer_read( void )
total = clicks * 1; total = clicks * 1;
if ( benchmark_timer_find_average_overhead == 1 ) { if ( benchmark_timer_find_average_overhead == true ) {
return total; /* in count units where each count is */ return total; /* in count units where each count is */
/* 1 / (clock frequency/2) */ /* 1 / (clock frequency/2) */
} else { } else {
@@ -98,7 +98,7 @@ int benchmark_timer_read( void )
} }
void benchmark_timer_disable_subtracting_average_overhead( void benchmark_timer_disable_subtracting_average_overhead(
rtems_boolean find_flag bool find_flag
) )
{ {
benchmark_timer_find_average_overhead = find_flag; benchmark_timer_find_average_overhead = find_flag;

View File

@@ -11,7 +11,7 @@
#include <bsp.h> #include <bsp.h>
rtems_boolean benchmark_timer_find_average_overhead; bool benchmark_timer_find_average_overhead;
void benchmark_timer_initialize(void) void benchmark_timer_initialize(void)
{ {
@@ -25,7 +25,7 @@ int benchmark_timer_read(void)
} }
void benchmark_timer_disable_subtracting_average_overhead( void benchmark_timer_disable_subtracting_average_overhead(
rtems_boolean find_flag bool find_flag
) )
{ {
benchmark_timer_find_average_overhead = find_flag; benchmark_timer_find_average_overhead = find_flag;

View File

@@ -188,7 +188,7 @@ void getRealTime(
*/ */
/* XXX this routine should be part of the public RTEMS interface */ /* XXX this routine should be part of the public RTEMS interface */
rtems_boolean _TOD_Validate( rtems_time_of_day *tod ); extern bool _TOD_Validate( rtems_time_of_day *tod );
int setRealTime( int setRealTime(
rtems_time_of_day *tod rtems_time_of_day *tod

View File

@@ -23,7 +23,7 @@ struct timeval Timer_start;
struct timeval Timer_stop; struct timeval Timer_stop;
struct timezone Time_zone; struct timezone Time_zone;
rtems_boolean benchmark_timer_find_average_overhead; bool benchmark_timer_find_average_overhead;
void benchmark_timer_initialize() void benchmark_timer_initialize()
{ {
@@ -48,7 +48,7 @@ int benchmark_timer_read()
total += Timer_stop.tv_usec; total += Timer_stop.tv_usec;
} }
if ( benchmark_timer_find_average_overhead == 1 ) if ( benchmark_timer_find_average_overhead == true )
return total; /* in countdown units */ return total; /* in countdown units */
else { else {
if ( total < LEAST_VALID ) if ( total < LEAST_VALID )
@@ -58,7 +58,7 @@ int benchmark_timer_read()
} }
void benchmark_timer_disable_subtracting_average_overhead( void benchmark_timer_disable_subtracting_average_overhead(
rtems_boolean find_flag bool find_flag
) )
{ {
benchmark_timer_find_average_overhead = find_flag; benchmark_timer_find_average_overhead = find_flag;