Changeset 25c62b0 in rtems


Ignore:
Timestamp:
Aug 31, 2008, 6:18:17 PM (11 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.9, master
Children:
5dff6e6e
Parents:
6b2923c
Message:

2008-08-31 Joel Sherrill <joel.sherrill@…>

  • timer/timer.c: Eliminate empty function from every benchmark timer driver. Fix spelling.
Location:
c/src/lib/libbsp
Files:
44 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/c4x/c4xsim/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/c4x/c4xsim/timer/timer.c

    r6b2923c r25c62b0  
    33 *  This file manages the benchmark timer used by the RTEMS Timing Test
    44 *  Suite.  Each measured time period is demarcated by calls to
    5  *  benchmark_timerinitialize() and benchmark_timerread().  benchmark_timerread() usually returns
    6  *  the number of microseconds since benchmark_timerinitialize() exitted.
     5 *  benchmark_timer_initialize() and benchmark_timer_read().  benchmark_timer_read() usually returns
     6 *  the number of microseconds since benchmark_timer_initialize() exitted.
    77 *
    88 *  NOTE: It is important that the timer start/stop overhead be
     
    2424
    2525uint32_t         Timer_interrupts;
    26 rtems_boolean benchmark_timerfind_average_overhead;
     26rtems_boolean benchmark_timer_find_average_overhead;
    2727
    2828static uint32_t   start;
    2929
    30 void benchmark_timerinitialize( void )
     30void benchmark_timer_initialize( void )
    3131{
    3232
     
    4949
    5050/*
    51  *  The following controls the behavior of benchmark_timerread().
     51 *  The following controls the behavior of benchmark_timer_read().
    5252 *
    5353 *  AVG_OVEREHAD is the overhead for starting and stopping the timer.  It
     
    6363#define LEAST_VALID       1  /* Don't trust a clicks value lower than this */
    6464
    65 int benchmark_timerread( void )
     65int benchmark_timer_read( void )
    6666{
    6767  uint32_t         clicks;
     
    8484  total = clicks * 1;
    8585
    86   if ( benchmark_timerfind_average_overhead == 1 ) {
     86  if ( benchmark_timer_find_average_overhead == 1 ) {
    8787    return total;          /* in count units where each count is */
    8888                           /* 1 / (clock frequency/2) */
     
    9898}
    9999
    100 /*
    101  *  Empty function call used in loops to measure basic cost of looping
    102  *  in Timing Test Suite.
    103  */
    104 
    105 rtems_status_code benchmark_timerempty_function( void )
    106 {
    107   return RTEMS_SUCCESSFUL;
    108 }
    109 
    110 void benchmark_timerdisable_subtracting_average_overhead(
     100void benchmark_timer_disable_subtracting_average_overhead(
    111101  rtems_boolean find_flag
    112102)
    113103{
    114   benchmark_timerfind_average_overhead = find_flag;
     104  benchmark_timer_find_average_overhead = find_flag;
    115105}
  • c/src/lib/libbsp/i386/i386ex/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/i386/i386ex/timer/timer.c

    r6b2923c r25c62b0  
    2929
    3030int Ttimer_val;
    31 rtems_boolean benchmark_timerfind_average_overhead;
     31rtems_boolean benchmark_timer_find_average_overhead;
    3232
    3333extern void timerisr(void);
     
    8282}
    8383
    84 void benchmark_timerinitialize(void)
     84void benchmark_timer_initialize(void)
    8585{
    8686
     
    9393    atexit(Timer_exit); /* Try not to hose the system at exit. */
    9494    if (!i386_set_idt_entry (&timer_raw_irq_data)) {
    95       printk("benchmark_timerinitialize: raw handler installation failed\n");
     95      printk("benchmark_timer_initialize: raw handler installation failed\n");
    9696      rtems_fatal_error_occurred(1);
    9797    }
     
    108108#define LEAST_VALID       4  /* Don't trust a value lower than this */
    109109
    110 int benchmark_timerread(void)
     110int benchmark_timer_read(void)
    111111{
    112112  register uint32_t         clicks;
     
    125125  /* ??? Is "do not restore old vector" causing problems? */
    126126
    127   if ( benchmark_timerfind_average_overhead == 1 )
     127  if ( benchmark_timer_find_average_overhead == 1 )
    128128    return total;          /* in one microsecond units */
    129129
     
    135135}
    136136
    137 rtems_status_code benchmark_timerempty_function( void )
    138 {
    139   return RTEMS_SUCCESSFUL;
    140 }
    141 
    142 void benchmark_timerdisable_subtracting_average_overhead(
     137void benchmark_timer_disable_subtracting_average_overhead(
    143138  rtems_boolean find_flag
    144139)
    145140{
    146   benchmark_timerfind_average_overhead = find_flag;
     141  benchmark_timer_find_average_overhead = find_flag;
    147142}
  • c/src/lib/libbsp/i386/pc386/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/i386/pc386/timer/timer.c

    r6b2923c r25c62b0  
    6060+--------------------------------------------------------------------------*/
    6161volatile uint32_t         Ttimer_val;
    62 rtems_boolean             benchmark_timerfind_average_overhead = TRUE;
     62rtems_boolean             benchmark_timer_find_average_overhead = TRUE;
    6363volatile unsigned int     fastLoop1ms, slowLoop1ms;
    64 void (*benchmark_timerinitialize_function)(void) = 0;
    65 uint32_t (*benchmark_timerread_function)(void) = 0;
     64void (*benchmark_timer_initialize_function)(void) = 0;
     65uint32_t (*benchmark_timer_read_function)(void) = 0;
    6666void (*Timer_exit_function)(void) = 0;
    6767
     
    113113
    114114/*-------------------------------------------------------------------------+
    115 |         Function: benchmark_timerinitialize
     115|         Function: benchmark_timer_initialize
    116116|      Description: Timer initialization routine.
    117117| Global Variables: Ttimer_val.
     
    134134
    135135/*-------------------------------------------------------------------------+
    136 |         Function: benchmark_timerread
     136|         Function: benchmark_timer_read
    137137|      Description: Read hardware timer value.
    138 | Global Variables: Ttimer_val, benchmark_timerfind_average_overhead.
     138| Global Variables: Ttimer_val, benchmark_timer_find_average_overhead.
    139139|        Arguments: None.
    140140|          Returns: Nothing.
     
    147147  total =  (uint32_t)(rdtsc() - Ttimer_val);
    148148
    149   if (benchmark_timerfind_average_overhead)
     149  if (benchmark_timer_find_average_overhead)
    150150    return total;
    151151  else if (total < LEAST_VALID)
     
    223223
    224224/*-------------------------------------------------------------------------+
    225 |         Function: benchmark_timerinitialize
     225|         Function: benchmark_timer_initialize
    226226|      Description: Timer initialization routine.
    227227| Global Variables: Ttimer_val.
     
    249249    continue;
    250250  Ttimer_val = 0;
    251 } /* benchmark_timerinitialize */
    252 
    253 /*-------------------------------------------------------------------------+
    254 |         Function: benchmark_timerread
     251} /* benchmark_timer_initialize */
     252
     253/*-------------------------------------------------------------------------+
     254|         Function: benchmark_timer_read
    255255|      Description: Read hardware timer value.
    256 | Global Variables: Ttimer_val, benchmark_timerfind_average_overhead.
     256| Global Variables: Ttimer_val, benchmark_timer_find_average_overhead.
    257257|        Arguments: None.
    258258|          Returns: Nothing.
     
    270270  total  = (Ttimer_val * US_PER_ISR) + (US_PER_ISR - TICK_TO_US(clicks));
    271271
    272   if (benchmark_timerfind_average_overhead)
     272  if (benchmark_timer_find_average_overhead)
    273273    return total;
    274274  else if (total < LEAST_VALID)
     
    284284
    285285void
    286 benchmark_timerinitialize(void)
     286benchmark_timer_initialize(void)
    287287{
    288288    static rtems_boolean First = TRUE;
     
    293293            printk("TSC: timer initialization\n");
    294294#endif /* DEBUG */
    295             benchmark_timerinitialize_function = &tsc_timer_initialize;
    296             benchmark_timerread_function = &tsc_read_timer;
     295            benchmark_timer_initialize_function = &tsc_timer_initialize;
     296            benchmark_timer_read_function = &tsc_read_timer;
    297297            Timer_exit_function = &tsc_timer_exit;
    298298        }
     
    301301            printk("ISR: timer initialization\n");
    302302#endif /* DEBUG */
    303             benchmark_timerinitialize_function = &i386_timer_initialize;
    304             benchmark_timerread_function = &i386_read_timer;
     303            benchmark_timer_initialize_function = &i386_timer_initialize;
     304            benchmark_timer_read_function = &i386_read_timer;
    305305            Timer_exit_function = &i386_timer_exit;
    306306        }
    307307        First = FALSE;
    308308    }
    309     (*benchmark_timerinitialize_function)();
     309    (*benchmark_timer_initialize_function)();
    310310}
    311311
    312312uint32_t
    313 benchmark_timerread(void)
    314 {
    315     return (*benchmark_timerread_function)();
     313benchmark_timer_read(void)
     314{
     315    return (*benchmark_timer_read_function)();
    316316}
    317317
     
    323323
    324324/*-------------------------------------------------------------------------+
    325 |         Function: benchmark_timerempty_function
    326 |      Description: Empty function used in time tests.
    327 | Global Variables: None.
    328 |        Arguments: None.
    329 |          Returns: Nothing.
    330 +--------------------------------------------------------------------------*/
    331 rtems_status_code benchmark_timerempty_function(void)
    332 {
    333   return RTEMS_SUCCESSFUL;
    334 } /* Empty function */
    335 
    336 /*-------------------------------------------------------------------------+
    337 |         Function: benchmark_timerdisable_subtracting_average_overhead
    338 |      Description: Set internal benchmark_timerfind_average_overhead flag value.
    339 | Global Variables: benchmark_timerfind_average_overhead.
     325|         Function: benchmark_timer_disable_subtracting_average_overhead
     326|      Description: Set internal benchmark_timer_find_average_overhead flag value.
     327| Global Variables: benchmark_timer_find_average_overhead.
    340328|        Arguments: find_flag - new value of the flag.
    341329|          Returns: Nothing.
    342330+--------------------------------------------------------------------------*/
    343331void
    344 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
    345 {
    346   benchmark_timerfind_average_overhead = find_flag;
    347 } /* benchmark_timerdisable_subtracting_average_overhead */
     332benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
     333{
     334  benchmark_timer_find_average_overhead = find_flag;
     335} /* benchmark_timer_disable_subtracting_average_overhead */
    348336
    349337static unsigned short lastLoadedValue;
  • c/src/lib/libbsp/i386/ts_386ex/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/i386/ts_386ex/timer/timer.c

    r6b2923c r25c62b0  
    2929
    3030volatile uint32_t          Ttimer_val;  /* Updated from ISR!!! */
    31 rtems_boolean benchmark_timerfind_average_overhead;
     31rtems_boolean benchmark_timer_find_average_overhead;
    3232
    3333extern void timerisr(void);
     
    9797}
    9898
    99 void benchmark_timerinitialize(void)
     99void benchmark_timer_initialize(void)
    100100{
    101101
     
    107107
    108108    if (!i386_get_current_idt_entry (&old_raw_irq_data)) {
    109       printk("benchmark_timerinitialize: failed to get old raw irq entry.\n");
     109      printk("benchmark_timer_initialize: failed to get old raw irq entry.\n");
    110110      rtems_fatal_error_occurred(1);
    111111    }
    112112
    113113    if (!i386_delete_idt_entry (&old_raw_irq_data)) {
    114       printk("benchmark_timerinitialize: failed to delete old raw irq entry.\n");
     114      printk("benchmark_timer_initialize: failed to delete old raw irq entry.\n");
    115115      rtems_fatal_error_occurred(1);
    116116    }
     
    118118    atexit(Timer_exit); /* Try not to hose the system at exit. */
    119119    if (!i386_set_idt_entry (&timer_raw_irq_data)) {
    120       printk("benchmark_timerinitialize: raw handler installation failed.\n");
     120      printk("benchmark_timer_initialize: raw handler installation failed.\n");
    121121      rtems_fatal_error_occurred(1);
    122122    }
     
    134134#define LEAST_VALID       4  /* Don't trust a value lower than this */
    135135
    136 int benchmark_timerread(void)
     136int benchmark_timer_read(void)
    137137{
    138138  register uint32_t         clicks, total;
     
    156156  total = Ttimer_val * US_PER_ISR + (US_PER_ISR - clicks);
    157157
    158   if ( benchmark_timerfind_average_overhead == 1 )
     158  if ( benchmark_timer_find_average_overhead == 1 )
    159159    return total;          /* in one microsecond units */
    160160  else if ( total < LEAST_VALID )
     
    164164}
    165165
    166 rtems_status_code benchmark_timerempty_function( void )
    167 {
    168   return RTEMS_SUCCESSFUL;
    169 }
    170 
    171 void benchmark_timerdisable_subtracting_average_overhead(
     166void benchmark_timer_disable_subtracting_average_overhead(
    172167  rtems_boolean find_flag
    173168)
    174169{
    175   benchmark_timerfind_average_overhead = find_flag;
     170  benchmark_timer_find_average_overhead = find_flag;
    176171}
    177172
  • c/src/lib/libbsp/m68k/av5282/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/av5282/timer/timer.c

    r6b2923c r25c62b0  
    99
    1010void
    11 benchmark_timerinitialize(void)
     11benchmark_timer_initialize(void)
    1212{
    1313    int preScaleDivisor = 58;
     
    2323 */
    2424int
    25 benchmark_timerread(void)
     25benchmark_timer_read(void)
    2626{
    2727    return MCF5282_TIMER3_DTCN;
    2828}
    2929
    30 /*
    31  *  Empty function call used in loops to measure basic cost of looping
    32  *  in Timing Test Suite.
    33  */
    34 rtems_status_code
    35 benchmark_timerempty_function(void)
    36 {
    37     return RTEMS_SUCCESSFUL;
    38 }
    39 
    4030void
    41 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     31benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    4232{
    4333}
  • c/src/lib/libbsp/m68k/gen68360/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/gen68360/timer/timer.c

    r6b2923c r25c62b0  
    4040
    4141void
    42 benchmark_timerinitialize (void)
     42benchmark_timer_initialize (void)
    4343{
    4444        /*
     
    7474 */
    7575int
    76 benchmark_timerread (void)
     76benchmark_timer_read (void)
    7777{
    7878        return *(uint32_t*)&m360.tcn1;
    7979}
    8080
    81 /*
    82  * Empty function call used in loops to measure basic cost of looping
    83  * in Timing Test Suite.
    84  */
    85 rtems_status_code
    86 benchmark_timerempty_function (void)
    87 {
    88         return RTEMS_SUCCESSFUL;
    89 }
    90 
    9181void
    92 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     82benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    9383{
    9484}
  • c/src/lib/libbsp/m68k/genmcf548x/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/genmcf548x/timer/timer.c

    r6b2923c r25c62b0  
    5555#include <mcf548x/mcf548x.h>
    5656
    57 rtems_boolean benchmark_timerfind_average_overhead;
     57rtems_boolean benchmark_timer_find_average_overhead;
    5858static uint32_t microsecond_timer_value = 0;
    5959
    60 void benchmark_timerinitialize(void)
     60void benchmark_timer_initialize(void)
    6161{
    6262MCF548X_SLT_SLTCNT1 = 0xFFFFFFFF;
     
    6969 */
    7070int
    71 benchmark_timerread(void)
     71benchmark_timer_read(void)
    7272{
    7373        microsecond_timer_value = (0xFFFFFFFF - MCF548X_SLT_SCNT1)/100;
     
    7575}
    7676
    77 /*
    78  *  Empty function call used in loops to measure basic cost of looping
    79  *  in Timing Test Suite.
    80  */
    81 rtems_status_code
    82 benchmark_timerempty_function(void)
     77void
     78benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    8379{
    84     return RTEMS_SUCCESSFUL;
     80benchmark_timer_find_average_overhead = find_flag;
    8581}
    86 
    87 void
    88 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
    89 {
    90 benchmark_timerfind_average_overhead = find_flag;
    91 }
    92 
    93 
    94 
  • c/src/lib/libbsp/m68k/idp/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/idp/timer/timer.c

    r6b2923c r25c62b0  
    3333
    3434int Ttimer_val;
    35 rtems_boolean benchmark_timerfind_average_overhead;
     35rtems_boolean benchmark_timer_find_average_overhead;
    3636
    3737rtems_isr timerisr(void);
    3838
    39 void benchmark_timerinitialize(void)
     39void benchmark_timer_initialize(void)
    4040{
    4141  (void) set_vector( timerisr, TIMER_VECTOR, 0 );  /* install ISR */
     
    6565#define LEAST_VALID       10 /* Don't trust a value lower than this */
    6666
    67 int benchmark_timerread(void)
     67int benchmark_timer_read(void)
    6868{
    6969  uint8_t         data;
     
    9494
    9595  /* do not restore old vector */
    96   if ( benchmark_timerfind_average_overhead == 1 )
     96  if ( benchmark_timer_find_average_overhead == 1 )
    9797    return total;          /* in countdown units */
    9898
     
    106106}
    107107
    108 rtems_status_code benchmark_timerempty_function( void )
    109 {
    110   return RTEMS_SUCCESSFUL;
    111 }
    112 
    113 void benchmark_timerdisable_subtracting_average_overhead(
     108void benchmark_timer_disable_subtracting_average_overhead(
    114109  rtems_boolean find_flag
    115110)
    116111{
    117   benchmark_timerfind_average_overhead = find_flag;
     112  benchmark_timer_find_average_overhead = find_flag;
    118113}
  • c/src/lib/libbsp/m68k/mcf52235/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mcf52235/timer/timer.c

    r6b2923c r25c62b0  
    1717#include <bsp.h>
    1818
    19 void benchmark_timerinitialize(void)
     19void benchmark_timer_initialize(void)
    2020{
    2121  uint32_t preScaleDivisor = bsp_get_CPU_clock_speed() / 1000000;
     
    2929 * Return timer value in microsecond units
    3030 */
    31 int benchmark_timerread(void)
     31int benchmark_timer_read(void)
    3232{
    3333  return MCF_DTIM3_DTCN;
    3434}
    3535
    36 /*
    37  *  Empty function call used in loops to measure basic cost of looping
    38  *  in Timing Test Suite.
    39  */
    40 rtems_status_code benchmark_timerempty_function(void)
    41 {
    42   return RTEMS_SUCCESSFUL;
    43 }
    44 
    45 void benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     36void benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    4637{
    4738}
  • c/src/lib/libbsp/m68k/mcf5235/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mcf5235/timer/timer.c

    r6b2923c r25c62b0  
    99
    1010void
    11 benchmark_timerinitialize(void)
     11benchmark_timer_initialize(void)
    1212{
    1313    int preScaleDivisor = 0x4A;
     
    2323 */
    2424int
    25 benchmark_timerread(void)
     25benchmark_timer_read(void)
    2626{
    2727    return MCF5235_TIMER3_DTCN;
    2828}
    2929
    30 /*
    31  *  Empty function call used in loops to measure basic cost of looping
    32  *  in Timing Test Suite.
    33  */
    34 rtems_status_code
    35 benchmark_timerempty_function(void)
    36 {
    37     return RTEMS_SUCCESSFUL;
    38 }
    39 
    4030void
    41 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     31benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    4232{
    4333}
  • c/src/lib/libbsp/m68k/mcf5329/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mcf5329/timer/timer.c

    r6b2923c r25c62b0  
    1818#include <bsp.h>
    1919
    20 void benchmark_timerinitialize(void)
     20void benchmark_timer_initialize(void)
    2121{
    2222  uint32_t preScaleDivisor = bsp_get_BUS_clock_speed() / 1000000;
     
    3030 * Return timer value in microsecond units
    3131 */
    32 int benchmark_timerread(void)
     32int benchmark_timer_read(void)
    3333{
    3434  return MCF_DTIM3_DTCN;
    3535}
    3636
    37 /*
    38  *  Empty function call used in loops to measure basic cost of looping
    39  *  in Timing Test Suite.
    40  */
    41 rtems_status_code benchmark_timerempty_function(void)
    42 {
    43   return RTEMS_SUCCESSFUL;
    44 }
    45 
    46 void benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     37void benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    4738{
    4839}
  • c/src/lib/libbsp/m68k/mrm332/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mrm332/timer/timer.c

    r6b2923c r25c62b0  
    2222#include <bsp.h>
    2323
    24 rtems_boolean benchmark_timerfind_average_overhead;
     24rtems_boolean benchmark_timer_find_average_overhead;
    2525
    2626extern rtems_isr Clock_isr(void);
    2727
    28 void benchmark_timerinitialize( void )
     28void benchmark_timer_initialize( void )
    2929{
    3030}
    3131
    3232/*
    33  *  The following controls the behavior of benchmark_timerread().
     33 *  The following controls the behavior of benchmark_timer_read().
    3434 *
    3535 *  FIND_AVG_OVERHEAD *  instructs the routine to return the "raw" count.
     
    5050 * Return timer value in 1/2-microsecond units
    5151 */
    52 int benchmark_timerread( void )
     52int benchmark_timer_read( void )
    5353{
    5454  uint32_t         total;
    5555  total = 0;
    5656
    57   if ( benchmark_timerfind_average_overhead == 1 )
     57  if ( benchmark_timer_find_average_overhead == 1 )
    5858    return total;          /* in XXX microsecond units */
    5959
     
    6464}
    6565
    66 /*
    67  *  Empty function call used in loops to measure basic cost of looping
    68  *  in Timing Test Suite.
    69  */
    70 
    71 rtems_status_code benchmark_timerempty_function(void)
    72 {
    73     return RTEMS_SUCCESSFUL;
    74 }
    75 
    76 void benchmark_timerdisable_subtracting_average_overhead(
     66void benchmark_timer_disable_subtracting_average_overhead(
    7767  rtems_boolean find_flag
    7868)
    7969{
    80   benchmark_timerfind_average_overhead = find_flag;
     70  benchmark_timer_find_average_overhead = find_flag;
    8171}
  • c/src/lib/libbsp/m68k/mvme136/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mvme136/timer/timer.c

    r6b2923c r25c62b0  
    3030
    3131int Ttimer_val;
    32 rtems_boolean benchmark_timerfind_average_overhead;
     32rtems_boolean benchmark_timer_find_average_overhead;
    3333
    3434rtems_isr timerisr(void);
    3535
    36 void benchmark_timerinitialize(void)
     36void benchmark_timer_initialize(void)
    3737{
    3838  (void) set_vector( timerisr, 66, 0 );       /* install ISR */
     
    6666#define LEAST_VALID       10 /* Don't trust a value lower than this */
    6767
    68 int benchmark_timerread(void)
     68int benchmark_timer_read(void)
    6969{
    7070/*
     
    8383  total = (Ttimer_val * 0x10000) + remaining;
    8484
    85   if ( benchmark_timerfind_average_overhead == 1 )
     85  if ( benchmark_timer_find_average_overhead == 1 )
    8686    return total;          /* in one-half microsecond units */
    8787
     
    9393}
    9494
    95 rtems_status_code benchmark_timerempty_function( void )
    96 {
    97   return RTEMS_SUCCESSFUL;
    98 }
    99 
    100 void benchmark_timerdisable_subtracting_average_overhead(
     95void benchmark_timer_disable_subtracting_average_overhead(
    10196  rtems_boolean find_flag
    10297)
    10398{
    104   benchmark_timerfind_average_overhead = find_flag;
     99  benchmark_timer_find_average_overhead = find_flag;
    105100}
  • c/src/lib/libbsp/m68k/mvme147/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mvme147/timer/timer.c

    r6b2923c r25c62b0  
    3333
    3434int Ttimer_val;
    35 rtems_boolean benchmark_timerfind_average_overhead;
     35rtems_boolean benchmark_timer_find_average_overhead;
    3636
    3737rtems_isr timerisr(void);
    3838
    39 void benchmark_timerinitialize(void)
     39void benchmark_timer_initialize(void)
    4040{
    4141  (void) set_vector(timerisr, TIMER_1_VECTOR, 0); /* install ISR */
     
    5757#define LEAST_VALID       10 /* Don't trust a value lower than this */
    5858
    59 int benchmark_timerread(void)
     59int benchmark_timer_read(void)
    6060{
    6161  uint32_t         total;
     
    7171}
    7272
    73 rtems_status_code benchmark_timerempty_function( void )
    74 {
    75   return RTEMS_SUCCESSFUL;
    76 }
    77 
    78 void benchmark_timerdisable_subtracting_average_overhead(
     73void benchmark_timer_disable_subtracting_average_overhead(
    7974  rtems_boolean find_flag
    8075)
    8176{
    82   benchmark_timerfind_average_overhead = find_flag;
     77  benchmark_timer_find_average_overhead = find_flag;
    8378}
  • c/src/lib/libbsp/m68k/mvme162/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/mvme162/timer/timer.c

    r6b2923c r25c62b0  
    3939
    4040uint32_t            Ttimer_val;
    41 rtems_boolean       benchmark_timerfind_average_overhead;
     41rtems_boolean       benchmark_timer_find_average_overhead;
    4242
    4343rtems_isr timerisr(void);
    4444
    45 void benchmark_timerinitialize(void)
     45void benchmark_timer_initialize(void)
    4646{
    4747  (void) set_vector( timerisr, VBR0 * 0x10 + 0x8, 0 );
     
    6464#define LEAST_VALID       10U   /* Don't trust a value lower than this */
    6565
    66 int benchmark_timerread(void)
     66int benchmark_timer_read(void)
    6767{
    6868  uint32_t            total;
     
    7070  total = (Ttimer_val * TICK_INTERVAL) + lcsr->timer_cnt_1;
    7171
    72   if ( benchmark_timerfind_average_overhead == 1 )
     72  if ( benchmark_timer_find_average_overhead == 1 )
    7373    return total;          /* in one-half microsecond units */
    7474
     
    7979}
    8080
    81 rtems_status_code benchmark_timerempty_function( void )
    82 {
    83   return RTEMS_SUCCESSFUL;
    84 }
    85 
    86 void benchmark_timerdisable_subtracting_average_overhead(
     81void benchmark_timer_disable_subtracting_average_overhead(
    8782  rtems_boolean find_flag
    8883)
    8984{
    90   benchmark_timerfind_average_overhead = find_flag;
     85  benchmark_timer_find_average_overhead = find_flag;
    9186}
  • c/src/lib/libbsp/m68k/uC5282/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/m68k/uC5282/timer/timer.c

    r6b2923c r25c62b0  
    1818
    1919void
    20 benchmark_timerinitialize(void)
     20benchmark_timer_initialize(void)
    2121{
    2222    int preScaleDivisor = bsp_get_CPU_clock_speed() / 1000000;
     
    3636 */
    3737int
    38 benchmark_timerread(void)
     38benchmark_timer_read(void)
    3939{
    4040    return MCF5282_TIMER3_DTCN;
    4141}
    4242
    43 /*
    44  *  Empty function call used in loops to measure basic cost of looping
    45  *  in Timing Test Suite.
    46  */
    47 rtems_status_code
    48 benchmark_timerempty_function(void)
    49 {
    50     return RTEMS_SUCCESSFUL;
    51 }
    52 
    5343void
    54 benchmark_timerdisable_subtracting_average_overhead(rtems_boolean find_flag)
     44benchmark_timer_disable_subtracting_average_overhead(rtems_boolean find_flag)
    5545{
    5646}
  • c/src/lib/libbsp/mips/csb350/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/mips/csb350/timer/timer.c

    r6b2923c r25c62b0  
    1717#include <bsp.h>
    1818
    19 rtems_boolean benchmark_timerfind_average_overhead;
     19rtems_boolean benchmark_timer_find_average_overhead;
    2020uint32_t tstart;
    2121
    22 void benchmark_timerinitialize(void)
     22void benchmark_timer_initialize(void)
    2323{
    2424    asm volatile ("mfc0 %0, $9\n" : "=r" (tstart));
     
    3131                             /* tx39 simulator can count instructions. :) */
    3232
    33 int benchmark_timerread(void)
     33int benchmark_timer_read(void)
    3434{
    3535  uint32_t  total;
     
    4242
    4343
    44   if ( benchmark_timerfind_average_overhead == 1 )
     44  if ( benchmark_timer_find_average_overhead == 1 )
    4545    return total;          /* in one microsecond units */
    4646
     
    5151}
    5252
    53 rtems_status_code benchmark_timerempty_function( void )
    54 {
    55   return RTEMS_SUCCESSFUL;
    56 }
    57 
    58 void benchmark_timerdisable_subtracting_average_overhead(
     53void benchmark_timer_disable_subtracting_average_overhead(
    5954  rtems_boolean find_flag
    6055)
    6156{
    62   benchmark_timerfind_average_overhead = find_flag;
     57  benchmark_timer_find_average_overhead = find_flag;
    6358}
  • c/src/lib/libbsp/mips/genmongoosev/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/mips/genmongoosev/timer/timer.c

    r6b2923c r25c62b0  
    1616#include <bsp.h>
    1717
    18 rtems_boolean benchmark_timerfind_average_overhead;
     18rtems_boolean benchmark_timer_find_average_overhead;
    1919
    2020#if defined(USE_TIMER2_FOR_CLOCK)
     
    2626#endif
    2727
    28 void benchmark_timerinitialize(void)
     28void benchmark_timer_initialize(void)
    2929{
    3030  /*
     
    5757#include <rtems/bspIo.h>
    5858
    59 int benchmark_timerread(void)
     59int benchmark_timer_read(void)
    6060{
    6161  uint32_t          clicks;
     
    7676    printk( "MG5 timer overran\n" );
    7777
    78   if ( benchmark_timerfind_average_overhead == 1 )
     78  if ( benchmark_timer_find_average_overhead == 1 )
    7979    return total;          /* in cycle units */
    8080
     
    8585}
    8686
    87 rtems_status_code benchmark_timerempty_function( void )
    88 {
    89   return RTEMS_SUCCESSFUL;
    90 }
    91 
    92 void benchmark_timerdisable_subtracting_average_overhead(
     87void benchmark_timer_disable_subtracting_average_overhead(
    9388  rtems_boolean find_flag
    9489)
    9590{
    96   benchmark_timerfind_average_overhead = find_flag;
     91  benchmark_timer_find_average_overhead = find_flag;
    9792}
    9893
  • c/src/lib/libbsp/mips/jmr3904/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/mips/jmr3904/timer/timer.c

    r6b2923c r25c62b0  
    1818#include <bsp.h>
    1919
    20 rtems_boolean benchmark_timerfind_average_overhead;
     20rtems_boolean benchmark_timer_find_average_overhead;
    2121
    22 void benchmark_timerinitialize(void)
     22void benchmark_timer_initialize(void)
    2323{
    2424  /*
     
    4646                             /* tx39 simulator can count instructions. :) */
    4747
    48 int benchmark_timerread(void)
     48int benchmark_timer_read(void)
    4949{
    5050  uint32_t          total;
     
    5252  total = TX3904_TIMER_READ( TX3904_TIMER1_BASE, TX3904_TIMER_TRR );
    5353
    54   if ( benchmark_timerfind_average_overhead == 1 )
     54  if ( benchmark_timer_find_average_overhead == 1 )
    5555    return total;          /* in one microsecond units */
    5656
     
    6161}
    6262
    63 rtems_status_code benchmark_timerempty_function( void )
    64 {
    65   return RTEMS_SUCCESSFUL;
    66 }
    67 
    68 void benchmark_timerdisable_subtracting_average_overhead(
     63void benchmark_timer_disable_subtracting_average_overhead(
    6964  rtems_boolean find_flag
    7065)
    7166{
    72   benchmark_timerfind_average_overhead = find_flag;
     67  benchmark_timer_find_average_overhead = find_flag;
    7368}
  • c/src/lib/libbsp/nios2/nios2_iss/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/nios2/nios2_iss/timer/timer.c

    r6b2923c r25c62b0  
    33 *  This file manages the benchmark timer used by the RTEMS Timing Test
    44 *  Suite.  Each measured time period is demarcated by calls to
    5  *  benchmark_timerinitialize() and benchmark_timerread().  benchmark_timerread() usually returns
    6  *  the number of microseconds since benchmark_timerinitialize() exitted.
     5 *  benchmark_timer_initialize() and benchmark_timer_read().  benchmark_timer_read() usually returns
     6 *  the number of microseconds since benchmark_timer_initialize() exitted.
    77 *
    88 *  NOTE: It is important that the timer start/stop overhead be
     
    2828
    2929volatile uint32_t Timer_interrupts;
    30 rtems_boolean    benchmark_timerfind_average_overhead;
     30rtems_boolean    benchmark_timer_find_average_overhead;
    3131
    3232#define TIMER_REGS ((altera_avalon_timer_regs*)NIOS2_IO_BASE(TIMER_BASE))
     
    3838}
    3939
    40 void benchmark_timerinitialize( void )
     40void benchmark_timer_initialize( void )
    4141{
    4242  uint32_t old_ie;
     
    8484
    8585/*
    86  *  The following controls the behavior of benchmark_timerread().
     86 *  The following controls the behavior of benchmark_timer_read().
    8787 *
    8888 *  AVG_OVEREHAD is the overhead for starting and stopping the timer.  It
     
    9898#define LEAST_VALID AVG_OVERHEAD /* Don't trust a value lower than this */
    9999
    100 int benchmark_timerread( void )
     100int benchmark_timer_read( void )
    101101{
    102102  uint32_t timer_wraps;
     
    129129  if(total < LEAST_VALID) return 0;
    130130
    131   if(benchmark_timerfind_average_overhead != TRUE) total-= AVG_OVERHEAD;
     131  if(benchmark_timer_find_average_overhead != TRUE) total-= AVG_OVERHEAD;
    132132 
    133133  return total;
    134134}
    135135
    136 /*
    137  *  Empty function call used in loops to measure basic cost of looping
    138  *  in Timing Test Suite.
    139  */
    140 
    141 rtems_status_code benchmark_timerempty_function( void )
    142 {
    143   return RTEMS_SUCCESSFUL;
    144 }
    145 
    146 void benchmark_timerdisable_subtracting_average_overhead(
     136void benchmark_timer_disable_subtracting_average_overhead(
    147137  rtems_boolean find_flag
    148138)
    149139{
    150   benchmark_timerfind_average_overhead = find_flag;
     140  benchmark_timer_find_average_overhead = find_flag;
    151141}
  • c/src/lib/libbsp/powerpc/score603e/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/powerpc/score603e/timer/timer.c

    r6b2923c r25c62b0  
    2424uint64_t         Timer_driver_Start_time;
    2525
    26 rtems_boolean benchmark_timerfind_average_overhead;
     26rtems_boolean benchmark_timer_find_average_overhead;
    2727
    2828/*
    29  * benchmark_timerinitialize
     29 * benchmark_timer_initialize
    3030 */
    3131
    32 void benchmark_timerinitialize()
     32void benchmark_timer_initialize()
    3333{
    3434
     
    4141
    4242/*
    43  *  benchmark_timerread
     43 *  benchmark_timer_read
    4444 */
    4545
    46 int benchmark_timerread()
     46int benchmark_timer_read()
    4747{
    4848  uint64_t          clicks;
     
    6262  total = (uint32_t) total64;
    6363
    64   if ( benchmark_timerfind_average_overhead == 1 )
     64  if ( benchmark_timer_find_average_overhead == 1 )
    6565    return total;          /* in "clicks" of the decrementer units */
    6666
     
    7171}
    7272
    73 rtems_status_code benchmark_timerempty_function( void )
    74 {
    75   return RTEMS_SUCCESSFUL;
    76 }
    77 
    78 void benchmark_timerdisable_subtracting_average_overhead(
     73void benchmark_timer_disable_subtracting_average_overhead(
    7974  rtems_boolean find_flag
    8075)
    8176{
    82   benchmark_timerfind_average_overhead = find_flag;
     77  benchmark_timer_find_average_overhead = find_flag;
    8378}
  • c/src/lib/libbsp/sh/simsh4/ChangeLog

    r6b2923c r25c62b0  
     12008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * timer/timer.c: Eliminate empty function from every benchmark timer
     4        driver. Fix spelling.
     5
    162008-08-31      Joel Sherrill <joel.sherrill@oarcorp.com>
    27
  • c/src/lib/libbsp/sh/simsh4/timer/timer.c

    r6b2923c r25c62b0  
    2323uint32_t         Timer_interrupts;
    2424
    25 bool benchmark_timerfind_average_overhead;
     25bool benchmark_timer_find_average_overhead;
    2626
    2727/* External assembler interrupt handler routine */
    2828extern rtems_isr timerisr(rtems_vector_number vector);
    2929
    30 /* benchmark_timerinitialize --
     30/* benchmark_timer_initialize --
    3131 *     Initialize timer 2 for accurate time measurement.
    3232 *
     
    3838 */
    3939void
    40 benchmark_timerinitialize(void)
     40benchmark_timer_initialize(void)
    4141{
    4242    return;
     
    4444
    4545/*
    46  *  The following controls the behavior of benchmark_timerread().
     46 *  The following controls the behavior of benchmark_timer_read().
    4747 *
    4848 *  FIND_AVG_OVERHEAD *  instructs the routine to return the "raw" count.
     
    6060#define LEAST_VALID       1  /* Don't trust a clicks value lower than this */
    6161
    62 /* benchmark_timerread --
     62/* benchmark_timer_read --
    6363 *     Read timer value in microsecond units since timer start.
    6464 *
     
    7070 */
    7171int
    72 benchmark_timerread( void )
     72benchmark_timer_read( void )
    7373{
    7474    return 0;
    7575}
    7676
    77 /* benchmark_timerempty_function --
    78  *     Empty function call used in loops to measure basic cost of looping
    79  *     in Timing Test Suite.
    80  *
    81  * PARAMETERS:
    82  *     none
    83  *
    84  * RETURNS:
    85  *     RTEMS_SUCCESSFUL
    86  */
    87 rtems_status_code
    88 benchmark_timerempty_function(void)
    89 {
    90     return RTEMS_SUCCESSFUL;
    91 }
    92 
    93 /* benchmark_timerdisable_subtracting_average_overhead --
     77/* benchmark_timer_disable_subtracting_average_overhead --
    9478 *     This routine is invoked by the "Check Timer" (tmck) test in the
    95  *     RTEMS Timing Test Suite. It makes the benchmark_timerread routine not
     79 *     RTEMS Timing Test Suite. It makes the benchmark_timer_read routine not
    9680 *     subtract the overhead required to initialize and read the benchmark
    9781 *     timer.
     
    10488 */
    10589void
    106 benchmark_timerdisable_subtracting_average_overhead(bool find_flag)
     90benchmark_timer_disable_subtracting_average_overhead(bool find_flag)
    10791{
    108   benchmark_timerfind_average_overhead = find_flag;
     92  benchmark_timer_find_average_overhead = find_flag;
    10993}
Note: See TracChangeset for help on using the changeset viewer.