Device trees

Matt Sealey matt at genesi-usa.com
Fri Jul 25 08:31:14 UTC 2008


Philip Schulz wrote:
>
> Unless I misunderstood what you guys said, I think it should be done
> the other way around.
> 
> It's my understanding that Linux always uses the FDT internally. If it
> finds that it's being booted from a full Open Firmware implementation
> with device tree, it will first parse the device tree and convert it
> to an FDT. That way, Linux doesn't have to do any client interface
> calls once it's past the device tree parsing stage. I think that's
> good, see below.

It would be more correct to say that both device tree implementations
are parsed and pushed into a single internal device tree representation.

The only difference is OpenFirmware implementations had this done anyway
(since quiesce is called and the OF is killed, they need a copy of the
DT) and in a flattened device tree, a text representation is compiled
and this binary blob is attached to the kernel either manually or by
boot firmware.

I would definitely suggest a similar route; using the CIF to access the
device drivers hardly ever works properly, and it's slow (horrible
calling convention) and cannot support interrupts (everything must be
polled, through that horrible calling convention).

There is little point keeping anything but RTAS around (RTAS is
important :)

-- 
Matt Sealey <matt at genesi-usa.com>
Genesi, Manager, Developer Relations


More information about the freebsd-ppc mailing list