Driver porting: compiling external modules
Posted Sep 2, 2004 20:30 UTC (Thu) by email@example.com
Parent article: Driver porting: compiling external modules
I've ported my CAN driver to Kernel 2.6.5 and I'm using the M=$(PWD) switch for making this external module. Now I got this output:
make -C /usr/src/linux M=/home/klaus/work/peak/peak-linux-driver/driver V=0 modules
make: Entering directory `/usr/src/linux-2.6.5-7.108'
CC [M] /home/klaus/work/peak/peak-linux-driver/driver/src/pcan_main.o
.... a lot more ...
CC [M] /home/klaus/work/peak/peak-linux-driver/driver/src/pcan_usb.o
LD [M] /home/klaus/work/peak/peak-linux-driver/driver/pcan.o
Building modules, stage 2.
Warning: could not find versions for .tmp_versions/pcan.mod
LD [M] /home/klaus/work/peak/peak-linux-driver/driver/pcan.ko
make: Leaving directory `/usr/src/linux-2.6.5-7.108'
I wondered about the line
"Warning: could not find versions for .tmp_versions/pcan.mod".
Some investigation shows that in my $(PWD) a directory .tmp_versions was created and the pcan.mod was stored in that directory. For any strange reason a part of modpost "sumversions.c" is looking for .tmp_versions/pcan.mod located at the base of the kernel source tree. The same happens with the SUBDIRS=$(PWD) syntax.
Does anyone have an idea what' wrong?
P.S. pcan.ko is generated and is works perfectly.
to post comments)