From cc85ca11fbb0b302266e09c3a85d2782ead85986 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Fri, 23 Nov 2007 14:16:12 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@108 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- src/chschd.c | 4 +--- src/include/scheduler.h | 24 +++++------------------- 2 files changed, 6 insertions(+), 22 deletions(-) (limited to 'src') diff --git a/src/chschd.c b/src/chschd.c index 65a1fd360..c93b6aab7 100644 --- a/src/chschd.c +++ b/src/chschd.c @@ -183,9 +183,7 @@ BOOL chSchRescRequiredI(void) { */ void chSchTimerHandlerI(void) { - if (rlist.r_preempt) - rlist.r_preempt--; - + rlist.r_preempt--; #ifdef CH_USE_SYSTEMTIME rlist.r_stime++; #endif diff --git a/src/include/scheduler.h b/src/include/scheduler.h index bb70a83af..4aed76e28 100644 --- a/src/include/scheduler.h +++ b/src/include/scheduler.h @@ -38,14 +38,14 @@ * Ready list header. */ typedef struct { - ThreadsQueue r_queue; - t_prio r_prio; - t_cnt r_preempt; + ThreadsQueue r_queue; + t_prio r_prio; + t_cnt r_preempt; #ifndef CH_CURRP_REGISTER_CACHE - Thread *r_current; + Thread *r_current; #endif #ifdef CH_USE_SYSTEMTIME - volatile t_time r_stime; + volatile t_time r_stime; #endif } ReadyList; @@ -69,26 +69,12 @@ extern "C" { } #endif -/** - * Current thread pointer. - * @note Dont use this directly but use the \p chThdSelf() - * instead. Direct use of system global variables is discouraged because - * portability reasons. - */ #ifdef CH_CURRP_REGISTER_CACHE register Thread *currp asm(CH_CURRP_REGISTER_CACHE); #else #define currp rlist.r_current #endif -/** - * System ticks counter. - * @note Dont use this directly but use the \p chSysGetTime() - * instead. Direct use of system global variables is discouraged because - * portability reasons. - */ -extern volatile t_time stime; - #endif /* _SCHEDULER_H_ */ /** @} */ -- cgit v1.2.3