freebsd-dev/sys/sys
John Baldwin 91a4536f22 - Fix a bug in the previous workaround for the tsleep/endtsleep race.
callout_stop() would fail in two cases:
    1) The timeout was currently executing, and
    2) The timeout had already executed.
  We only needed to work around the race for 1).  We caught some instances
  of 2) via the PS_TIMEOUT flag, however, if endtsleep() fired after the
  process had been woken up but before it had resumed execution,
  PS_TIMEOUT would not be set, but callout_stop() would fail, so we
  would block the process until endtsleep() resumed it.  Except that
  endtsleep() had already run and couldn't resume it.  This adds a new flag
  PS_TIMOFAIL to indicate the case of 2) when PS_TIMEOUT isn't set.
- Implement this race fix for condition variables as well.

Tested by:	sos
2001-08-21 18:42:45 +00:00
..
_lock.h - Move state about lock objects out of struct lock_object and into a new 2001-05-04 17:15:16 +00:00
_mutex.h Undo part of the tangle of having sys/lock.h and sys/mutex.h included in 2001-05-01 08:13:21 +00:00
_posix.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
_sigset.h Check validity of signal callback requested via aio routines. 2001-04-18 22:18:39 +00:00
_timespec.h Synchronize with some of my local changes. To quote: 2001-01-23 04:40:54 +00:00
aac_ioctl.h Make AAC_COMPAT_LINUX optional once again. 2001-08-06 19:40:47 +00:00
acct.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
acl.h o Separate acl_t into internal and external representations as 2001-04-24 22:45:41 +00:00
agpio.h A driver for programming the AGP hardware. This is only very lightly 2000-06-09 16:04:30 +00:00
aio.h When aio_read/write() is used on a raw device, physical buffers are 2001-03-10 22:47:57 +00:00
assym.h Use "nm | awk ..." instead of genassym(1) to generate symbol value headers. 2000-06-02 09:27:48 +00:00
ata.h Change the ioctl interface to prepare for new functionality. 2001-05-17 10:28:59 +00:00
bio.h Define BIO_CMD{1,2}, available for local hacks, similar to the already 2001-06-29 15:21:28 +00:00
bitstring.h Cleanup of bitstring.h: 2000-10-09 12:34:51 +00:00
blist.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
buf.h Limit the amount of KVM reserved for the buffer cache and for swap-meta 2001-08-20 00:41:12 +00:00
bus_dma.h Fix "alignemnt" typo. 2001-06-16 15:28:28 +00:00
bus_private.h Hints overhaul: 2001-06-12 09:40:04 +00:00
bus.h Add INTR_TYPE_AV so that we can get to the PI_AV priority in the ithread 2001-06-16 22:42:19 +00:00
callout.h Whitespace style nits. 2001-08-21 15:37:19 +00:00
capability.h o Change the API and ABI of the Extended Attribute kernel interfaces to 2001-03-15 02:54:29 +00:00
ccdvar.h Cleanup some remaining bdev fluff. 2000-01-16 09:25:10 +00:00
cdefs.h Support GCC 3.0 2001-06-02 17:35:50 +00:00
cdio.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
cdrio.h Add session argument to *CLOSEDISK, allowing to set session type on fixate. 2001-01-10 19:17:38 +00:00
chio.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
clist.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
condvar.h Add missing () around macro argument in cv_waitq_empty() 2001-07-17 08:25:24 +00:00
conf.h Make the fmt arguments to make_dev and make_dev_alias const char *. 2001-08-02 20:35:35 +00:00
cons.h With this commit, I hereby pronounce gensetdefs past its use-by date. 2001-06-13 10:58:39 +00:00
consio.h Refine cursor type/shape control escape sequences and 2001-08-02 08:30:40 +00:00
copyright.h We are now in the year 2001, so ajust copyrights. 2001-01-01 08:05:48 +00:00
ctype.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
dataacq.h Add $FreeBSD$ 2000-05-01 20:32:07 +00:00
device_port.h Add PC-Card/ISA SCSI host adpater drivers from NetBSD/pc98 2000-10-23 12:55:51 +00:00
devicestat.h Export the head structure for the device statistics STAILQ in 2001-08-04 18:02:47 +00:00
digiio.h Add DIGIIO_SETALTPIN and DIGIIO_GETALTPIN ioctl values 2001-06-20 14:51:58 +00:00
dir.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
dirent.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
disk.h Add disk_enumerate() for finding names of disks. Vinum and libh will 2000-06-15 20:30:53 +00:00
disklabel.h Use ANSI prototype and function definition for dkcksum so that this 2001-01-14 05:14:37 +00:00
diskmbr.h Use ANSI prototype and function definition for dkcksum so that this 2001-01-14 05:14:37 +00:00
diskpc98.h Use ANSI prototype and function definition for dkcksum so that this 2001-01-14 05:14:37 +00:00
diskslice.h Write support for the cd(4) driver. 2000-10-30 07:03:00 +00:00
dkstat.h Redeclare cp_time. It's no longer static, and linprocfs needs it. 2000-09-07 16:38:04 +00:00
dmap.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
domain.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
dvdio.h Add support for the DVD ioctl interface. 2000-05-12 03:36:02 +00:00
elf32.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
elf64.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
elf_common.h Add "ELFOSABI_NONE" which is the symbol used in a copy of the old ELF spec, 2001-02-24 22:23:12 +00:00
elf_generic.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
errno.h Add ENOTSUP, which is specified as an error return value for various 2000-05-02 06:02:11 +00:00
event.h Introduce EVFILT_TIMER, which allows a process to establish an 2001-07-19 18:34:40 +00:00
eventhandler.h Undo part of the tangle of having sys/lock.h and sys/mutex.h included in 2001-05-01 08:13:21 +00:00
eventvar.h Simplify kqueue API slightly. 2000-07-18 19:31:52 +00:00
exec.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
extattr.h o Introduce extattr_{delete,get,set}_fd() to allow extended attribute 2001-03-31 16:20:05 +00:00
fbio.h Add some definitions. Their actual support will be added 2001-08-02 11:17:38 +00:00
fcntl.h This patch implements O_DIRECT about 80% of the way. It takes a patchset 2001-05-24 07:22:27 +00:00
fdcio.h Implement a new ioctl command for floppies: FD_READID 2001-06-26 22:16:30 +00:00
file.h This patch implements O_DIRECT about 80% of the way. It takes a patchset 2001-05-24 07:22:27 +00:00
filedesc.h o Merge contents of struct pcred into struct ucred. Specifically, add the 2001-05-25 16:59:11 +00:00
filio.h Commit the kernel part of our DVD support. Nothing much to say really, 1999-12-07 22:25:28 +00:00
fnv_hash.h Use the same API as the example code. 2001-03-20 02:10:18 +00:00
gmon.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
iconv.h Add function prototypes and base module for kernel side iconv library. 2001-04-09 09:39:29 +00:00
imgact_aout.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
imgact_elf.h MFS: bring the consistent `compat_3_brand' support into -CURRENT 2001-02-24 22:20:11 +00:00
imgact.h Make size of dynamic loader argument variable to support 2000-09-26 05:09:21 +00:00
inflate.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
interrupt.h Clean up the code exporting interrupt statistics via sysctl a bit: 2001-06-01 13:23:28 +00:00
inttypes.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
ioccom.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
ioctl_bt848.h Fix typo in comments 2000-10-31 14:30:29 +00:00
ioctl_compat.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
ioctl_meteor.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
ioctl.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
ipc.h sysvipc loadable. 2000-12-01 08:57:47 +00:00
jail.h o Move per-process jail pointer (p->pr_prison) to inside of the subject 2001-02-21 06:39:57 +00:00
joystick.h Switch over to using the generic joy driver 1999-12-05 20:02:19 +00:00
kbio.h Implement keyboard paste 2001-03-11 22:51:05 +00:00
kernel.h Make hostid an unsigned long (matches kern_mib.c change) 2001-06-22 19:51:45 +00:00
kobj.h Fix typos: initalise -> initialise. 2001-02-08 20:28:57 +00:00
kthread.h Include <sys/cdefs.h> so that this file is self-sufficient. 2001-02-15 11:35:55 +00:00
ktr.h - Replace the unused KTR_IDLELOOP trace class with a new KTR_WITNESS trace 2001-06-25 23:09:31 +00:00
ktrace.h Limit size of passed in data for utrace function. 2001-01-06 09:34:20 +00:00
libkern.h Rewrite of the CAM error recovery code. 2001-03-27 05:45:52 +00:00
linedisc.h Make the fmt arguments to make_dev and make_dev_alias const char *. 2001-08-02 20:35:35 +00:00
link_aout.h Update the prototype for "r_brk" to correspond with the change in 2000-09-18 20:40:32 +00:00
link_elf.h Update the prototype for "r_brk" to correspond with the change in 2000-09-18 20:40:32 +00:00
linker_set.h With this commit, I hereby pronounce gensetdefs past its use-by date. 2001-06-13 10:58:39 +00:00
linker.h Add linker_reference_module(). 2001-06-18 15:09:33 +00:00
lock.h - Add a new witness_assert() to perform arbitrary locking assertions. 2001-06-27 06:27:29 +00:00
lockf.h Wrap around MALLOC_DECLARE() invocation with #ifdef. 2001-05-03 08:57:26 +00:00
lockmgr.h Undo part of the tangle of having sys/lock.h and sys/mutex.h included in 2001-05-01 08:13:21 +00:00
malloc.h - Remove asleep(), await(), and M_ASLEEP. 2001-08-10 06:37:05 +00:00
mbuf.h Constify m_copydata. 2001-08-19 04:35:28 +00:00
mchain.h Introduce API for sequential reads/writes (build/dissect) of mbuf chains. 2001-02-24 15:44:30 +00:00
md4.h Import kernel part of SMB/CIFS requester. 2001-04-10 07:59:06 +00:00
md5.h Add a new entrypoint to the hashes in libmd: 2001-03-17 10:00:50 +00:00
mdioctl.h Introduce a force option, MD_FORCE, that instructs the driver to 2001-08-07 19:23:16 +00:00
memrange.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
mman.h Add MAP_NOCORE to mmap(2), and MADV_NOCORE and MADV_CORE to madvise(2). 2000-02-28 04:10:35 +00:00
module.h Constify the module name. This silences a few warnings ("initialization 2001-06-19 21:40:14 +00:00
mount.h Machine dependent ifdefs for sparc64. 2001-07-31 04:14:30 +00:00
mouse.h Spelling police: extention -> extension in a comment. 2001-07-05 08:52:40 +00:00
msg.h Move the MSG* and SEM* options to opt_sysvipc.h 2000-05-01 13:33:56 +00:00
msgbuf.h Replace logwakeup() with "int msgbuftrigger". There is little 2000-12-20 21:50:37 +00:00
mtio.h Make residuals signed. 2001-01-21 01:34:14 +00:00
mutex.h Reorg vm_page.c into vm_page.c, vm_pageq.c, and vm_contig.c (for contigmalloc). 2001-07-04 23:27:09 +00:00
namei.h Add new flag PDIRUNLOCK to the component.cn_flags which should be set by 2000-09-17 07:26:42 +00:00
nlist_aout.h $Id$ -> $FreeBSD$ 1999-08-27 23:45:13 +00:00
param.h Bump MAXCOMLEN from 16 to 19 to take advantage of 32-bit alignment. 2001-08-10 05:34:48 +00:00
pciio.h [ repository copy of sys/pci/pci_ioctl.h to sys/sys/pciio.h happened in the 1999-12-08 17:44:04 +00:00
pcpu.h - Split out the support for per-CPU data from the SMP code. UP kernels 2001-05-10 17:45:49 +00:00
pioctl.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
pipe.h select() DKI is now in <sys/selinfo.h>. 2001-01-09 04:33:49 +00:00
poll.h Fix typo: compatability -> compatibility. 2001-02-06 12:05:58 +00:00
posix4.h Fixed some type mismatches. p_retval[0] in struct proc has type 1999-12-27 10:22:09 +00:00
priority.h Implement a unified run queue and adjust priority levels accordingly. 2001-02-12 00:20:08 +00:00
proc.h - Fix a bug in the previous workaround for the tsleep/endtsleep race. 2001-08-21 18:42:45 +00:00
procfs.h Use explicit sizes for the prpsinfo command length string so that 2001-08-16 08:35:51 +00:00
protosw.h Make the protoswitch definitiosn checkable in the same way that 2001-08-10 23:17:22 +00:00
ptio.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
ptrace.h GC unused prototype of ptrace_write_u(). 2001-08-21 13:41:46 +00:00
queue.h CIRCLEQs are a disgrace to everything Knuth taught us in Volume 1 Chapter 2. 2000-12-29 09:55:40 +00:00
random.h Provide the infrastructure for sysadmins to select the broad class 2001-02-18 17:40:47 +00:00
reboot.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
regression.h o Include file to provide prototypes for regression testing-specific 2001-05-26 15:37:25 +00:00
resource.h add prototype for dosetrlimit 2001-07-22 00:21:19 +00:00
resourcevar.h - Close races with signals and other AST's being triggered while we are in 2001-08-10 22:53:32 +00:00
rman.h Convert all simplelocks to mutexes and remove the simplelock implementations. 2001-01-24 12:35:55 +00:00
rtprio.h Implement a unified run queue and adjust priority levels accordingly. 2001-02-12 00:20:08 +00:00
runq.h Implement a unified run queue and adjust priority levels accordingly. 2001-02-12 00:20:08 +00:00
sbuf.h Add printf format checking to sbuf_printf() 2001-07-18 15:58:06 +00:00
select.h Do not recursively include <sys/selinfo.h> from <sys/select.h>; all in-tree 2001-01-20 03:11:47 +00:00
selinfo.h Move `struct selinfo' and related functions to <sys/selinfo.h>. 2001-01-04 03:29:16 +00:00
sem.h Move the MSG* and SEM* options to opt_sysvipc.h 2000-05-01 13:33:56 +00:00
sema.h Implement kernel semaphores. 2001-08-14 22:13:14 +00:00
semaphore.h Track libc_r addition of semaphores implementation. 2000-01-20 07:55:42 +00:00
shm.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
signal.h Check validity of signal callback requested via aio routines. 2001-04-18 22:18:39 +00:00
signalvar.h *** empty log message *** 2001-08-09 01:21:58 +00:00
smp.h Move CPU_ABSENT() macro to smp.h, where it belongs anyway. It will be 2001-08-01 00:54:00 +00:00
snoop.h Move the kernel stuff out of snoop.h. It was only there because some 2001-07-25 14:47:56 +00:00
socket.h FreeBSD already avoided namespace pollution (rev.1.45). 2001-06-12 11:12:23 +00:00
socketvar.h Correct comment: so_q -> so_comp, so_q0 -> so_incomp. 2001-06-28 04:39:49 +00:00
sockio.h Add kernel infrastructure for network device cloning. 2001-07-02 20:49:25 +00:00
soundcard.h Correct the URL to the Hacker's Guide to Voxware. 2001-08-21 07:39:47 +00:00
stat.h Get userland visible flags added for snapshots to give a few days 2000-07-04 04:58:34 +00:00
sx.h Add sx_try_upgrade() and sx_downgrade(). 2001-08-13 21:25:30 +00:00
syscall-hide.h Regen syscalls that were made mpsafe via vm_mtx 2001-05-19 01:37:12 +00:00
syscall.h Regen syscalls that were made mpsafe via vm_mtx 2001-05-19 01:37:12 +00:00
syscall.mk Regen syscalls that were made mpsafe via vm_mtx 2001-05-19 01:37:12 +00:00
sysctl.h Make dynamic sysctl entries start at 0x100, not decimal 100 - there are 2001-07-25 17:21:18 +00:00
sysent.h sysvipc loadable. 2000-12-01 08:57:47 +00:00
syslimits.h After one too many PRs on the subject, bite the bullet and define IOV_MAX 2001-06-18 20:24:54 +00:00
syslog.h syslog.h fails to compile with -Wwrite-strings 2001-05-21 17:32:47 +00:00
sysproto.h Regen syscalls that were made mpsafe via vm_mtx 2001-05-19 01:37:12 +00:00
systm.h - Remove asleep(), await(), and M_ASLEEP. 2001-08-10 06:37:05 +00:00
taskqueue.h taskqueue_swi is a pointer, not a struct. Fix a comment that misleadingly 2000-06-09 22:32:36 +00:00
termios.h Add B921600 (yes, some serial ports can do this, but generic sio not support 2001-06-20 03:26:41 +00:00
time.h Polish getnano{up}*time() prototypes. 2001-05-23 20:33:54 +00:00
timeb.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
timepps.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
timers.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
times.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
timespec.h This file declares `struct timespec' so that we can have a single, 2001-01-23 04:44:04 +00:00
timetc.h Isolate the Timecounter internals in their own two files. 2000-03-20 14:09:06 +00:00
timex.h Update to the 2001-04-02 version of the nanokernel code from Dave Mills. 2001-04-16 13:05:05 +00:00
tty.h Fixed unsorting of prototypes in previous commit. Is it too much to 2001-02-17 05:40:52 +00:00
ttychars.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
ttycom.h Remove the TABLDISC line discipline number, it's not in the tree 2000-01-29 16:47:35 +00:00
ttydefaults.h Kernel support for erase2 character. 2000-11-28 20:03:23 +00:00
ttydev.h Add B921600 (yes, some serial ports can do this, but generic sio not support 2001-06-20 03:26:41 +00:00
types.h Use a fixed type for times in on-disk structures for ufs rather than 2001-07-16 00:55:27 +00:00
ucontext.h Add a per-signal flag to mark handlers registered with osigaction, so we 1999-10-11 20:33:17 +00:00
ucred.h o Merge contents of struct pcred into struct ucred. Specifically, add the 2001-05-25 16:59:11 +00:00
uio.h After one too many PRs on the subject, bite the bullet and define IOV_MAX 2001-06-18 20:24:54 +00:00
un.h Implement a LOCAL_PEERCRED socket option which returns a 2001-08-17 22:01:18 +00:00
unistd.h After one too many PRs on the subject, bite the bullet and define IOV_MAX 2001-06-18 20:24:54 +00:00
unpcb.h Implement a LOCAL_PEERCRED socket option which returns a 2001-08-17 22:01:18 +00:00
user.h Use the backwards compatability mechanisms so that ps/top etc dont have 2001-08-16 08:41:15 +00:00
utsname.h Round 1 of Brucification inspired changes. 2001-03-24 08:37:56 +00:00
vmmeter.h Add mibs to hold the number of forks since boot. New mibs are: 2001-01-23 14:32:01 +00:00
vnioctl.h Fix a bug in the block number calculation for VN disks with a sector 1999-09-17 05:34:00 +00:00
vnode.h Remove MFS 2001-05-29 20:39:47 +00:00
wait.h Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL" 1999-12-29 04:46:21 +00:00
xrpuio.h $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00