Mercurial > ecos-v2_0-branch
comparison packages/kernel/current/include/sched.inl @ 115:6ed91473a1cd ecos-sw-2000-08-21
Merge from eCos master repository on 2000-08-21-22:40:54-BST
| author | jlarmour |
|---|---|
| date | Fri, 25 Aug 2000 17:32:38 +0000 |
| parents | bf00f99aec69 |
| children | 0ec04793409a |
comparison
equal
deleted
inserted
replaced
| 114:5ad2b71d525e | 115:6ed91473a1cd |
|---|---|
| 87 | 87 |
| 88 HAL_REORDER_BARRIER(); | 88 HAL_REORDER_BARRIER(); |
| 89 | 89 |
| 90 cyg_ucount32 __lock = sched_lock - 1; | 90 cyg_ucount32 __lock = sched_lock - 1; |
| 91 | 91 |
| 92 if( __lock == 0 ) unlock_inner(); | 92 if( __lock == 0 ) unlock_inner(0); |
| 93 else sched_lock = __lock; | 93 else sched_lock = __lock; |
| 94 | 94 |
| 95 HAL_REORDER_BARRIER(); | 95 HAL_REORDER_BARRIER(); |
| 96 } | |
| 97 | |
| 98 inline void Cyg_Scheduler::reschedule() | |
| 99 { | |
| 100 // This function performs the equivalent of calling unlock() and | |
| 101 // lock() is succession. Unlike that pair, however, it does not | |
| 102 // leave a brief window between the calls when the lock is unclaimed | |
| 103 // by the current thread. | |
| 104 | |
| 105 CYG_INSTRUMENT_SCHED(RESCHEDULE,sched_lock,0); | |
| 106 | |
| 107 unlock_inner( sched_lock ); | |
| 96 } | 108 } |
| 97 | 109 |
| 98 inline void Cyg_Scheduler::unlock_simple() | 110 inline void Cyg_Scheduler::unlock_simple() |
| 99 { | 111 { |
| 100 // This function decrements the lock, but does not call unlock_inner(). | 112 // This function decrements the lock, but does not call unlock_inner(). |
