[U-Boot] pull request for u-boot-tegra/master

Stephen Warren swarren at wwwdotorg.org
Mon Jun 11 23:59:39 CEST 2012


On 06/08/2012 07:53 PM, Simon Glass wrote:
> Hi Stephen,
> 
> On Fri, Jun 8, 2012 at 3:52 PM, Stephen Warren <swarren at wwwdotorg.org
> <mailto:swarren at wwwdotorg.org>> wrote:
...
>     Uggh. The problem is that older versions of dtc would only accept a
>     single definition of the root node; they don't allow another copy to be
>     specified, which "overlays" or is "merged with" it. Put another way, dtc
>     can't compile a simple:
> 
>     > /dts-v1/;
>     >
>     > / {
>     >     foo = "bar";
>     > };
>     >
>     > / {
>     >     foo = "bar";
>     > };
> 
>     That means we can't separate the device tree source into separate
>     skeleton.dtsi, tegra20.dtsi, and tegra2-$board.dts.
> 
>     So, we have basically no choice but to require people to upgrade to a
>     recent dtc. If we do that, we can also get rid of the cpp hacks, since
>     the latest dtc has a -i option that can be used to set an include path.
> 
> 
> Oh dear, it's worse than I thought. Perhaps the first step would be to
> ask the device-tree people to issue a new release (1.4?), if they have
> not already.

At this point, given how rapidly device tree in general (and hence dtc)
is evolving, the simplest solution seems to be just to add a copy of the
dtc source into U-Boot itself. This is the approach that the kernel has
taken and ensures that everybody is working from the "same page" w.r.t. dtc.

Wolfgang, can we add the dtc source into the U-Boot source tree in order
to avoid these problems? The only alternative would be for everyone to
manually install a recent version themselves, since the version of dtc
packaged by commonly-used distros is far too old to be useful.

For reference, my copy of the U-Boot source is about 81M in >7500 files.
Adding dtc would add roughly 364K and 34 files (at least, that's the
size of the copy of dtc in the kernel, which omits the tests etc.). That
seems pretty small.


More information about the U-Boot mailing list