On 11/11/2010 04:03 PM, [email protected] wrote:
> From: Dirk Brandewie <[email protected]>
> 
> This patch forces the size of the DTB to be modulo 32 bytes. This is
> needed to support linking multiple DTB's into a single section in the
> image. GCC wants structures to be 32 byte aligned without this change
> DTB's after the first in the section may not be properly aligned so
> the flat tree parsing code will fall over.
> 
> Signed-off-by: Dirk Brandewie <[email protected]>

I don't think 32 is a universal number; it should depend on the ABI.  On
x86, for one thing, I'm pretty sure that there is no particular
alignment requirements beyond the natural alignment of the data items,
for example.

Although 32 is probably conservative on any platform, please flag the
origin of this with a comment, or make it a constant defined in a header
file... otherwise, if this breaks for whatever reason it'll be near
impossible to find.

        -hpa
_______________________________________________
devicetree-discuss mailing list
[email protected]
https://lists.ozlabs.org/listinfo/devicetree-discuss

Reply via email to