Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 54f034f4 authored by Jack Pham's avatar Jack Pham
Browse files

usb: gadget: Allow f_rndis and f_gsi to coexist as modules



Currently the make targets for CONFIG_USB_F_RNDIS and
CONFIG_USB_F_GSI both include rndis.o. This would work if only
one is enabled, or both are enabled as =Y as rndis.o will get
linked into the vmlinux image once. Otherwise if both are
enabled with at least one as a module, it results in a module
load failure due to duplicate symbols.

A simple fix for this is to let the usb_f_gsi.o module only
include rndis.o if CONFIG_USB_F_RNDIS is disabled.

Change-Id: Id5b96aaa9a728aa26a65b2c66f2341d6e2fb786b
Signed-off-by: default avatarJack Pham <jackp@codeaurora.org>
parent 15d3aa2e
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -62,5 +62,8 @@ usb_f_ccid-y := f_ccid.o
obj-$(CONFIG_USB_F_CCID)	+= usb_f_ccid.o
usb_f_cdev-y			:= f_cdev.o
obj-$(CONFIG_USB_F_CDEV)	+= usb_f_cdev.o
usb_f_gsi-y			:= f_gsi.o rndis.o
usb_f_gsi-y			:= f_gsi.o
ifeq ($(CONFIG_USB_F_RNDIS),)
usb_f_gsi-y			+= rndis.o
endif
obj-$(CONFIG_USB_F_GSI)		+= usb_f_gsi.o