[OpenBIOS] SPARC64: Forth re-entrancy during MMU I/D TLB miss

Blue Swirl blauwirbel at gmail.com
Tue Aug 31 20:18:38 CEST 2010

On Tue, Aug 31, 2010 at 3:38 PM, Mark Cave-Ayland
<mark.cave-ayland at siriusit.co.uk> wrote:
> Hi everyone,
> So having a poke around various bits of documentation relating to
> implementing pgmap@, I've come to the realisation that since the Solaris
> kernel needs to install it's own va>tte-data implementation into OpenBIOS
> then it's going to be necessary to call back into Forth from the D/I-MMU
> miss traps.

The thought of that gives me the shivers.

> I've been looking around the code in arch/sparc64/switch.S but it looks as
> if this code only swaps between 2 individual contexts - am I right in
> thinking there needs to be a way of specifying the memory address of the
> context for this code to be reusable during a trap? Or would a better way be
> to duplicate this file but with another static context used only for MMU
> miss traps?

Sparc64 should use the same approach as Sparc32 (and x86): save the
context to stack. It's even easier than Sparc32 because there is a
window flush instruction.

More information about the OpenBIOS mailing list