[RFC][PATCH 6/8] Walnut DTS
Josh Boyer
jwboyer at linux.vnet.ibm.com
Tue Jul 17 12:39:58 EST 2007
On Tue, Jul 17, 2007 at 07:47:26AM +1000, Benjamin Herrenschmidt wrote:
> > That "typical practice" is inspired by the need to explicitly
> > put #address-cells and #size-cells into the device tree if you
> > want Linux to properly parse the device tree, even if the default
> > values would work perfectly (if Linux would work correctly,
> > that is).
>
> Linux does handle default values in some areas. The problem with default
> values is that they are badly defined and the spec contains gray areas
> and contradictions as to what the default values should be in some
> circumstances. As a general matter, I dislike default values because
> they somewhat require background knowledge of what default values should
> be in different contexts to "read" a device-tree. To be simple, I
> believe default values are a bad idea.
Right. See, there are people like me that don't know what the default values
are/should be. Having them explicitly listed, even if it's redundant, serves
as a good learning aid.
Now, realistically I do know what the default is in this case. But I only
learned that recently. With hopefully more people starting to port things
over to arch/powerpc it might be a good idea to document them at least.
Otherwise, I fear we'd wind up repeating ourselves over and over.
Could we get a 'thou shalt not rely on defaults' added to
booting-without-of.txt? Or maybe something less draconian ;).
josh
More information about the Linuxppc-dev
mailing list