I have Makefile like this:
obj-m += some_kernel_module.o all: make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules clean: make -C /lib/module