Changeset dff0a94 in mainline for kernel/test/synch/semaphore2.c
- Timestamp:
- 2006-12-11T19:41:04Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 00bb6965
- Parents:
- e54fb21
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/test/synch/semaphore2.c
re54fb21 rdff0a94 42 42 static semaphore_t sem; 43 43 44 static SPINLOCK_INITIALIZE(lock);44 SPINLOCK_INITIALIZE(sem_lock); 45 45 46 46 static waitq_t can_start; … … 57 57 uint32_t rc; 58 58 59 spinlock_lock(& lock);59 spinlock_lock(&sem_lock); 60 60 rc = seed % max; 61 61 seed = (((seed<<2) ^ (seed>>2)) * 487) + rc; 62 spinlock_unlock(& lock);62 spinlock_unlock(&sem_lock); 63 63 return rc; 64 64 }
Note:
See TracChangeset
for help on using the changeset viewer.