Use atomics for mutating p_sigmask

2014-07-07 Thread Matthew Dempsky
p_sigmask is only modified by the owning thread from process context (e.g., sys_sigprocmask(), sys_sigreturn(), userret(), or postsig()), but it can be accessed anywhere (e.g., interrupts or threads on other CPUs). Currently sys_sigprocmask() protects p_sigmask with splhigh(), but that's not MP-sa

Re: Mark get*[ug]id() as NOLOCK

2014-07-07 Thread Philip Guenther
On Mon, Jul 7, 2014 at 11:18 AM, Matthew Dempsky wrote: > Recently guenther changed user credentials to be a per-process > resource, but kept a per-thread cache of credentials that get > refreshed at each system call entry. All of the get*[ug]id() system > calls simply access the thread cached c

Re: Mark get*[ug]id() as NOLOCK

2014-07-07 Thread Mark Kettenis
> Date: Mon, 07 Jul 2014 15:06:47 -0400 > From: Ted Unangst > > On Mon, Jul 07, 2014 at 11:18, Matthew Dempsky wrote: > > Recently guenther changed user credentials to be a per-process > > resource, but kept a per-thread cache of credentials that get > > refreshed at each system call entry. All

Re: Mark get*[ug]id() as NOLOCK

2014-07-07 Thread Ted Unangst
On Mon, Jul 07, 2014 at 11:18, Matthew Dempsky wrote: > Recently guenther changed user credentials to be a per-process > resource, but kept a per-thread cache of credentials that get > refreshed at each system call entry. All of the get*[ug]id() system > calls simply access the thread cached crede

Re: Mark get*[ug]id() as NOLOCK

2014-07-07 Thread Mark Kettenis
> Date: Mon, 7 Jul 2014 11:18:53 -0700 > From: Matthew Dempsky > > Recently guenther changed user credentials to be a per-process > resource, but kept a per-thread cache of credentials that get > refreshed at each system call entry. All of the get*[ug]id() system > calls simply access the thread

Mark get*[ug]id() as NOLOCK

2014-07-07 Thread Matthew Dempsky
Recently guenther changed user credentials to be a per-process resource, but kept a per-thread cache of credentials that get refreshed at each system call entry. All of the get*[ug]id() system calls simply access the thread cached credentials, and possibly copyout() them if necessary, so they're s