From: Luis R. Rodriguez Date: Wed, 5 Aug 2009 16:27:55 +0000 (-0700) Subject: Use obj-m for drivers/net/wireless/ to support driver-select X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=049d8845bf36b4d0805ab8c6014b9357a17fe2ce;p=openwrt%2Fstaging%2Fblogic.git Use obj-m for drivers/net/wireless/ to support driver-select The script ./scripts/driver-select allows you to enable only one wireless driver or a select group of wireless drivers on drivers/net/wireless/ . When using driver-select you can opt out to *not* provide a driver being built in to the directory drivers/net/wireless/ but instead to a child directory, example would be to enable ATH_COMMON which only enables modules within drivers/net/wireless/ath/ and nothing in drivers/net/wireless/ . When building external kernel modules obj-y enabled directories will build a built-in.o file only if at least one module was enabled in that directory. Traditionally the kernel will also build empty built-in.o files on empty directories. Since running 'make' instead of 'make modules' makes no sense for external modules we cannot build a built-in.o on drivers/net/wireless/ by using oby-y and only enabling modules on children directories, say on drivers/net/wireless/ath/. Doing this in-kernel (only selecting ATH_COMMON) *does* work as a first pass 'make' would have built the empty drivers/net/wireless/built-in.o but for external modules this is not the case. To fix this for compat-wireless then use oby-m for drivers/net/wireless/ driver-select now works. Signed-off-by: Luis R. Rodriguez --- diff --git a/Makefile b/Makefile index 6fda3f4df76a..41a3c97f0905 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,7 @@ NOSTDINC_FLAGS := -I$(M)/include/ -include $(M)/include/net/compat.h $(CFLAGS) obj-y := net/wireless/ net/mac80211/ net/rfkill/ ifeq ($(ONLY_CORE),) -obj-y += \ +obj-m += \ drivers/ssb/ \ drivers/misc/eeprom/ \ drivers/net/usb/ \