xref: /openbmc/linux/drivers/usb/musb/Kconfig (revision 744543c599c420bcddca08cd2e2713b82a008328)
1550a7375SFelipe Balbi#
2550a7375SFelipe Balbi# USB Dual Role (OTG-ready) Controller Drivers
3550a7375SFelipe Balbi# for silicon based on Mentor Graphics INVENTRA designs
4550a7375SFelipe Balbi#
5550a7375SFelipe Balbi
6550a7375SFelipe Balbi# (M)HDRC = (Multipoint) Highspeed Dual-Role Controller
7550a7375SFelipe Balbiconfig USB_MUSB_HDRC
8*744543c5SHans de Goede	tristate 'Inventra Highspeed Dual Role Controller (TI, ADI, AW, ...)'
9845c071bSEzequiel Garcia	depends on (USB || USB_GADGET)
10550a7375SFelipe Balbi	help
11550a7375SFelipe Balbi	  Say Y here if your system has a dual role high speed USB
12550a7375SFelipe Balbi	  controller based on the Mentor Graphics silicon IP.  Then
13550a7375SFelipe Balbi	  configure options to match your silicon and the board
14550a7375SFelipe Balbi	  it's being used with, including the USB peripheral role,
15550a7375SFelipe Balbi	  or the USB host role, or both.
16550a7375SFelipe Balbi
1757bfc0a7SPeter Meerwald	  Texas Instruments families using this IP include DaVinci
18a227fd7dSDavid Brownell	  (35x, 644x ...), OMAP 243x, OMAP 3, and TUSB 6010.
19550a7375SFelipe Balbi
20085ad406SBryan Wu	  Analog Devices parts using this IP include Blackfin BF54x,
21085ad406SBryan Wu	  BF525 and BF527.
22085ad406SBryan Wu
23*744543c5SHans de Goede	  Allwinner SoCs using this IP include A10, A13, A20, ...
24*744543c5SHans de Goede
25550a7375SFelipe Balbi	  If you do not know what this is, please say N.
26550a7375SFelipe Balbi
271376d92fSFelipe Balbi	  To compile this driver as a module, choose M here; the
281376d92fSFelipe Balbi	  module will be called "musb-hdrc".
29550a7375SFelipe Balbi
30c6bde9b5SFelipe Contrerasif USB_MUSB_HDRC
31c6bde9b5SFelipe Contreras
327c925546SFelipe Balbichoice
33b7b741eaSDaniel Mack	bool "MUSB Mode Selection"
34b7b741eaSDaniel Mack	default USB_MUSB_DUAL_ROLE if (USB && USB_GADGET)
35b7b741eaSDaniel Mack	default USB_MUSB_HOST if (USB && !USB_GADGET)
36b7b741eaSDaniel Mack	default USB_MUSB_GADGET if (!USB && USB_GADGET)
37b7b741eaSDaniel Mack
38b7b741eaSDaniel Mackconfig USB_MUSB_HOST
39b7b741eaSDaniel Mack	bool "Host only mode"
40845c071bSEzequiel Garcia	depends on USB=y || USB=USB_MUSB_HDRC
41b7b741eaSDaniel Mack	help
42b7b741eaSDaniel Mack	  Select this when you want to use MUSB in host mode only,
43b7b741eaSDaniel Mack	  thereby the gadget feature will be regressed.
44b7b741eaSDaniel Mack
45b7b741eaSDaniel Mackconfig USB_MUSB_GADGET
46b7b741eaSDaniel Mack	bool "Gadget only mode"
47845c071bSEzequiel Garcia	depends on USB_GADGET=y || USB_GADGET=USB_MUSB_HDRC
483f83e538SGeert Uytterhoeven	depends on HAS_DMA
49b7b741eaSDaniel Mack	help
50b7b741eaSDaniel Mack	  Select this when you want to use MUSB in gadget mode only,
51b7b741eaSDaniel Mack	  thereby the host feature will be regressed.
52b7b741eaSDaniel Mack
53b7b741eaSDaniel Mackconfig USB_MUSB_DUAL_ROLE
54b7b741eaSDaniel Mack	bool "Dual Role mode"
55845c071bSEzequiel Garcia	depends on ((USB=y || USB=USB_MUSB_HDRC) && (USB_GADGET=y || USB_GADGET=USB_MUSB_HDRC))
563f83e538SGeert Uytterhoeven	depends on HAS_DMA
57b7b741eaSDaniel Mack	help
58b7b741eaSDaniel Mack	  This is the default mode of working of MUSB controller where
59b7b741eaSDaniel Mack	  both host and gadget features are enabled.
60b7b741eaSDaniel Mack
61b7b741eaSDaniel Mackendchoice
62b7b741eaSDaniel Mack
6382c02f58STony Lindgrencomment "Platform Glue Layer"
64550a7375SFelipe Balbi
65*744543c5SHans de Goedeconfig USB_MUSB_SUNXI
66*744543c5SHans de Goede	tristate "Allwinner (sunxi)"
67*744543c5SHans de Goede	depends on ARCH_SUNXI
68*744543c5SHans de Goede	depends on NOP_USB_XCEIV
69*744543c5SHans de Goede	depends on PHY_SUN4I_USB
70*744543c5SHans de Goede	depends on EXTCON
71*744543c5SHans de Goede	depends on GENERIC_PHY
72*744543c5SHans de Goede	select SUNXI_SRAM
73*744543c5SHans de Goede
747c925546SFelipe Balbiconfig USB_MUSB_DAVINCI
751376d92fSFelipe Balbi	tristate "DaVinci"
767c925546SFelipe Balbi	depends on ARCH_DAVINCI_DMx
77a0cb12e2SArnd Bergmann	depends on NOP_USB_XCEIV
78787f5627SFelipe Balbi	depends on BROKEN
79550a7375SFelipe Balbi
807c925546SFelipe Balbiconfig USB_MUSB_DA8XX
811376d92fSFelipe Balbi	tristate "DA8xx/OMAP-L1x"
827c925546SFelipe Balbi	depends on ARCH_DAVINCI_DA8XX
83a0cb12e2SArnd Bergmann	depends on NOP_USB_XCEIV
84787f5627SFelipe Balbi	depends on BROKEN
853ee076deSSergei Shtylyov
867c925546SFelipe Balbiconfig USB_MUSB_TUSB6010
871376d92fSFelipe Balbi	tristate "TUSB6010"
88c0442479STony Lindgren	depends on ARCH_OMAP2PLUS || COMPILE_TEST
89c0442479STony Lindgren	depends on NOP_USB_XCEIV = USB_MUSB_HDRC # both built-in or both modules
90550a7375SFelipe Balbi
917c925546SFelipe Balbiconfig USB_MUSB_OMAP2PLUS
921376d92fSFelipe Balbi	tristate "OMAP2430 and onwards"
931c390eb3SArnd Bergmann	depends on ARCH_OMAP2PLUS && USB
941c390eb3SArnd Bergmann	depends on OMAP_CONTROL_PHY || !OMAP_CONTROL_PHY
953e3101d5SKishon Vijay Abraham I	select GENERIC_PHY
96085ad406SBryan Wu
97eb83092cSAjay Kumar Guptaconfig USB_MUSB_AM35X
981376d92fSFelipe Balbi	tristate "AM35x"
997c925546SFelipe Balbi	depends on ARCH_OMAP
100a0cb12e2SArnd Bergmann	depends on NOP_USB_XCEIV
101eb83092cSAjay Kumar Gupta
1029ecb8875SAjay Kumar Guptaconfig USB_MUSB_DSPS
1039ecb8875SAjay Kumar Gupta	tristate "TI DSPS platforms"
10497238b35SSebastian Andrzej Siewior	select USB_MUSB_AM335X_CHILD
105c0442479STony Lindgren	depends on ARCH_OMAP2PLUS || COMPILE_TEST
106eff196adSFelipe Balbi	depends on OF_IRQ
1079ecb8875SAjay Kumar Gupta
1087c925546SFelipe Balbiconfig USB_MUSB_BLACKFIN
1091376d92fSFelipe Balbi	tristate "Blackfin"
1107c925546SFelipe Balbi	depends on (BF54x && !BF544) || (BF52x && ! BF522 && !BF523)
111a0cb12e2SArnd Bergmann	depends on NOP_USB_XCEIV
1127c925546SFelipe Balbi
1134bc36fd3SMian Yousaf Kaukabconfig USB_MUSB_UX500
1141860c925SLinus Walleij	tristate "Ux500 platforms"
115c0442479STony Lindgren	depends on ARCH_U8500 || COMPILE_TEST
1164bc36fd3SMian Yousaf Kaukab
11710434d27SApelete Seketeliconfig USB_MUSB_JZ4740
11810434d27SApelete Seketeli	tristate "JZ4740"
119a0cb12e2SArnd Bergmann	depends on NOP_USB_XCEIV
12010434d27SApelete Seketeli	depends on MACH_JZ4740 || COMPILE_TEST
12110434d27SApelete Seketeli	depends on USB_MUSB_GADGET
12210434d27SApelete Seketeli	depends on USB_OTG_BLACKLIST_HUB
12310434d27SApelete Seketeli
12497238b35SSebastian Andrzej Siewiorconfig USB_MUSB_AM335X_CHILD
12597238b35SSebastian Andrzej Siewior	tristate
12697238b35SSebastian Andrzej Siewior
1272e7fc3baSArnd Bergmannchoice
1282e7fc3baSArnd Bergmann	prompt 'MUSB DMA mode'
12910434d27SApelete Seketeli	default MUSB_PIO_ONLY if ARCH_MULTIPLATFORM || USB_MUSB_JZ4740
1302e7fc3baSArnd Bergmann	default USB_UX500_DMA if USB_MUSB_UX500
1312e7fc3baSArnd Bergmann	default USB_INVENTRA_DMA if USB_MUSB_OMAP2PLUS || USB_MUSB_BLACKFIN
1322e7fc3baSArnd Bergmann	default USB_TI_CPPI_DMA if USB_MUSB_DAVINCI
1332e7fc3baSArnd Bergmann	default USB_TUSB_OMAP_DMA if USB_MUSB_TUSB6010
1349ecb8875SAjay Kumar Gupta	default MUSB_PIO_ONLY if USB_MUSB_TUSB6010 || USB_MUSB_DA8XX || USB_MUSB_AM35X \
1359ecb8875SAjay Kumar Gupta				|| USB_MUSB_DSPS
136550a7375SFelipe Balbi	help
1372e7fc3baSArnd Bergmann	  Unfortunately, only one option can be enabled here. Ideally one
1382e7fc3baSArnd Bergmann	  should be able to build all these drivers into one kernel to
1392e7fc3baSArnd Bergmann	  allow using DMA on multiplatform kernels.
140550a7375SFelipe Balbi
141d2389440SMian Yousaf Kaukabconfig USB_UX500_DMA
1421860c925SLinus Walleij	bool 'ST Ericsson Ux500'
1432e7fc3baSArnd Bergmann	depends on USB_MUSB_UX500
144d2389440SMian Yousaf Kaukab	help
145d2389440SMian Yousaf Kaukab	  Enable DMA transfers on UX500 platforms.
146d2389440SMian Yousaf Kaukab
147550a7375SFelipe Balbiconfig USB_INVENTRA_DMA
1482e7fc3baSArnd Bergmann	bool 'Inventra'
1492e7fc3baSArnd Bergmann	depends on USB_MUSB_OMAP2PLUS || USB_MUSB_BLACKFIN
150550a7375SFelipe Balbi	help
151550a7375SFelipe Balbi	  Enable DMA transfers using Mentor's engine.
152550a7375SFelipe Balbi
153550a7375SFelipe Balbiconfig USB_TI_CPPI_DMA
1542e7fc3baSArnd Bergmann	bool 'TI CPPI (Davinci)'
1552e7fc3baSArnd Bergmann	depends on USB_MUSB_DAVINCI
156550a7375SFelipe Balbi	help
157550a7375SFelipe Balbi	  Enable DMA transfers when TI CPPI DMA is available.
158550a7375SFelipe Balbi
1599b3452d1SSebastian Andrzej Siewiorconfig USB_TI_CPPI41_DMA
1609b3452d1SSebastian Andrzej Siewior	bool 'TI CPPI 4.1 (AM335x)'
1619b3452d1SSebastian Andrzej Siewior	depends on ARCH_OMAP
162411dd19cSGeorge Cherian	select TI_CPPI41
1639b3452d1SSebastian Andrzej Siewior
164550a7375SFelipe Balbiconfig USB_TUSB_OMAP_DMA
1652e7fc3baSArnd Bergmann	bool 'TUSB 6010'
16670c1ff4bSArnd Bergmann	depends on USB_MUSB_TUSB6010 = USB_MUSB_HDRC # both built-in or both modules
167550a7375SFelipe Balbi	depends on ARCH_OMAP
168550a7375SFelipe Balbi	help
169550a7375SFelipe Balbi	  Enable DMA transfers on TUSB 6010 when OMAP DMA is available.
170550a7375SFelipe Balbi
1712e7fc3baSArnd Bergmannconfig MUSB_PIO_ONLY
1722e7fc3baSArnd Bergmann	bool 'Disable DMA (always use PIO)'
1732e7fc3baSArnd Bergmann	help
1742e7fc3baSArnd Bergmann	  All data is copied between memory and FIFO by the CPU.
1752e7fc3baSArnd Bergmann	  DMA controllers are ignored.
1762e7fc3baSArnd Bergmann
1772e7fc3baSArnd Bergmann	  Do not choose this unless DMA support for your SOC or board
1782e7fc3baSArnd Bergmann	  is unavailable (or unstable).  When DMA is enabled at compile time,
1792e7fc3baSArnd Bergmann	  you can still disable it at run time using the "use_dma=n" module
1802e7fc3baSArnd Bergmann	  parameter.
1812e7fc3baSArnd Bergmann
1822e7fc3baSArnd Bergmannendchoice
183c6bde9b5SFelipe Contreras
184c6bde9b5SFelipe Contrerasendif # USB_MUSB_HDRC
185