Re: curproc vs MP vs locking

2020-09-15 Thread Claudio Jeker
On Tue, Sep 15, 2020 at 04:38:45PM +0200, Mark Kettenis wrote: > > Date: Tue, 15 Sep 2020 12:34:07 +0200 > > From: Martin Pieuchot > > > > Many functions in the kernel take a "struct proc *" as argument. When > > reviewing diffs or reading the signature of such functions it is not > > clear if t

Re: curproc vs MP vs locking

2020-09-15 Thread Mark Kettenis
> Date: Tue, 15 Sep 2020 12:34:07 +0200 > From: Martin Pieuchot > > Many functions in the kernel take a "struct proc *" as argument. When > reviewing diffs or reading the signature of such functions it is not > clear if this pointer can be any thread or if it is, like in many cases, > pointing t

curproc vs MP vs locking

2020-09-15 Thread Martin Pieuchot
Many functions in the kernel take a "struct proc *" as argument. When reviewing diffs or reading the signature of such functions it is not clear if this pointer can be any thread or if it is, like in many cases, pointing to `curproc'. This distinction matters when it comes to reading/writing memb