[patch 29/30] PS3: Device tree source.

Segher Boessenkool segher at kernel.crashing.org
Fri Jun 15 18:37:03 EST 2007


>> "node name" in flat device trees doesn't allow a proper
>> "name" property to exist for the root node.  This is a
>> bug in the flat device tree tools, and either should be
>> fixed, or this should be clearly documented as a divergence
>> from "real" OF.
>>
>> "name" of the root node is a bit special, since it is
>> never displayed as part of a device path or used for
>> device selection (instead, "/" at start of a path is
>> handled specially, just like on unix filesystems).
>
> This 'special' behaviour, the fact that it's definition is out of sync
> with the generic name recommended practice, and finally, the fact that
> quite a lot of real OFs out there don't even bother having one, makes 
> me
> think that it's a good idea to stick to what I did, which is to say the
> root node has no name in a flat device-tree.

Putting that info in "compatible" instead should work
fine enough.

> Now, what I -may- do to avoid information loss is tweak prom_init.c to
> actually extract that name if it exist and stick a "name" property in
> the root node in that case when flattening the tree.

Nice, thanks!

> But I still beleive as far as flat DTs for embedded are concerned, we
> shouldn't use and rely on having a name at the root of the tree.

There _has_ to be a "name" property.  But you have one,
just not with interesting contents ;-)

>> Since anything that matches for "compatible" entries
>> also first should check the "name" contents, it should
>> be okay for flat device trees to have the information
>> that could/should be in "name" in "compatible", instead.


Segher




More information about the Linuxppc-dev mailing list