Commit 1dd33a9f authored by Linus Walleij's avatar Linus Walleij Committed by Greg Kroah-Hartman
Browse files

usb: fotg210: Collect pieces of dual mode controller



The Faraday FOTG210 is a dual-mode OTG USB controller that can
act as host, peripheral or both. To be able to probe from one
hardware description and to follow the pattern of other dual-
mode controllers such as MUSB or MTU3 we need to collect the
two, currently completely separate drivers in the same
directory.

After this, users need to select the main symbol USB_FOTG210
and then each respective subdriver. We pave the road to
compile both drivers into the same kernel and select the
one we want to use at probe() time, and possibly add OTG
support in the end.

This patch doesn't do much more than create the new symbol
and collect the drivers in one place. We also add a comment
for the section of dual-mode controllers in the Kconfig
file so people can see what these selections are about.

Also add myself as maintainer as there has been little
response on my patches to these drivers.

Cc: Fabian Vogt <fabian@ritter-vogt.de>
Cc: Yuan-Hsin Chen <yhchen@faraday-tech.com>
Cc: Felipe Balbi <balbi@kernel.org>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20221023144708.3596563-1-linus.walleij@linaro.org


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent c5edb757
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -7873,6 +7873,12 @@ F: fs/notify/fanotify/
F:	include/linux/fanotify.h
F:	include/uapi/linux/fanotify.h
FARADAY FOTG210 USB2 DUAL-ROLE CONTROLLER
M:	Linus Walleij <linus.walleij@linaro.org>
L:	linux-usb@vger.kernel.org
S:	Maintained
F:	drivers/usb/fotg210/
FARSYNC SYNCHRONOUS DRIVER
M:	Kevin Curtis <kevin.curtis@farsite.co.uk>
S:	Supported
+4 −0
Original line number Diff line number Diff line
@@ -111,8 +111,12 @@ source "drivers/usb/usbip/Kconfig"

endif

comment "USB dual-mode controller drivers"

source "drivers/usb/cdns3/Kconfig"

source "drivers/usb/fotg210/Kconfig"

source "drivers/usb/mtu3/Kconfig"

source "drivers/usb/musb/Kconfig"
+2 −0
Original line number Diff line number Diff line
@@ -17,6 +17,8 @@ obj-$(CONFIG_USB_CDNS_SUPPORT) += cdns3/
obj-$(CONFIG_USB_CDNS3)		+= cdns3/
obj-$(CONFIG_USB_CDNSP_PCI)	+= cdns3/

obj-$(CONFIG_USB_FOTG210)	+= fotg210/

obj-$(CONFIG_USB_MON)		+= mon/
obj-$(CONFIG_USB_MTU3)		+= mtu3/

+36 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0

config USB_FOTG210
	tristate "Faraday FOTG210 USB2 Dual Role controller"
	depends on USB || USB_GADGET
	depends on HAS_DMA && HAS_IOMEM
	default ARCH_GEMINI
	help
	  Faraday FOTG210 is a dual-mode USB controller that can act
	  in both host controller and peripheral controller mode.

if USB_FOTG210

config USB_FOTG210_HCD
	tristate "Faraday FOTG210 USB Host Controller support"
	depends on USB
	help
	  Faraday FOTG210 is an OTG controller which can be configured as
	  an USB2.0 host. It is designed to meet USB2.0 EHCI specification
	  with minor modification.

	  To compile this driver as a module, choose M here: the
	  module will be called fotg210-hcd.

config USB_FOTG210_UDC
	depends on USB_GADGET
	tristate "Faraday FOTG210 USB Peripheral Controller support"
	help
	   Faraday USB2.0 OTG controller which can be configured as
	   high speed or full speed USB device. This driver suppports
	   Bulk Transfer so far.

	   Say "y" to link the driver statically, or "m" to build a
	   dynamically linked module called "fotg210-udc".

endif
+3 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0
obj-$(CONFIG_USB_FOTG210_HCD)	+= fotg210-hcd.o
obj-$(CONFIG_USB_FOTG210_UDC)	+= fotg210-udc.o
Loading