Results 1 to 3 of 3
hi,
the usb module is giving the following error..
cc module.c -o module
module.c:53: error: variable `my_usb_driver' has initializer but incomplete type
module.c:55: error: unknown field `name' specified in initializer
...
- 07-05-2006 #1Just Joined!
- Join Date
- Feb 2005
- Posts
- 27
error in compiling usb driver
hi,
the usb module is giving the following error..
cc module.c -o module
module.c:53: error: variable `my_usb_driver' has initializer but incomplete type
module.c:55: error: unknown field `name' specified in initializer
module.c:55: warning: excess elements in struct initializer
module.c:55: warning: (near initialization for `my_usb_driver')
module.c:56: error: unknown field `probe' specified in initializer
module.c:56: warning: excess elements in struct initializer
module.c:56: warning: (near initialization for `my_usb_driver')
module.c:57: error: unknown field `disconnect' specified in initializer
module.c:57: warning: excess elements in struct initializer
module.c:57: warning: (near initialization for `my_usb_driver')
module.c:53: error: storage size of `my_usb_driver' isn't known
make: *** [module] Error 1
i have checked all the structure usb_driver is there in the usb.h file in linux/usb.h
my make file is as follows :-
obj-m := module.o
#KERNELDIR = /lib/modules/$(shell uname -r)/build
KERNELDIR = /lib/modules/2.6.13.1/build
#KERNELDIR = /usr/src/kernels/$(shell uname -r)/include
PWD := $(shell pwd)
default:
$(MAKE) -C $(KERNELDIR) M=$(PWD) module
- 07-05-2006 #2Just Joined!
- Join Date
- Jun 2006
- Posts
- 15
I can able to findout the solution, if u possible to give u'r source code....
- 07-09-2006 #3This often occurs when you use a structure as a type without a previous typedef, this is:
Originally Posted by recklinux
struct my_struct;
my_struct mi_var_struct;
I think you're missing something like this.
Best regards


Reply With Quote
