[PATCH 3/6] 8xx: get rid of _PAGE_HWWRITE dependency in MMU.
benh at kernel.crashing.org
Tue Oct 6 10:15:39 EST 2009
On Tue, 2009-10-06 at 00:55 +0200, Joakim Tjernlund wrote:
> > Sure but if dirty is cleared by the kernel, then you also need to
> > write permission in the TLB or it will miss setting dirty on the
> > store to the page.
> Dirty map to HW changed bit so if kernel clears it, the next
> store will trap to DTLB error. There I will check RW and clear it
> without trapping to C. Is that OK? Not if I read you correcly below ..
Well, if the HW has the ability to enforce trap when store with !DIRTY,
then that's fine, just map it that way, but you shouldn't have to handle
it in the DTLB error neither, the kernel will fix it up for you in
I think I need to get myself an 8xx manual and figure out what that damn
MMU actually does :-)
> No it's really !(RW _AND_ DIRTY) -> no store permitted, and
> .. hmm, I don't do that. I should do a
> if ( store && !(pte & (RW | DIRTY))
> goto DSI
> in DTLB error?
Well, if the HW does the test of DIRTY, then it's fine, as you seem to
suggest above. _something_ needs to do it, either SW or HW, ie, we need
to catch any attempt to store to a non-dirty page to set dirty.
> > !(PRESENT _AND_ ACCESSED) -> no access permitted.
> Yes, how about those pinned kernel ptes. Do they have ACCESSED from
More information about the Linuxppc-dev