Commit Graph

10 Commits

Author SHA1 Message Date
hannken 0b2854eb6c Fix for lint during build of libc. 2000-05-05 20:12:00 +00:00
thorpej 855b79db92 Let each platform typedef the new __cpu_simple_lock_t, which should
be the most efficient type used for the atomic operations in the
simplelock structure, and should also be __volatile.
2000-05-02 04:41:04 +00:00
pk e327115496 FIx declaration in __ldstub. 2000-04-30 22:15:30 +00:00
thorpej f51470a514 Require that each each MACHINE/MACHINE_ARCH supply a lock.h. This file
contains the values __SIMPLELOCK_LOCKED and __SIMPLELOCK_UNLOCKED, which
replace the old SIMPLELOCK_LOCKED and SIMPLELOCK_UNLOCKED.  These files
are also required to supply inline functions __cpu_simple_lock(),
__cpu_simple_lock_try(), and __cpu_simple_unlock() if locking is to be
supported on that platform (i.e. if MULTIPROCESSOR is defined in the
_KERNEL case).  Change these functions to take an int * (&alp->lock_data)
rather than the struct simplelock * itself.

These changes make it possible for userland to use the locking primitives
by including <machine/lock.h>.
2000-04-29 03:31:45 +00:00
thorpej 6ec1ededf1 Make a slight rearrangement in how <machine/lock.h> is included. 1999-07-27 23:45:13 +00:00
thorpej cc668e410f Define apporpriate an value for SIMPLELOCK_LOCKED, based on the
semantics of ldstub.
1999-07-27 22:22:33 +00:00
thorpej c1ee8f0a8c Prepend `cpu_' to the machine-dependent atomic locking primitivies. 1999-07-27 21:45:39 +00:00
chs 61458d7dfa LOCKDEBUG enhancements for non-MP:
keep a list of locked locks.
use this to print where the lock was locked
when we either go to sleep with a lock held
or try to free a locked lock.
1998-11-04 06:19:55 +00:00
pk 40beab6ad6 If a lock is held do not spin in a read/write loop but just read the lock
until it is released. This is easier on the bus cache coherency logic.
1998-10-05 19:58:19 +00:00
pk e6ce8bcfc7 sparc spin lock functions. 1998-09-27 14:31:18 +00:00