Subject: Re: "pmap_unwire: wiring ... didn't change!"
To: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
From: Chuck Silvers <chuq@chuq.com>
List: port-mips
Date: 09/02/2005 08:36:16
On Thu, Sep 01, 2005 at 09:27:55PM +0900, Izumi Tsutsui wrote:
> In article <20050830161048.GB12998@spathi.chuq.com>
> chuq@chuq.com wrote:
> 
> > if we can remove the need to save/change/restore the pagemask
> > in the common cases of creating and invalidating TLB entries,
> > that would be a nice improvement, yea.
> 
> Well, I'm not a mips guru ;-p

you keep saying that, I keep not believing you.  :-)


> so there are some questions:
> - MIPSX_TLBUpdate() does tlbr (which might modify the pagemask register),
>   but in this function all TLBs have the default pagemask?

sounds right to me.


> - MIPSX_TLBRead() might read a wired TLB entry, so we should restore
>   pagemask before return?

yup.


> - MIPSX_TBIAP() does tlbr but it won't read wired TLB entries,
>   so no need to restore the default pagemask?

yup.


> - MIPSX_TLBMissException() only happens non-wired TLB entries
>   so no need to restore the default pagemask?

yup.


> > note that even with that change, my mobilepro 880 still doesn't work.
> > now it hangs even before printing the copyright (but after printing
> > the mem_cluster stuff).
> 
> Hmm, it seems that MIPS3_4100 (which supports 1k page too?) requires
> a special pagemask value. How about this one? (untested)

do we need to save and restore the special 4100 pagemask any more than
we need to save and restore the normal pagemask?  if all the non-locked
entries have it, then wouldn't it be the same?  or does the hardware
automatically zero the pagemask sometimes?

what kind of box has a 4100 CPU anyway?

-Chuck