diff --git a/src/sys/kernel/spinlock.c b/src/sys/kernel/spinlock.c index 339b544..3328f8d 100644 --- a/src/sys/kernel/spinlock.c +++ b/src/sys/kernel/spinlock.c @@ -28,6 +28,7 @@ *****************************************************************************************/ #include +#include void spinLockInit(spinLock_t *lock) { *lock = SPIN_LOCK_INITIALIZER; @@ -54,7 +55,8 @@ void spinLock(spinLock_t *lock) { while (!spinTryLock(lock)) - while (*lock == 1); + while (*lock == 1) + schedYield(); } int spinLockLocked(spinLock_t *lock) { @@ -64,6 +66,9 @@ /*** $Log$ + Revision 1.11 2004/07/21 17:11:18 reddawg + A Quick tweak I'm going to clean up some unused variables in sched.h + Revision 1.10 2004/07/20 21:17:05 reddawg CFLAGS: I updated cflags so optimizations are consistant on all files different optimization levels maybe the source of some of our problems?