From e36fa6f27fe2d6abf188913f058a4f95d287a308 Mon Sep 17 00:00:00 2001 From: bernie Date: Tue, 10 Aug 2004 06:59:09 +0000 Subject: [PATCH] timer_gettick(): Rename to timer_ticks() and add backwards compatibility inline. git-svn-id: https://src.develer.com/svnoss/bertos/trunk@127 38d2e660-2303-0410-9eaa-f027e97ec537 --- drv/timer.c | 7 +++++-- drv/timer.h | 19 ++++++++++--------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/drv/timer.c b/drv/timer.c index dc350057..b2caf90d 100755 --- a/drv/timer.c +++ b/drv/timer.c @@ -15,6 +15,9 @@ /* * $Log$ + * Revision 1.13 2004/08/10 06:59:09 bernie + * timer_gettick(): Rename to timer_ticks() and add backwards compatibility inline. + * * Revision 1.12 2004/08/08 05:59:37 bernie * Remove a few useless casts. * @@ -141,10 +144,10 @@ void timer_delay(time_t time) #else /* !CONFIG_KERN_SIGNALS */ - time_t start = timer_gettick(); + time_t start = timer_ticks(); /* Busy wait */ - while (timer_gettick() - start < time) { /* nop */ } + while (timer_ticks() - start < time) { /* nop */ } #endif /* !CONFIG_KERN_SIGNALS */ } diff --git a/drv/timer.h b/drv/timer.h index 09d97c13..d88168f0 100755 --- a/drv/timer.h +++ b/drv/timer.h @@ -15,11 +15,8 @@ /* * $Log$ - * Revision 1.14 2004/08/03 15:50:03 aleph - * Rename timer_tick() to timer_ticks() - * - * Revision 1.13 2004/08/02 20:20:29 aleph - * Merge from project_ks + * Revision 1.15 2004/08/10 06:59:09 bernie + * timer_gettick(): Rename to timer_ticks() and add backwards compatibility inline. * * Revision 1.12 2004/07/30 14:34:10 rasky * Vari fix per documentazione e commenti @@ -167,8 +164,10 @@ INLINE time_t timer_ticks(void) return result; } -/* OBSOLETE */ -#define timer_gettick timer_ticks +DEPRECATED INLINE time_t timer_gettick(void) +{ + return timer_ticks(); +} /*! @@ -183,8 +182,10 @@ INLINE time_t timer_ticks_unlocked(void) return _clock; } -/* OBSOLETE */ -#define timer_gettick_irq timer_ticks_unlocked +DEPRECATED INLINE time_t timer_gettick_irq(void) +{ + return timer_ticks_unlocked(); +} /*! -- 2.25.1