aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorVivek Gautam <gautam.vivek@samsung.com>2013-05-14 08:02:16 -0400
committerFelipe Balbi <balbi@ti.com>2013-05-15 10:26:00 -0400
commit1bc0d926895bf86cf2b848c5d02cb422e275bbbb (patch)
treebc9ca8ae76731d73b03af60008a7e9df8a26b60c /drivers/usb
parentfea77077d1623c6a8d586266cf55c2289360bea3 (diff)
usb: dwc3: Fix compilation break when building with USB_DWC3_DUAL_ROLE=y
The commit: 388e5c5 usb: dwc3: remove dwc3 dependency on host AND gadget breaks compilation when USB=y, USB_GADGET=m, USB_DWC3=y and USB_DWC3_DUAL_ROLE=y. drivers/built-in.o: In function `dwc3_gadget_giveback': drivers/usb/dwc3/gadget.c:271: undefined reference to `usb_gadget_unmap_request' drivers/built-in.o: In function `__dwc3_gadget_kick_transfer': drivers/usb/dwc3/gadget.c:1005: undefined reference to `usb_gadget_unmap_request' drivers/built-in.o: In function `__dwc3_gadget_ep_queue': drivers/usb/dwc3/gadget.c:1073: undefined reference to `usb_gadget_map_request' drivers/built-in.o: In function `dwc3_gadget_reset_interrupt': drivers/usb/dwc3/gadget.c:2165: undefined reference to `usb_gadget_set_state' drivers/built-in.o: In function `dwc3_gadget_init': drivers/usb/dwc3/gadget.c:2647: undefined reference to `usb_add_gadget_udc' drivers/built-in.o: In function `dwc3_gadget_exit': drivers/usb/dwc3/gadget.c:2681: undefined reference to `usb_del_gadget_udc' drivers/built-in.o: In function `__dwc3_ep0_do_control_data': drivers/usb/dwc3/ep0.c:929: undefined reference to `usb_gadget_map_request' drivers/usb/dwc3/ep0.c:906: undefined reference to `usb_gadget_map_request' drivers/built-in.o: In function `dwc3_ep0_set_config': drivers/usb/dwc3/ep0.c:575: undefined reference to `usb_gadget_set_state' drivers/built-in.o: In function `dwc3_ep0_set_address': drivers/usb/dwc3/ep0.c:520: undefined reference to `usb_gadget_set_state' drivers/usb/dwc3/ep0.c:522: undefined reference to `usb_gadget_set_state' drivers/built-in.o: In function `dwc3_ep0_set_config': drivers/usb/dwc3/ep0.c:556: undefined reference to `usb_gadget_set_state' Making changes similar to patch: 71a5e61 usb: chipidea: fix and improve dependencies if usb host or gadget support is built as module Let us limit the DWC3 mode to depend on corresponding usb-subsystem and USB_DWC3. Signed-off-by: Vivek Gautam <gautam.vivek@samsung.com> Cc: Felipe Balbi <balbi@ti.com> Cc: Fengguang Wu <fengguang.wu@intel.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/dwc3/Kconfig6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/usb/dwc3/Kconfig b/drivers/usb/dwc3/Kconfig
index ea5ee9c21c35..757aa18027d0 100644
--- a/drivers/usb/dwc3/Kconfig
+++ b/drivers/usb/dwc3/Kconfig
@@ -19,21 +19,21 @@ choice
19 19
20config USB_DWC3_HOST 20config USB_DWC3_HOST
21 bool "Host only mode" 21 bool "Host only mode"
22 depends on USB 22 depends on USB=y || USB=USB_DWC3
23 help 23 help
24 Select this when you want to use DWC3 in host mode only, 24 Select this when you want to use DWC3 in host mode only,
25 thereby the gadget feature will be regressed. 25 thereby the gadget feature will be regressed.
26 26
27config USB_DWC3_GADGET 27config USB_DWC3_GADGET
28 bool "Gadget only mode" 28 bool "Gadget only mode"
29 depends on USB_GADGET 29 depends on USB_GADGET=y || USB_GADGET=USB_DWC3
30 help 30 help
31 Select this when you want to use DWC3 in gadget mode only, 31 Select this when you want to use DWC3 in gadget mode only,
32 thereby the host feature will be regressed. 32 thereby the host feature will be regressed.
33 33
34config USB_DWC3_DUAL_ROLE 34config USB_DWC3_DUAL_ROLE
35 bool "Dual Role mode" 35 bool "Dual Role mode"
36 depends on (USB && USB_GADGET) 36 depends on ((USB=y || USB=USB_DWC3) && (USB_GADGET=y || USB_GADGET=USB_DWC3))
37 help 37 help
38 This is the default mode of working of DWC3 controller where 38 This is the default mode of working of DWC3 controller where
39 both host and gadget features are enabled. 39 both host and gadget features are enabled.