Reputation: 1
I'am trying to compile the wifi driver into the linux kernel:
https://github.com/McMCCRU/rtl8188gu
https://github.com/OpenStick/linux
I know little about how to compile drivers into kernel, so I can only add "source .../Kconfig" to an existing Kconfig and "obj-y += .../" to an existing Makefile, however that made no difference - the driver seemed to be non-existent. What shall I do?
I want to get this driver compiled as a module at least. Anyway, I need to make my rtl8188gu work.
Upvotes: 0
Views: 838
Reputation: 72
Put your files in some directory, for example in drivers/net/wireless/your-directory.
In drivers/net/wireless/Kconfig add something like:
config YOUR_DRIVER
tristate "Driver for this and that"
depends on NET
help
If you are unsure, say N.
Notice: you should not add CONFIG_ prefix here
In drivers/net/wireless/Makefile add:
obj-$(CONFIG_YOUR_DRIVER) += /your-directory/
In drivers/net/wireless/your-directory/Makefile add (assuming your source file is your-driver.c):
obj-$(CONFIG_YOUR_DRIVER) += your-driver.o
make menuconfig, select your driver in Device Drivers -> Network device support -> Wireless LAN, or set
CONFIG_YOUR_DRIVER to "y"/"m" manually.
These are common steps. Drivers you're interested in are much more complicated. So you'll need to spend some time to build them inside of source tree. You can relay on Makefiles provided by repositories.
Upvotes: 0