Order of the Butterfly
Posts: 301 from 2003/2/24
From: Genesi
jcmarcos, Of course I was right! :D
Thanks jigen, for such nice explanations. I was hoping I could go the slow, painful route and bring around a gradual realisation through argument.
Of course just blinding them with science is just as good :)
Here is the big big post that explains everything;
The initial task to get MacOS X working on Pegasos is to implement the Mac prom_#? firmware functionality and expected stuff in the OpenFirmware - XPostFacto does this to SOME extent but it expects that there is at least a sane (as sane as Apple OF gets) foundation to work from.
SmartFirmware contains NO Apple proprietary functions, therefore has NO base to work from. Someone would have to add this. I suspect it would be possible from a Forth boot script or loader (perhaps a yaboot-style thing).
The code from CodeGen supports ELF and COFF, I am not entirely sure of the differences between COFF and XCOFF. I also don't know if the support is compiled in. NetBSD has an XCOFF loader because NetBSD's loader for OpenFirmware is generally meant to run on Apple Macs, which most certainly DO have XCOFF support. I am also not entirely sure that Pegasos OF can boot from HFS+ filesystems or recognise Mac partitioning. You cannot boot MacOS if OF doesn't see the disk layout, read the filesystem or understand the loader.
As for NVRAM, it would need to be stored permanently somewhere; Apple Macs rely on it for certain things, and act strangely (not keeping time etc.) when it is blank (take a real Mac, and do COMMAND-OPTION-P-R and it will nuke the nvram.. anything below OS X will FREAK, OS X just ignores it but makes things up as it goes along - not ideal :)
It might be possible to "portion" out 8k of nvram especially for MacOS usage. I do not recall the size of the nvram on the Pegasos II at this time.
Drivers for Pegasos for Darwin or IOKit would have to be written. Porting Darwin is the very first step - initialise the northbridge, and so on, to do the things that Darwin and MacOS want to do.
I wonder how many people want to spend the time reimplementing drivers for 11 discrete and unsupported hardware components;
* OS X has *NO* support for legacy PS/2, serial ports or parallel ports. Pegasos firmware currently doesn't support USB keyboards, so you could get around this by using BOTH. If you relegated serial port support to simply Darwin kernel debugging (no MacOS access), then this would be easy.
* not to mention the essential Via IDE (otherwise speed will be practically zero)
* Via Firewire
* Via (UHCI) USB controller. I am not sure if the USB controller is supported on a PCI card in MacOS or not. It's certainly possible to plug in PCI USB cards and have them "just work" on MacOS. One in the southbridge (with southbridge registers..) however may be different.
* the Via AC97 functionality *and* the specific Sigmatel codec functionality
* and definitely not the Via Rhine or Marvell ethernet.
Then there is hoping MacOS has support for your non-OpenFirmware Radeon (HAHA good luck!) or flashing it with an OpenFirmware BIOS and hoping it still runs under MorphOS and Linux and everything else (should.. but.. the world is full of surprises).
MacOS might boot without specific support for those chipsets bar USB (since MacOS requires it) and the requisite changes to Darwin and the OpenFirmware initial stuff. After that new drivers would need to be installed and SOMETHING like XPostFacto would be useful as long as it didn't require booting MacOS first (maybe a custom Darwin install CD could be made..)
Darwin developers (real PowerPC ones!!) should be getting Pegasos systems from the Freescale deal, so at least we will have Darwin sorted with a little help. It's quite disappointing for me as it stands that Darwin has gone from a very successful PowerPC kernel to yet-another-x86-project. It's depressing to see alternative platforms thrown over the side just so they can get every variant of the PC working - I wonder where the "cool" factor of getting Darwin to boot on every PowerPC machine ever created could have gone, as jigen said, plenty of IBM systems around - thin clients and terminals all the way up to servers.. and then there are more than just Apple machines. There is an RS/6000 (CHRP!!) laptop series somewhere in the world and occasionally on eBay - doesn't it sound cool to have that kind of weird and wacky support, doesn't NetBSD thrive on that kind of "it runs on everything" rather than the more Windowsy model of "it runs on everything that executes IA-32 instructions"?
Neko
Matt Sealey, Genesi USA, Inc.
Developer Relations
Product Development Analyst