aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/musb/Makefile
diff options
context:
space:
mode:
authorDaniel Mack <zonque@gmail.com>2013-04-10 21:55:46 +0200
committerFelipe Balbi <balbi@ti.com>2013-05-28 19:22:23 +0300
commitb7b741ea38a32336b45870b76aaec1abe57badd0 (patch)
tree10d48d17c988e5f6b6743bd3d6eb97f9bc0e0679 /drivers/usb/musb/Makefile
parentusb: musb: factor out hcd initalization (diff)
downloadlinux-dev-b7b741ea38a32336b45870b76aaec1abe57badd0.tar.xz
linux-dev-b7b741ea38a32336b45870b76aaec1abe57badd0.zip
usb: musb: add Kconfig options for HOST, GAGDET or DUAL_ROLE modes
This makes building the actual object files optional to the selected mode, which saves users who know which kind of USB mode support they need some binary size. Unimplemented functions are stubbed out with static inline functions. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/musb/Makefile')
-rw-r--r--drivers/usb/musb/Makefile4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/musb/Makefile b/drivers/usb/musb/Makefile
index 3b858715b5ea..2b82ed7c85ca 100644
--- a/drivers/usb/musb/Makefile
+++ b/drivers/usb/musb/Makefile
@@ -6,8 +6,8 @@ obj-$(CONFIG_USB_MUSB_HDRC) += musb_hdrc.o
musb_hdrc-y := musb_core.o
-musb_hdrc-y += musb_gadget_ep0.o musb_gadget.o
-musb_hdrc-y += musb_virthub.o musb_host.o
+musb_hdrc-$(CONFIG_USB_MUSB_HOST)$(CONFIG_USB_MUSB_DUAL_ROLE) += musb_virthub.o musb_host.o
+musb_hdrc-$(CONFIG_USB_MUSB_GADGET)$(CONFIG_USB_MUSB_DUAL_ROLE) += musb_gadget_ep0.o musb_gadget.o
musb_hdrc-$(CONFIG_DEBUG_FS) += musb_debugfs.o
# Hardware Glue Layer