Hoping some someone on this board can help.
I'm trying to backport the stack to linux 2.4.25 for use with the gp2x console.
I've got some of the modules compiled for the 2.4 kernel, however some of the files for the wireless lan sample driver are giving me trouble.
In particular the compiler (ver 2.95.3) is reporting errors in file drivers/sdio/function/wlan/ar6000/hif/hif.c :
arm-linux-gcc -D__KERNEL__ -I/home/sandbox/projects/code/gp2xsdk/work/kernel/2.0.0/include -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -fno-common -pipe -mapcs-32 -D__LINUX_ARM_ARCH__=4 -march=armv4 -mtune=arm9tdmi -mshort-load-bytes -msoft-float -Uarm -DMODULE -nostdinc -iwithprefix include -DKBUILD_BASENAME=hif -c -o hif.o hif.c
hif.c:54: unknown field `Version' specified in initializer
hif.c:54: warning: missing braces around initializer
hif.c:54: warning: (near initialization for `FunctionContext.function')
hif.c:55: unknown field `function' specified in initializer
hif.c:56: unknown field `function' specified in initializer
hif.c:57: unknown field `function' specified in initializer
hif.c:58: unknown field `function' specified in initializer
hif.c:59: unknown field `function' specified in initializer
hif.c:60: unknown field `function' specified in initializer
hif.c:61: unknown field `function' specified in initializer
hif.c:62: unknown field `function' specified in initializer
hif.c:63: unknown field `function' specified in initializer
hif.c:64: unknown field `function' specified in initializer
make[6]: *** [hif.o] Error 1
---------------------------
the section in hif.c looks like this:
TARGET_FUNCTION_CONTEXT FunctionContext = {
.function.Version = CT_SDIO_STACK_VERSION_CODE,
.function.pName = "sdio_wlan",
.function.MaxDevices = 1,
.function.NumDevices = 0,
.function.pIds = Ids,
.function.pProbe = hifDeviceInserted,
.function.pRemove = hifDeviceRemoved,
.function.pSuspend = NULL,
.function.pResume = NULL,
.function.pWake = NULL,
.function.pContext = &FunctionContext,
};
----------------
TARGET_FUNCTION_CONTEXT is defined is a local header file as:
typedef struct target_function_context {
SDFUNCTION function; /* function description of the bus driver */
OS_SEMAPHORE instanceSem; /* instance lock. Unused */
SDLIST instanceList; /* list of instances. Unused */
} TARGET_FUNCTION_CONTEXT;
-----------------
It looks like thee issue is gcc version related, as a newer gcc version 3.4.6 seems to get past this point. Of course these modules wont load with the stock gp2x kernel.
Any ideas on how to rewrite this section appreciated.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
It looks like your compiler version doesn't handle the depth of structure initialization with .name.name format. You will probbaly have to make the iniialization explicit and use extra curly braces. The stack has been run on various 2.4.20 platforms.
Paul
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hoping some someone on this board can help.
I'm trying to backport the stack to linux 2.4.25 for use with the gp2x console.
I've got some of the modules compiled for the 2.4 kernel, however some of the files for the wireless lan sample driver are giving me trouble.
In particular the compiler (ver 2.95.3) is reporting errors in file drivers/sdio/function/wlan/ar6000/hif/hif.c :
arm-linux-gcc -D__KERNEL__ -I/home/sandbox/projects/code/gp2xsdk/work/kernel/2.0.0/include -Wall -Wstrict-prototypes -Wno-trigraphs -Os -fno-strict-aliasing -fno-common -Uarm -fno-common -pipe -mapcs-32 -D__LINUX_ARM_ARCH__=4 -march=armv4 -mtune=arm9tdmi -mshort-load-bytes -msoft-float -Uarm -DMODULE -nostdinc -iwithprefix include -DKBUILD_BASENAME=hif -c -o hif.o hif.c
hif.c:54: unknown field `Version' specified in initializer
hif.c:54: warning: missing braces around initializer
hif.c:54: warning: (near initialization for `FunctionContext.function')
hif.c:55: unknown field `function' specified in initializer
hif.c:56: unknown field `function' specified in initializer
hif.c:57: unknown field `function' specified in initializer
hif.c:58: unknown field `function' specified in initializer
hif.c:59: unknown field `function' specified in initializer
hif.c:60: unknown field `function' specified in initializer
hif.c:61: unknown field `function' specified in initializer
hif.c:62: unknown field `function' specified in initializer
hif.c:63: unknown field `function' specified in initializer
hif.c:64: unknown field `function' specified in initializer
make[6]: *** [hif.o] Error 1
---------------------------
the section in hif.c looks like this:
TARGET_FUNCTION_CONTEXT FunctionContext = {
.function.Version = CT_SDIO_STACK_VERSION_CODE,
.function.pName = "sdio_wlan",
.function.MaxDevices = 1,
.function.NumDevices = 0,
.function.pIds = Ids,
.function.pProbe = hifDeviceInserted,
.function.pRemove = hifDeviceRemoved,
.function.pSuspend = NULL,
.function.pResume = NULL,
.function.pWake = NULL,
.function.pContext = &FunctionContext,
};
----------------
TARGET_FUNCTION_CONTEXT is defined is a local header file as:
typedef struct target_function_context {
SDFUNCTION function; /* function description of the bus driver */
OS_SEMAPHORE instanceSem; /* instance lock. Unused */
SDLIST instanceList; /* list of instances. Unused */
} TARGET_FUNCTION_CONTEXT;
-----------------
It looks like thee issue is gcc version related, as a newer gcc version 3.4.6 seems to get past this point. Of course these modules wont load with the stock gp2x kernel.
Any ideas on how to rewrite this section appreciated.
It looks like your compiler version doesn't handle the depth of structure initialization with .name.name format. You will probbaly have to make the iniialization explicit and use extra curly braces. The stack has been run on various 2.4.20 platforms.
Paul