Port-powerpc archive

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

Re: Porting to IBM Risc 6000



On Sun, Aug 11, 2002 at 12:22:05PM -0700, Matt Thomas wrote:

> My inclination is to have to move to a rs6k port and have
> GENERIC and GENERIC64 for 32bit and 64bit PPC platforms.
This would require a 32 bit userland, as 64 bit applications can't
run on a 32 bit machine and 32 bit applications will run in some
kind of emulation when a 64 bit kernel is running?
(Sorry for this questions. I don't have The Clue (C) (R) (TM), but 
I wane learn more about all this OS internas. This is the reason 
for my interrest in getting the rs6k port going: Learning by doing.)

> The real question is do we want a single kernel which can work
> on 32bit and 64bit platforms?
Stupid question: How can this work? A single Kernel for 32 and 64 bit
machines? Wouldn't the 32 bit compatibility force compromises that we
probably don't want? Like a 4GB address space limit? 

> The most significant thing is to create a RTAS module with the
> various functions we need. 
As I understand the CHRP spec and the CHRP to OFW binding RTAS is a
CHRP speciffic extension to OFW, so there is no RTAS already in NetBSD 
(macppc e.g)?
(Sorry to ask, but my VAX has eaten the /usr/src disk with the 
NetBSD source so I can't check this my self and it will take some days
to get the CVS repository mirrored again... ;-(  )

> Now if we do it right, there could
> be an RTAS work-alike implemented for PReP. 
I had a brief look into the PReP spec. There is also some hardware
abstraction called RTAS. But the PReP RTAS is hardware _and_ OS 
dependend. The PReP spec "defines the functions that must be abstracted, 
but it does not define the interface to the operating system nor does
it define the way the functions are collected into usable services."
[...] "Initial versions of the RTAS are distributed by an operating 
system vendor." I.e. we have to write our own PReP RTAS. We are free
to choose an OS interface for it so (perhaps) we can make it CHRP 
compatible. 

> But the most significant difference is that one uses a PC'ish 
> PNP database and CHRP uses OFW.
Next stupid question: Can't this be solved by attaching different busses?
like:
mainbus*        at root
cpu*            at mainbus?
ofbus*          at mainbus?
# taken from GENERIC ofppc

pci*            at ofbus?
ofisa*          at pci? dev ? function ?
# for CHRP

pci0            at mainbus0 bus ?
# and so on from GENERIC prep like it is at the moment.

> For instance, the 43p model 260 device tree will look something
> like:
> 
> ofbus* at root
> cpu* at ofbus?
> rtas* at ofbus?
> pci* at ofbus?
Why ofbus* at root? GENERIC ofppc is configured this way:
mainbus*        at root
ofbus*          at mainbus?
ofbus*          at ofbus?
cpu*            at mainbus?
ofdisk*         at ofbus?
ofnet*          at ofbus?
ofcons*         at ofbus?
ofrtc*          at ofbus?
-- 



tschüß,
         Jochen

Homepage: http://www.unixag-kl.fh-kl.de/~jkunz/



Home | Main Index | Thread Index | Old Index