From 8fbe2e69b544479feb5a361c6aebeae53eb827c8 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Thu, 4 Sep 2014 08:59:49 -0500 Subject: Use correct prototype of benchmark_timer_read() This change starts with removing the effectively empty file timerdrv.h. The prototypes for benchmark_timer_XXX() were in btimer.h which was not universally used. Thus every use of timerdrv.h had to be changed to btimer.h. Then the prototypes for benchmark_timer_read() had to be adjusted to return benchmark_timer_t rather than int or uint32_t. I took this opportunity to also correct the file headers to separate the copyright from the file description comments which is needed to ensure the copyright isn't propagated into Doxygen output. --- c/src/lib/libcpu/m68k/mcf5206/timer/timer.c | 12 ++++++++---- c/src/lib/libcpu/m68k/mcf5206/timer/timerisr.S | 11 +++++++---- c/src/lib/libcpu/m68k/mcf5272/timer/timer.c | 11 +++++++---- c/src/lib/libcpu/m68k/mcf5272/timer/timerisr.S | 12 ++++++------ 4 files changed, 28 insertions(+), 18 deletions(-) (limited to 'c/src/lib/libcpu/m68k') diff --git a/c/src/lib/libcpu/m68k/mcf5206/timer/timer.c b/c/src/lib/libcpu/m68k/mcf5206/timer/timer.c index a95521bb77..dbeebc80e0 100644 --- a/c/src/lib/libcpu/m68k/mcf5206/timer/timer.c +++ b/c/src/lib/libcpu/m68k/mcf5206/timer/timer.c @@ -1,8 +1,11 @@ -/* - * Timer Init +/** + * @file + * @brief Timer Init * * This module initializes TIMER 2 for on the MCF5206E for benchmarks. - * + */ + +/* * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia * Author: Victor V. Vengerov * @@ -21,6 +24,7 @@ #include #include +#include #include "mcf5206/mcf5206e.h" #define TRR2_VAL 65530 @@ -99,7 +103,7 @@ benchmark_timer_initialize(void) * RETURNS: * number of microseconds since timer has been started */ -int +benchmark_timer_t benchmark_timer_read( void ) { uint16_t clicks; diff --git a/c/src/lib/libcpu/m68k/mcf5206/timer/timerisr.S b/c/src/lib/libcpu/m68k/mcf5206/timer/timerisr.S index 2d4c5bc24d..bbcf6e2d6a 100644 --- a/c/src/lib/libcpu/m68k/mcf5206/timer/timerisr.S +++ b/c/src/lib/libcpu/m68k/mcf5206/timer/timerisr.S @@ -1,5 +1,6 @@ -/* - * Handle MCF5206 TIMER2 interrupts. +/** + * @file + * @brief Handle MCF5206 TIMER2 interrupts * * All code in this routine is pure overhead which can perturb the * accuracy of RTEMS' timing test suite. @@ -11,7 +12,9 @@ * occur during the measured time period. * * An external counter, Timer_interrupts, is incremented. - * + */ + +/* * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia * Author: Victor V. Vengerov * @@ -29,7 +32,7 @@ */ #include -#include "bsp.h" +#include #include "mcf5206/mcf5206e.h" BEGIN_CODE diff --git a/c/src/lib/libcpu/m68k/mcf5272/timer/timer.c b/c/src/lib/libcpu/m68k/mcf5272/timer/timer.c index 0788456f84..812310fbea 100644 --- a/c/src/lib/libcpu/m68k/mcf5272/timer/timer.c +++ b/c/src/lib/libcpu/m68k/mcf5272/timer/timer.c @@ -1,8 +1,10 @@ -/* - * Timer Init +/** + * @file * * This module initializes TIMER 2 for on the MCF5272 for benchmarks. - * + */ + +/* * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia * Author: Victor V. Vengerov * @@ -22,6 +24,7 @@ #include #include #include +#include #define TRR2_VAL 65530 @@ -102,7 +105,7 @@ benchmark_timer_initialize(void) * RETURNS: * number of microseconds since timer has been started */ -int +benchmark_timer_t benchmark_timer_read( void ) { uint16_t clicks; diff --git a/c/src/lib/libcpu/m68k/mcf5272/timer/timerisr.S b/c/src/lib/libcpu/m68k/mcf5272/timer/timerisr.S index 2e36c34262..b9c28921c4 100644 --- a/c/src/lib/libcpu/m68k/mcf5272/timer/timerisr.S +++ b/c/src/lib/libcpu/m68k/mcf5272/timer/timerisr.S @@ -1,5 +1,6 @@ -/* - * Handle MCF5272 TIMER2 interrupts. +/** + * @file + * @brief Handle MCF5272 TIMER2 interrupts. * * All code in this routine is pure overhead which can perturb the * accuracy of RTEMS' timing test suite. @@ -11,7 +12,9 @@ * occur during the measured time period. * * An external counter, Timer_interrupts, is incremented. - * + */ + +/* * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia * Author: Victor V. Vengerov * @@ -30,9 +33,6 @@ #include #include -/* -#include "mcf5272/mcf5272.h" -*/ BEGIN_CODE PUBLIC(timerisr) -- cgit v1.2.3