kernel - use new td_ucred in numerous places
authorMatthew Dillon <dillon@apollo.backplane.com>
Tue, 15 Dec 2009 18:43:48 +0000 (10:43 -0800)
committerMatthew Dillon <dillon@apollo.backplane.com>
Tue, 15 Dec 2009 18:43:48 +0000 (10:43 -0800)
commit9910d07b2f8670a44edbe17863f961ffbc6ea537
tree838053a60a1e058de31fdd72274ba79bf96dadd7
parente348d1a5ff2e9fdfd4ad4e5a6c2fc7d89848ee7f
kernel - use new td_ucred in numerous places

* Use curthread->td_ucred in numerous places, primarily system calls,
  where curproc->p_ucred was used before.

* Clean up local variable use related to the above.

* Adjust several places where p_ucred is replaced to properly deal
  with lwp threading races to avoid accessing and freeing a potentially
  stale ucred.

* Adjust static procedures in the ktrace code to generally take lwp
  pointers instead of proc pointers.
34 files changed:
sys/emulation/43bsd/43bsd_hostinfo.c
sys/emulation/dragonfly12/dfbsd12_stat.c
sys/emulation/linux/linux_file.c
sys/emulation/linux/linux_misc.c
sys/emulation/linux/linux_socket.c
sys/emulation/linux/linux_stats.c
sys/emulation/linux/linux_uid16.c
sys/kern/imgact_resident.c
sys/kern/init_main.c
sys/kern/kern_acl.c
sys/kern/kern_checkpoint.c
sys/kern/kern_descrip.c
sys/kern/kern_event.c
sys/kern/kern_fork.c
sys/kern/kern_jail.c
sys/kern/kern_ktrace.c
sys/kern/kern_prot.c
sys/kern/kern_resource.c
sys/kern/kern_sysctl.c
sys/kern/kern_varsym.c
sys/kern/lwkt_caps.c
sys/kern/sys_generic.c
sys/kern/sys_mqueue.c
sys/kern/sysv_msg.c
sys/kern/sysv_sem.c
sys/kern/sysv_shm.c
sys/kern/uipc_syscalls.c
sys/kern/vfs_syscalls.c
sys/netproto/ncp/ncp_mod.c
sys/platform/pc32/i386/sys_machdep.c
sys/sys/thread.h
sys/vfs/nfs/nfs_syscalls.c
sys/vm/vm_mmap.c
sys/vm/vm_swap.c