Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 6 Jul 2003 22:41:53 -0700
From:      Alfred Perlstein <bright@mu.org>
To:        David Xu <davidxu@viatech.com.cn>
Cc:        cvs-all@FreeBSD.org
Subject:   Re: cvs commit: src/lib/libpthread/thread thr_attr_get_np.c thr_cancel.c thr_getschedparam.c thr_join.c thr_mutex_prioceiling.c thr_sigaction.c thr_sigmask.c thr_sigpending.c thr_sigsuspend.c
Message-ID:  <20030707054153.GN72093@elvis.mu.org>
In-Reply-To: <005f01c34442$f9091c40$f001a8c0@davidw2k>
References:  <200307070428.h674SNfq092785@repoman.freebsd.org> <20030707044204.GM72093@elvis.mu.org> <005f01c34442$f9091c40$f001a8c0@davidw2k>

next in thread | previous in thread | raw e-mail | index | archive | help
* David Xu <davidxu@viatech.com.cn> [030706 21:45] wrote:
> 
> > * David Xu <davidxu@FreeBSD.org> [030706 21:28] wrote:
> > > davidxu     2003/07/06 21:28:23 PDT
> > > 
> > >   FreeBSD src repository
> > > 
> > >   Modified files:
> > >     lib/libpthread/thread thr_attr_get_np.c thr_cancel.c 
> > >                           thr_getschedparam.c thr_join.c 
> > >                           thr_mutex_prioceiling.c thr_sigaction.c 
> > >                           thr_sigmask.c thr_sigpending.c 
> > >                           thr_sigsuspend.c 
> > >   Log:
> > >   Avoid accessing user provided parameters in critical region.
> > 
> > Interesting, is this to avoid pagefaults during critical sections
> > inside userspace?
> > 
> Yes.

Sorry to yammer out a bunch of questions out of the blue, but I'm
trying to understand:

Is that completely necessary?  I mean, isn't it likely that these
arguements are paged in since they are parameters that have just
been touched by the process?  What if there's paging pressure and
the stack gets paged out anyway?  Is there something protecting
that from happening?  I mean, I know it would be unpleasant to
fault, but the code should be able to handle this right?

-- 
-Alfred Perlstein [alfred@freebsd.org]
'Instead of asking why a piece of software is using "1970s technology,"
 start asking why software is ignoring 30 years of accumulated wisdom.'



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030707054153.GN72093>