[U-Boot] Merging device trees at runtime for module-based systems

Wolfgang Denk wd at denx.de
Thu Oct 25 14:44:41 CEST 2012


Dear Daniel,

In message <5087B919.2010006 at gmail.com> you wrote:
> 
> So let's say we have n versions of the baseboard and m versions of the
> module, we would much like to only prepare n + m files, instead of n * m
> by pre-compiling every possible combination (some of which may actually
> never occur 'in the wild').

What you are facing is a situation that
1) appears to be pretty common, and
2) has (AFAICT) not been truely satisfactory solved yet.

> So my question is: is it possible to do that kind of assembly of a
> number of files at runtime in U-Boot? I guess all it takes is merging a
> number of trees together, right? I browsed through the APIs but couldn't
> yet find an clear approach to that kind of problem. If not, what would
> it take to add that functionality? I can probably help with the
> implementation if someone tells me what would be the right way.

I think it should be possible to overlay several DT images; ideally
these would be strictly orthogonal, i. e. the newly loaded one would
only add new properties, but I think it should be also no problem to
define some latest-wins policy, i. e. in case of already existing
properties the newly loaded ones would just overwrite the previous
settings.

I definitely can see the benefit of such a feature and would be happy
if you could go forward and implement it.

Thanks in advance.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
While money can't buy happiness, it certainly lets  you  choose  your
own form of misery.


More information about the U-Boot mailing list