NetBSD/sys/sys
jonathan 230fb9b8ab Eliminate several uses of `curproc' from the socket-layer code and from NFS.
Add a new explicit `struct proc *p' argument to socreate(), sosend().
Use that argument instead of curproc. Follow-on changes to pass that
argument to socreate(), sosend(), and (*so->so_send)() calls.
These changes reviewed and independently recoded  by Matt Thomas.

Changes to soreceive() and (*dom->dom_exernalize() from Matt Thomas:
pass soreceive()'s struct uio* uio->uio_procp to unp_externalize().
Eliminate curproc from unp_externalize.   Also, now soreceive() uses
its uio->uio_procp value, pass that same value downward to
((pr->pru_usrreq)() calls for consistency, instead of (struct proc * )0.

Similar changes in sys/nfs to eliminate (most) uses of curproc,
either via the req-> r_procp field of a struct nfsreq *req argument,
or by passing down new explicit struct proc * arguments.

Reviewed by: Matt Thomas, posted to tech-kern.
NB: The (*pr->pru_usrreq)() change should be tested on more (all!) protocols.
2004-05-22 22:52:13 +00:00
..
Makefile Replace the statfs() family of system calls with statvfs(). 2004-04-21 01:05:31 +00:00
acct.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
agpio.h From FreeBSD: Fix an off-by-bit error in the AGP_MODE_[GS]ET_RATE() macros. 2003-02-24 21:59:52 +00:00
ansi.h Replace the statfs() family of system calls with statvfs(). 2004-04-21 01:05:31 +00:00
ataio.h "definitions" has lots of 'i's, but that's not reason to leave one out. 2002-09-29 23:23:56 +00:00
audioio.h Add AudioNvideo, AudioNcenter, AudioNdepth, and AudioNlfe 2002-10-12 07:39:00 +00:00
boot_flag.h Add two new boot flags: 2003-11-03 16:39:07 +00:00
bootblock.h Add offset of old i386 mbr bootsel structure. 2004-04-26 21:00:38 +00:00
bswap.h
buf.h change the way to handle NEW_BUFQ_STRATEGY option. 2004-02-28 06:28:47 +00:00
callout.h Make callout_setfunc() a CPP macro. Suggested by enami. 2003-10-30 04:32:56 +00:00
cdefs.h Add a __insn_barrier() macro to stop the optimizer from moving code 2004-01-07 19:38:10 +00:00
cdefs_aout.h Add a.out weak-symbol support (new in binutils 2.14). 2003-12-07 12:58:56 +00:00
cdefs_elf.h Define link_sets start/stop as ptype * const [] since they are in a 2004-05-01 07:16:55 +00:00
cdio.h make it clear that ENTRIES = ENTRYS :-) 2004-05-10 15:14:12 +00:00
chio.h
clockctl.h - Protect clockctl.h consistently with the correct ifdef. 2003-09-30 20:38:38 +00:00
conf.h Make VOP_STRATEGY(bp) a real VOP as discussed on tech-kern. 2004-01-25 18:06:48 +00:00
core.h
device.h Add EVCNT_ATTACH_STATIC2 to allow adding of array members 2004-04-30 23:00:03 +00:00
dir.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
dirent.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
disk.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
disklabel.h Revert previous; it is not the correct solution to the problem of 2003-11-14 12:07:42 +00:00
disklabel_acorn.h protect against multiple inclusion. 2003-01-11 18:54:19 +00:00
dkbad.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
dkio.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
dkstat.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
domain.h Eliminate several uses of `curproc' from the socket-layer code and from NFS. 2004-05-22 22:52:13 +00:00
dvdio.h Add some headers for region code support (RPC), which will be added in the 2001-12-09 22:54:51 +00:00
endian.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
envsys.h - comma at the end of an enum list is illegal in ansi c 2003-02-20 20:57:56 +00:00
errno.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
event.h Initialise (most) pools from a link set instead of explicit calls 2004-04-25 16:42:40 +00:00
eventvar.h Protect the event queue with a simple mutex; this only partially addresses 2003-02-23 22:05:35 +00:00
exec.h make STACKGAPLEN 4k, since struct statvfs is more than 2k. 2004-05-01 22:42:51 +00:00
exec_aout.h Reshuffle MIDs value so that conflicts with binutils are avoided and 2004-02-11 01:03:35 +00:00
exec_coff.h - Add execsw es_setup_stack 2003-08-08 18:54:16 +00:00
exec_ecoff.h - Add execsw es_setup_stack 2003-08-08 18:54:16 +00:00
exec_elf.h add EI_NIDENT (16) as seen in other <elf.h> headers. 2004-05-17 02:28:17 +00:00
exec_macho.h Support Darwin static binaries (I should say: support the only Darwin 2003-10-19 07:52:22 +00:00
exec_script.h Back out the lwp/ktrace changes. They contained a lot of colateral damage, 2003-06-29 22:28:00 +00:00
extent.h Add extensible malloc types, adapted from FreeBSD. This turns 2003-02-01 06:23:35 +00:00
fcntl.h Add F_CLOSEM, F_MAXFD. 2004-01-05 00:35:53 +00:00
fdio.h
featuretest.h NetBSD.ORG -> NetBSD.org 2003-12-04 12:42:54 +00:00
file.h Provide a version of FILE_UNUSE() for cases where we already hold the 2004-05-16 17:48:18 +00:00
filedesc.h use a two-level bitmap as suggested by mogul and banga for fdalloc; 2003-10-30 07:27:02 +00:00
filio.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
float_ieee754.h Add a note how this file is to be used. 2003-10-26 16:44:20 +00:00
fstypes.h Add a define for VFS_MAXFIDSIZE 2004-04-21 02:21:49 +00:00
gmon.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
hash.h Add <sys/hash.h>, which currently implements three inline functions: 2001-12-05 06:51:55 +00:00
ieee754.h Use "#if" to compare two tokens, not "#ifdef". 2003-10-27 02:30:26 +00:00
inttypes.h
ioccom.h parameter with two es. From Peter Postma. 2004-02-24 15:22:01 +00:00
ioctl.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ioctl_compat.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ipc.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
kcont.h Misc. style fix; white-space usage, comment style, ansify, multiple 2004-03-25 23:02:58 +00:00
kcore.h
kernel.h define symbols also if _STANDALONE because arc4random needs mono_time. This 2003-10-02 12:14:00 +00:00
kgdb.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
kprintf.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ksem.h Don't make declarations visible from userland, unless _LIBC is defined, 2003-09-30 20:37:36 +00:00
ksyms.h o Fix a bug in ksyms that changed the real meaning of st_name entries for 2003-11-17 10:16:18 +00:00
kthread.h
ktrace.h Make ktrwrite() and ktrinitheader() private again. ktrsyscall32() no longer 2004-02-25 21:34:18 +00:00
lkm.h Since rev. 1.29, lkmdispatch is called before the LKM's load function. 2004-02-06 22:40:37 +00:00
localedef.h - No need to include sys/param.h and sys/types.h here. 2002-11-19 09:53:16 +00:00
lock.h introduce LK_EXCLOTHER for lockstatus(). 2004-05-18 11:55:59 +00:00
lockf.h Initialise (most) pools from a link set instead of explicit calls 2004-04-25 16:42:40 +00:00
lwp.h use lockstatus() instead of L_BIGLOCK to check if we're holding a biglock. 2004-05-18 11:59:11 +00:00
malloc.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
mallocvar.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
mbuf.h Standalone programs should not use stddef.h. They are more like the 2004-04-09 15:43:19 +00:00
md4.h NetBSD.ORG -> NetBSD.org 2003-12-04 12:42:54 +00:00
md5.h NetBSD.ORG -> NetBSD.org 2003-12-04 12:42:54 +00:00
midiio.h netbsd.org -> NetBSD.org 2003-12-04 13:57:30 +00:00
mman.h Add a MAP_WIRED flag to mmap(2), which causes the new mapping to be 2003-10-07 00:17:09 +00:00
mount.h Add a mutex for mount point I/O and wait counters (i.e. the `mnt_wcnt', 2004-05-02 12:21:02 +00:00
msg.h Add a new feature-test macro, _NETBSD_SOURCE. If this is defined 2003-04-28 23:16:11 +00:00
msgbuf.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
mtio.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
namei.h remove declaration of cache_purge that has turned into a macro. 2004-04-17 15:24:22 +00:00
null.h Update comment after the #endif for recent change. 2003-10-24 21:45:09 +00:00
param.h 2.0E: new pci_devinfo() argument. 2004-04-24 09:51:06 +00:00
pipe.h Initialise (most) pools from a link set instead of explicit calls 2004-04-25 16:42:40 +00:00
pmc.h Expose <machine/pmc.h> to userland. 2002-08-08 16:23:19 +00:00
poll.h Add a new feature-test macro, _NETBSD_SOURCE. If this is defined 2003-04-28 23:16:11 +00:00
pool.h Initialise (most) pools from a link set instead of explicit calls 2004-04-25 16:42:40 +00:00
power.h Add event type for AC adapter. 2004-05-03 07:41:47 +00:00
proc.h PR/9347: Eric E. Fair: socket buffer pool exhaustion leads to system deadlock 2004-04-17 15:15:29 +00:00
properties.h prototypes must not have variable name 2003-07-04 07:42:04 +00:00
protosw.h Eliminate space between function name and prototype. 2004-04-22 01:34:17 +00:00
ptrace.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
queue.h Consistently arrange order of definitions for each type. Specifically: 2004-04-18 14:25:34 +00:00
radioio.h Add support for radio cards. Written by Maxim Tsyplakov and Vladimir Popov 2002-01-01 21:51:38 +00:00
ras.h Add new macros: 2004-03-03 21:05:30 +00:00
reboot.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
resource.h Namespace police: wrap RLIM_NLIMITS inside _NETBSD_SOURCE since it's an 2004-04-26 10:33:38 +00:00
resourcevar.h Provide a mutex for the process limits data structure. 2004-05-06 22:20:30 +00:00
rnd.h Fix signed/unsigned comparison warnings. 2002-11-10 03:28:59 +00:00
sa.h kernel part of no-syscall upcall stack return: libpthread registers 2004-01-02 18:52:17 +00:00
savar.h add kernel part of concurrency support for SA on MP systems 2004-03-14 01:08:47 +00:00
scanio.h
sched.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
scsiio.h Fix two typos in comments. From OpenBSD. 2002-07-10 21:56:42 +00:00
select.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
sem.h Back out the lwp/ktrace changes. They contained a lot of colateral damage, 2003-06-29 22:28:00 +00:00
sha1.h prototype must not have variable name 2003-07-08 06:17:59 +00:00
shm.h Need to make sure __sysconf() has C linkage. 2003-10-20 22:16:33 +00:00
siginfo.h Add the notion of an "empty" ksiginfo_t (one where on signo is filled in). 2004-04-03 19:43:08 +00:00
signal.h Update namespace protection for siginfo; originally from Christos. 2004-05-07 23:54:48 +00:00
signalvar.h Change sigactsfree() to take a `struct sigacts' pointer, to fit the needs 2004-05-04 21:25:47 +00:00
sigtypes.h Define a few 32bit compat types (if COMPAT_NETBSD32, not exported to 2003-10-13 18:50:43 +00:00
socket.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
socketvar.h Eliminate several uses of `curproc' from the socket-layer code and from NFS. 2004-05-22 22:52:13 +00:00
sockio.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
stat.h Compact previous a little, making better use of _NETBSD_SOURCE. 2003-11-04 00:00:36 +00:00
statvfs.h use tab after #define. 2004-05-11 10:30:48 +00:00
stdint.h Factor out W{CHAR,INT}_{MAX,MIN} into their own header file. 2004-05-08 21:51:47 +00:00
swap.h
syscall.h Regen from syscalls.master rev. 1.142: 2004-05-10 22:30:41 +00:00
syscallargs.h Regen from syscalls.master rev. 1.142: 2004-05-10 22:30:41 +00:00
sysctl.h Tweak sysctl setup functions (the macros, actually) for use in lkms, 2004-05-20 06:34:24 +00:00
syslimits.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
syslog.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
systm.h use lockstatus() instead of L_BIGLOCK to check if we're holding a biglock. 2004-05-18 11:59:11 +00:00
systrace.h Don't pass the (unused) return value args to the 2003-10-31 03:28:12 +00:00
tablet.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
termios.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
time.h POSIX-2001: Add restrict keywords to gettimeofday(2) and setitimer(2); 2004-04-27 01:12:44 +00:00
timeb.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
timepps.h Fix NTP PPSAPI support (enabled with "options PPS_SYNC"): 2004-01-23 05:01:19 +00:00
times.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
timex.h Don't 'extern' function prototypes. 2002-03-17 11:14:04 +00:00
tprintf.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
trace.h Replace the statfs() family of system calls with statvfs(). 2004-04-21 01:05:31 +00:00
tree.h avoid generating compiler warnings; reported by des@des.no; solution 2004-03-28 19:38:30 +00:00
tty.h Constify the table argument to ttspeedtab. 2004-04-25 06:13:38 +00:00
ttychars.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ttycom.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ttydefaults.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
ttydev.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
types.h Replace the statfs() family of system calls with statvfs(). 2004-04-21 01:05:31 +00:00
ucontext.h Define a few 32bit compat types (if COMPAT_NETBSD32, not exported to 2003-10-13 18:50:43 +00:00
ucred.h Add mutex to protect the ucred reference counter. 2004-05-02 12:36:55 +00:00
uio.h PR# standards/16143: hide struct uio from userland behind a __UIO_EXPOSE 2003-09-13 16:59:29 +00:00
un.h Eliminate several uses of `curproc' from the socket-layer code and from NFS. 2004-05-22 22:52:13 +00:00
unistd.h Kernel portion of the fsync_range(2) system call. Written by Bill 2003-11-15 01:19:38 +00:00
unpcb.h Restore a change that made AF_LOCAL sockets block on connect(2) until 2003-11-29 10:02:42 +00:00
user.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
userconf.h
userret.h update comment to match reality: sparc64 uses mi_userret 2004-03-29 21:15:03 +00:00
utsname.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
uuid.h uuidgen(2) syscall. Originally from FreeBSD, ported by John Franklin in 2004-01-29 02:00:02 +00:00
vadvise.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
verified_exec.h prototype must not carry variable name 2003-07-08 06:49:19 +00:00
vmmeter.h Move UCB-licensed code from 4-clause to 3-clause licence. 2003-08-07 16:26:28 +00:00
vnode.h Add a mutex for mount point I/O and wait counters (i.e. the `mnt_wcnt', 2004-05-02 12:21:02 +00:00
vnode_if.h Make VOP_STRATEGY(bp) a real VOP as discussed on tech-kern. 2004-01-25 18:06:48 +00:00
wait.h correctly define _W_INT ifdef _KERNEL 2003-09-20 14:59:56 +00:00
wdog.h