Port-macppc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Booting on a Powerbook6,8 (was Re: Installing 8.0 on a Powerbook6,8)



> On Feb 15, 2021, at 7:47 PM, Jason Thorpe <thorpej%me.com@localhost> wrote:
> 
> Ok, so I spent a little more time working on this and I think it boils down to the fact that we just don't implement a correct virt-mode OpenFirmware client on PowerPC.

So, I have spent some time working on this (I'm really motivated to get this Powerbook6,8 working because it's an example of a system for which I have *other* changes I want to finish up :-)

It has mainly been an exercise in re-factoring that allow me to do a couple of things:

1- Do a bunch more of the early interaction with OFW *still in the OFW context*.

2- Dumping OFW's translations, and, for translations that are not already covered by mappings the kernel sets up, entering those mappings into the kernel's pmap.  (The vast majority of the translations maintained by the firmware are already covered by BAT mappings the kernel uses for I/O regions ... only 3 or 4 regions actually needed to be entered to the kernel's pmap on my test system.)

3- Split the initialization of kernel VM data structures (BAT table initialization, setting up the HTAB and kernel pmap, etc.) from programming the MMU hardware.

This allows me to have a very short critical section where we switch the MMU to be managed by the kernel.  The call OFW call trampoline no longer has any saving / restoring of segment registers, etc.  However, I am going to stick with the trampoline because it will be useful for calling into proper real-mode OFW as well.  And I am likely to need a different version of the trampoline for 601 systems because I/O regions are not mapped using BATs on the 601, but rather using I/O segment mappings, and there is at least one I/O segment (0xf0000000) that is going to require special handling (because OFW is mapped into that segment)... I could either choose to make that region a BAT mapping, or I could save/restore the SRs on the 601 only.  Anyway, I have options :-)

It's booting and working fine on my PowerMac10,1 (1.42GHz Mac mini).  I will try it out on the Powerbook6,8 hopefully a little later today.

I've already gotten replies from some folks about helping to test on 601 systems.  If there are others out there willing to help test these changes on a wider variety of HW, please ping me off-list.

Thanks!

-- thorpej



Home | Main Index | Thread Index | Old Index