DTC/dts modifications
Jon Loeliger
jdl at freescale.com
Tue May 2 05:45:33 EST 2006
On Mon, 2006-05-01 at 14:39, Kumar Gala wrote:
>
> Comment aren't the issue.
Ah, ok.
> > I think to get CPP to be usable, it will need to handle
> > the # emitted line-location markers, "# <line> <file> <level>".
>
> Don't follow you here.
The pre-processor emits crap like this:
# 1 "cmd_load.c"
# 1 "/proj/ppc/sysperf/sw/u/jdl/86xx/u-boot-86xx/common//"
# 1 "<built-in>"
# 1 "<command line>"
# 1 "cmd_load.c"
# 27 "cmd_load.c"
# 1 "/proj/ppc/sysperf/sw/u/jdl/86xx/u-boot-86xx/include/common.h" 1
# 30 "/proj/ppc/sysperf/sw/u/jdl/86xx/u-boot-86xx/include/common.h"
typedef unsigned char uchar;
typedef volatile unsigned long vu_long;
typedef volatile unsigned short vu_short;
typedef volatile unsigned char vu_char;
> Try running a current .dts through cpp today. You will get errors like:
>
> oftree.dts:15:3: error: invalid preprocessing directive #address
> Because of props like:
>
> #cpus = <1>;
> #address-cells = <1>;
> #size-cells = <0>;
>
> If these used some other symbol instead of '#' cpp will be happy and
> we can use it to create macros for us.
Yeah, we're not going to be able to change those; they
are "By The Book".
Instead, we'll have to make the lexical analysis conscious
of something like a <newline> context sensitive token or so.
Or throw some flag to cpp to not emit location markers.
Or something.
jdl
More information about the Linuxppc-dev
mailing list