freebsd-nq/sys
Bruce Evans 4df0520624 clock.c:
Quick fix for calling DELAY() for ddb input in some (atkbd-based)
console drivers.  ddb must not use any normal locks, but DELAY()
normally calls getit() which needs clock_lock.  One problem with using
normal locks in ddb is that deadlock is possible, but deadlock on
clock_lock is unlikely becaluse clock_lock is bogusly recursive,
apparently just to hide the problem of ddb using it.  The i8254 clock
hardware has mostly write-only registers so it is important for it to
use a lock that gives exclusive access.  (atkbd hardware is also
unfriendly to reentrant software but that problem is more local and
already solved.)  I mostly saw the symptoms of the bug caused by
unlocking in getit() running cpu_unpend().  cpu_unpend() should not
be called while in ddb and Debugger() calls for failing assertions
about this caused a breakpoint within ddb.

ddb must also not call getit() because ddb may be being used to step
through clock initialization code that has stopped or otherwise mangled
the clock.  If the clock is stopped, then getit() always returns the
same value and DELAY() takes forever if it trusts getit().

The quick fix is implement DELAY(n) as (n * timer_freq / 1000000)
inb(0x84)'s if ddb is active.

machdep.c:
Don't permit recursion on clock_lock.
2003-09-07 14:23:08 +00:00
..
alpha Fix build breakage caused by the inclusion of <ddb/ddb.h> while 2003-09-07 05:33:46 +00:00
amd64 Oops. sizeof(long) = 8, not 4. Get the fxsave buffer inside mcontext 2003-09-05 20:47:27 +00:00
arm
boot Add BOOT_PXELDR_ALWAYS_SERIAL option which forces serial console. 2003-09-03 08:12:20 +00:00
cam Put the device cloning functions for disk-drivers under #ifndef BURN_BRIDGES. 2003-09-05 10:40:16 +00:00
coda Add support for the Coda 6.x venus<->kernel interface. This extends 2003-09-07 07:43:10 +00:00
compat Restored a non-egregious cast so that this file compiles on i386's 2003-09-07 13:03:13 +00:00
conf Add support for the Coda 6.x venus<->kernel interface. This extends 2003-09-07 07:43:10 +00:00
contrib
crypto
ddb Label the uarea address as such in DDB's ps output 2003-08-30 19:06:57 +00:00
dev Better stab at MD code for pc98. The 8251 stuff is a total lie 2003-09-07 04:59:15 +00:00
fs Add support for the Coda 6.x venus<->kernel interface. This extends 2003-09-07 07:43:10 +00:00
geom Bzero the right number of bytes. 2003-09-06 18:37:17 +00:00
gnu - Clean-up comments that refer to the use of B_LOCKED. 2003-08-28 00:56:39 +00:00
i4b Use PCIR_BAR(x) instead of PCIR_MAPS. 2003-09-02 17:30:40 +00:00
i386 clock.c: 2003-09-07 14:23:08 +00:00
ia64 MFp4: Revamped GENERIC (and hints). This is some much more pleasant 2003-09-07 06:39:51 +00:00
isa clock.c: 2003-09-07 14:23:08 +00:00
isofs/cd9660
kern Return EINVAL if the contested bit is not set on the umtx passed to 2003-09-07 11:14:52 +00:00
libkern
modules Add support for the Coda 6.x venus<->kernel interface. This extends 2003-09-07 07:43:10 +00:00
net Add locking. We use a single lock to guard the global vlan list and also 2003-09-05 20:58:59 +00:00
net80211 Experimental bpf capture format for 802.11 devices. The link layer 2003-09-05 22:19:32 +00:00
netatalk More checking of M_PREPEND() return values: pass through link-layer 2003-08-29 19:27:09 +00:00
netatm
netgraph
netinet Add locking. 2003-09-06 04:53:43 +00:00
netinet6
netipsec Locking and misc cleanups; most of which I've been running for >4 months: 2003-09-01 05:35:55 +00:00
netipx
netkey
netnatm
netncp
netsmb
nfs
nfsclient Remove now unused BOOTP tags related to NFS swap device. 2003-09-05 11:12:55 +00:00
nfsserver
opencrypto
pc98 Merged from sys/dev/sio/sio.c revisions 1.403 and 1.404. 2003-08-28 11:20:54 +00:00
pccard More debug under boot verbose. 2003-08-29 23:25:00 +00:00
pci Make indentation uniform. 2003-09-06 14:04:30 +00:00
posix4
powerpc Standardize idempotentcy ifdefs. Consistently use _MACHINE_VARARGS_H_ 2003-09-01 03:01:45 +00:00
rpc
security Remove extra tabs indenting MAC library calls; they were there to 2003-08-29 02:43:57 +00:00
sparc64 - Clear the CE AFSR bits which indicate the error condition when handling 2003-09-04 15:25:10 +00:00
sys msync(2) should be declared MP-safe. 2003-09-07 05:42:07 +00:00
tools
ufs - Several of the callers to getdirtybuf() were erroneously changed to pass 2003-09-03 04:08:15 +00:00
vm Don't open with exclusive bit, swapon(8) wants to trash our swapdev. 2003-09-02 05:53:44 +00:00
Makefile