Btw, I should add that I'm no expert when it comes to developing/compiling kernel modules, however I must state that your Makefile look overly complex compared to one that I use for a kernel module. My Makefile looks like:
Code:
obj-m += my-module.o
I build the module running this command:
Code:
make -C /lib/modules/`uname -r`/build M=`pwd`
For this to work, I must be in the directory where the source code of my kernel module and the Makefile (shown above) exists.