macros and dtc
Geoff Levand
geoffrey.levand at am.sony.com
Tue Feb 20 02:51:00 EST 2007
Kumar Gala wrote:
> After spending some time this weekend cleaning up dts files I figured
> it would be nice if we can some to consensus on how we are going to
> do macro support. There is clearly a lot of duplication between
> dts's and it only gets worse when you add in slight variations for
> revs of boards.
>
> I wasn't sure if we are thinking of using some style of preprocessor
> (cpp, m4, etc..) or trying to add something into dtc itself.
>
> However, I think it would be good for us to get some traction towards
> a solution for in kernel dts files.
Based on the previous discussions, there were some concerns with using CPP
on the dts. m4 is a nice preprocessor and I think that it sould be the
choice.
It would be good to have the kernel config available when running the
preprosessor, so that would mean running it from the makefile, not the
wrapper script. It also seems then that having a different file extension
so the processing would fall naturally into a makefile target.
$(obj)/xyz.dts: xyz.dts.m4
$(call cmd,m4)
-Geoff
More information about the Linuxppc-dev
mailing list