Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 25 Aug 2001 00:18:55 -0700
From:      Julian Elischer <julian@elischer.org>
To:        Peter Wemm <peter@wemm.org>
Cc:        Matt Dillon <dillon@earth.backplane.com>, Alfred Perlstein <bright@mu.org>, David Greenman <dg@root.com>, freebsd-hackers@FreeBSD.ORG
Subject:   Re: Possible race in i386/i386/pmap.c:pmap_copy()
Message-ID:  <3B87515F.3EEE8188@elischer.org>
References:  <20010825055913.1ED783810@overcee.netplex.com.au>

next in thread | previous in thread | raw e-mail | index | archive | help
Peter Wemm wrote:
> 
> Matt Dillon wrote:
> >
> > :
> > :Thinking about this a bit more....
> > :doesn't each process ahve it's own PTD?, so a process could sleep and
> > :another could run but it would have a differnt PTD
> > :so they could change that PTDE with impunity
> > :because when teh current process runs again it get's its own
> > :ptd back again..
> >
> >     Hmm.  Ok, I think you are right.  APTDpde is what is being loaded
> >     and that points into the user page table directory page, which is
> >     per-process.  So APTDpde should be per-process.
> 
> But it is!  (sort-of)  APTDpde was per-process but is now per-address-space
> with the advent of fork and RFMEM sharing (and KSE).

AH yes, it's a race for KSe, but we are 1:1 still so it's not a problem (yet :-)
( at least, not the one that's hitteng me at the moment)

For your info peter, What I'm seeing is that at exit
(or maybe even before), occasionally PTES are found to have already been 
zero'd even though thevm thinks they should still be valid..
I can't imagine what I've screwed up but it's sure subtle...


> 
> When we context switch, PTD goes with the process^H^H^H^Haddress space, and
> APTD is merely mapped by the last entry in the per-process PTD
> (PTD[APTDPDTI] if memory serves correctly).

(second last)


> 
> Cheers,
> -Peter
> --
> Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au
> "All of this is for nothing if we don't go to the stars" - JMS/B5
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-hackers" in the body of the message

-- 
+------------------------------------+       ______ _  __
|   __--_|\  Julian Elischer         |       \     U \/ / hard at work in 
|  /       \ julian@elischer.org     +------>x   USA    \ a very strange
| (   OZ    )                                \___   ___ | country !
+- X_.---._/    presently in San Francisco       \_/   \\
          v

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




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