Skip to contentSkip to conversation

staging: emxx_udc: allow modular build

PATCH Superseded Arnd Bergmann 1 participant 2 messages Jun 22, 2016 – Jun 23, 2016 Staging

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: emxx_udc: allow modular build

A change to the usb gadget core allowed certain API functions to be part of a loadable module, which breaks having emxx_udc built-in:

drivers/staging/built-in.o: In function `nbu2ss_drv_probe':
(.text+0x2428): undefined reference to `usb_ep_set_maxpacket_limit'

The original patch already fixed tons of other cases that have the added dependency but apparently missed this one that now appears in an ARM allmodconfig build.

This patch makes the symbol "tristate", which lets the Kconfig dependency tracking handle it correctly.

Fixes 5a8d651a2bde ("usb: gadget: move gadget API functions to udc-core")
---
 drivers/staging/emxx_udc/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/emxx_udc/Kconfig +1 -1
index cc3402020487..d7577096fb25 100644
@@ -1,5 +1,5 @@
 config USB_EMXX
-	bool "EMXX USB Function Device Controller"
+	tristate "EMXX USB Function Device Controller"
  	depends on USB_GADGET && (ARCH_SHMOBILE || (ARM && COMPILE_TEST))
 	help
 	   The Emma Mobile series of SoCs from Renesas Electronics and
Signature · 1 line
2.9.0
#1 lore raw
Quoted 25 lines · CEST Arnd Bergmann

A change to the usb gadget core allowed certain API functions to be part of a loadable module, which breaks having emxx_udc built-in:

drivers/staging/built-in.o: In function `nbu2ss_drv_probe':
(.text+0x2428): undefined reference to `usb_ep_set_maxpacket_limit'

The original patch already fixed tons of other cases that have the added dependency but apparently missed this one that now appears in an ARM allmodconfig build.

This patch makes the symbol "tristate", which lets the Kconfig dependency tracking handle it correctly.

Fixes 5a8d651a2bde ("usb: gadget: move gadget API functions to udc-core")
---
 drivers/staging/emxx_udc/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/emxx_udc/Kconfig +0 -0
index cc3402020487..d7577096fb25 100644

drivers/staging/emxx_udc/Kconfig line 5

Quoted 6 lines
drivers/staging/emxx_udc/Kconfig +1 -1
@@ -1,5 +1,5 @@
 config USB_EMXX
-	bool "EMXX USB Function Device Controller"
+	tristate "EMXX USB Function Device Controller"
  	depends on USB_GADGET && (ARCH_SHMOBILE || (ARM && COMPILE_TEST))
 	help
 	   The Emma Mobile series of SoCs from Renesas Electronics and

I ran into another build error in some configrations, please disregard this one and use v2 instead.

Arnd