Subject: Re: non-ofw kernels [was Re: NetBSD/G3 upgrade]
To: Bill Studenmund <wrstuden@nas.nasa.gov>
From: David A. Gatwood <dgatwood@mvista.com>
List: port-macppc
Date: 06/23/1999 13:02:10
On Wed, 23 Jun 1999, Bill Studenmund wrote:

> I'm not sure how much of a problem that'll be. My main thought with "bart"
> was that it'd act as an indicator of a nubus class machine. I don't think
> at any point we'd be going out and twiddling bits in the bart chip itself.
> It's more that we expect to find nubus-ish cards around.

You'll probably want to enable and disable the various slots, which is
handled by BART, as well as switching on or off burst mode and setting the
chip's speed.  There might also be a need to reset it for some reason
(dunno), as well as determine the chip revision to know whether to check
for a possible PDS device instead of slot E.  I'm not sure how to do that,
though....  Really, you should probably be able to leave that part as
MacOS leaves it.


> Apple's practice was to make internal video look like a nubus card, so
> even on machines w/o nubus expansion slots, we'd probably need to look at
> the internal video as a nubus card. :-(

The PDM motherboard video framebuffer lives in motherboard RAM, and thus
you can use the video address that MacOS feeds you to determine whether
you're running on motherboard video or an AV card.  If it's motherboard
video, the CLUT stuff is located in normal IO space (50f24000), not in
NuBus card range, though it's possible that it might be mirrored up there.

The AV card lives in the superslot portion of slot E.  The HPV card lives
in the regular slot portion of slot E.  Thus, it is quite trivial to
determine which one is in use just by looking at the framebuffer location.
If it's above 0xF0000000, it's an HPV (regular slot space for slot E).  If
it's in the 0xE0000000 - 0xEFFFFFFF range, it's an AV card.  If it's at
0x0 or 0x01000000 (I think that's right, but I may not have the 1 in the
right place), it's a PDM on motherboard video.  As for how to detect other
NuBus cards... then you'll have to actually implement real support for
nubus, I suspect.


Later,
David