Subject: Re: Are there any known problems with uvm or pmap in -current as of about Oct. 16?
To: Markus W Kilbinger <kilbi@rad.rwth-aachen.de>
From: Chuck Silvers <chuq@chuq.com>
List: port-macppc
Date: 11/07/2001 09:10:28
--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
ah, I was wrong, it is a pmap bug. pmap_pte_clear() is calling
TLBIE() on the address that contains the PTE rather than the address
that the PTE is mapping. the attached diff fixes the problem.
I don't know what document that reference about "As shown in Section 7.6.3.2.2"
comes from, is that document wrong or did you just mis-read it, matt?
also, pmap_clear_bit() is doing some unnecessary work to compute
the pte's address, it could just check the PTE_VALID bit in the pvo's
copy of the pte and skip the pte processing if it's not set.
-Chuck
On Mon, Nov 05, 2001 at 11:26:49PM +0100, Markus W Kilbinger wrote:
> >>>>> "Chuck" == Chuck Silvers <chuq@chuq.com> writes:
>
> Chuck> at this point the new pmap appears to be much more stable
> Chuck> than the old one, so I recommend that everyone turn on
> Chuck> "options NEWPMAP" if you haven't done so already.
>
> After all these changes I still see a strange nfs related problem,
> probably macppc specific, detected when trying to build a kernel in
> nfs mounted /usr/src:
>
> Simply cd into such a nfs mounted directory on a macppc machine and
> execute
>
> sh /sys/conf/newvers.sh && cat vers.c
>
> vers.c is missing most of its lines most of the time!
>
> I could only reproduce this problem in this scenario (macppc nfs
> client, no matter what nfs server).
>
> Is this also pmap related? Can anybody reproduce this problem?
>
> Markus.
--SUOF0GtieIMvvwua
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="diff.ppc-pmap"
Index: arch/powerpc/mpc6xx/pmap.c
===================================================================
RCS file: /cvsroot/syssrc/sys/arch/powerpc/mpc6xx/pmap.c,v
retrieving revision 1.34
diff -u -r1.34 pmap.c
--- arch/powerpc/mpc6xx/pmap.c 2001/11/06 06:25:28 1.34
+++ arch/powerpc/mpc6xx/pmap.c 2001/11/07 17:06:33
@@ -506,13 +506,13 @@
}
static __inline void
-pmap_pte_clear(volatile pte_t *pt, int ptebit)
+pmap_pte_clear(volatile pte_t *pt, int ptebit, vaddr_t va)
{
/*
* As shown in Section 7.6.3.2.2
*/
pt->pte_lo &= ~ptebit;
- TLBIE(pt);
+ TLBIE(va);
EIEIO();
TLBSYNC();
SYNC();
@@ -2049,7 +2049,7 @@
pt = pmap_pvo_to_pte(pvo, -1);
if (pt != NULL) {
pmap_pte_synch(pt, &pvo->pvo_pte);
- pmap_pte_clear(pt, ptebit);
+ pmap_pte_clear(pt, ptebit, pvo->pvo_vaddr);
}
rv |= pvo->pvo_pte.pte_lo;
pvo->pvo_pte.pte_lo &= ~ptebit;
--SUOF0GtieIMvvwua--