Compiling Errors of map_funcs.c
Folks,
I try to enable support MTD device under MontaVista 3.1 for our Intel IXP425 demo board. However, I got some errors when compiling the MTD driver of the intel-ixdp4xx-arm_xscale_be Linux Support Package. I would appreciate it if you could give me some pointer. Below is what I did.
#make ixdp425_config // use default settings for IXP425
#make dep
#make zImage
<snip>
xscale_be-gcc -mbig-endian -D__KERNEL__ -I/home/banyan/mykernel/linux-2.4.20_mvl31/include -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -pipe -mapcs -mno-sched-prolog -mapcs-32 -D__LINUX_ARM_ARCH__=5 -mcpu=xscale -mtune=xscale -mshort-load-bytes -msoft-float -nostdinc -iwithprefix include -DKBUILD_BASENAME=ixp425 -c -o ixp425.o ixp425.c
ixp425.c:35:1: warning: "B0" redefined /home/banyan/mykernel/linux-2.4.20_mvl31/include/asm/termbits.h:88:1: warning: this is the location of the previous definition ixp425.c:75: error: unknown field `read16' specified in initializer
ixp425.c:75: warning: initialization from incompatible pointer type
ixp425.c:76: error: unknown field `copy_from' specified in initializer
ixp425.c:76: warning: initialization makes integer from pointer without a cast
ixp425.c:77: error: unknown field `write16' specified in initializer
ixp425.c:77: warning: initialization makes integer from pointer without a cast
ixp425.c:84: warning: return type defaults to `int'
make[4]: *** [ixp425.o] Error 1
I add "CONFIG_MTD_COMPLEX_MAPPINGS=y" into .config to enable the definition of the "read16", "copy_from" and etc. fields. And "make dep; make zImage" again.
xscale_be-gcc -mbig-endian -D__KERNEL__ -I/home/banyan/mykernel/linux-2.4.20_mvl31/include -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -pipe -mapcs -mno-sched-prolog -mapcs-32 -D__LINUX_ARM_ARCH__=5 -mcpu=xscale -mtune=xscale -mshort-load-bytes -msoft-float -nostdinc -iwithprefix include -DKBUILD_BASENAME=map_funcs -DEXPORT_SYMTAB -c map_funcs.c
map_funcs.c:81: error: parse error before "do"
map_funcs.c:95: error: simple_map_init' undeclared here (not in a function) map_funcs.c:95: error: initializer element is not constant map_funcs.c:95: error: (near initialization for __ksymtab_simple_map_init.value')
I can not figure out these errors, particularly line 81. Any comment and suggestion will be highly appreciated.
Regards,
Zhigao
Quoted 3 lines · Chen Zhigao
Folks,
I try to enable support MTD device under MontaVista 3.1 for our Intel IXP425 demo board.
You need to contact your MontaVista support channel for your problem. Those are old file versions of a kernel no longer supported here at linux-mtd, and no one here knows how to translate those line numbers to some previous version of the source code. If a supported IXP425 LSP cannot compile its supported mtd mapping driver then it's a bug in that product. I can give you a hint that your ixp425.c is apparently older than the rest of the mtd code and needs various mods to match the rest of the code.
Signature · 1 line
Todd