> The following from tegra-harmony.dts compiles fine:
>
> /dts-v1/;
>
> /memreserve/ 0x1c000000 0x04000000;
> /include/ "tegra250.dts"
>
> / {
>
> However, if I re-order this as follows:
>
> /dts-v1/;
> /include/ "tegra250.dts"
>
> /memreserve/ 0x1c000000 0x04000000;
>
> / {
>
> Then dtc fails:
>
> Is this a dtc bug, or does the DTS syntax actually disallow this?
Correct. The grammar is explicitly:
sourcefile:
DT_V1 ';' memreserves devicetree
;
memreserves:
/* empty */
| memreserve memreserves
;
memreserve:
DT_MEMRESERVE addr addr ';'
and then much later devicetree leads to...:
propdata:
propdataprefix DT_STRING
| propdataprefix '<' celllist '>'
| propdataprefix '[' bytestring ']'
| propdataprefix DT_REF
| propdataprefix DT_INCBIN '(' DT_STRING ',' addr ',' addr ')'
where INCBIN is the include mechanism.
jdl
_______________________________________________
devicetree-discuss mailing list
[email protected]
https://lists.ozlabs.org/listinfo/devicetree-discuss