usb: cdns3: Moves reusable code to separate module

Patch moves common reusable code used by cdns3 and cdnsp driver
to cdns-usb-common library. This library include core.c, drd.c
and host.c files.

Signed-off-by: Pawel Laszczak <pawell@cadence.com>
Tested-by: Aswath Govindraju <a-govindraju@ti.com>
Signed-off-by: Peter Chen <peter.chen@nxp.com>
This commit is contained in:
Pawel Laszczak
2020-12-07 11:32:20 +01:00
committed by Peter Chen
parent f738957277
commit 394c3a144d
6 changed files with 35 additions and 7 deletions

View File

@@ -1,8 +1,15 @@
config CDNS_USB_COMMON
tristate
config CDNS_USB_HOST
bool
config USB_CDNS3
tristate "Cadence USB3 Dual-Role Controller"
depends on USB_SUPPORT && (USB || USB_GADGET) && HAS_DMA
select USB_XHCI_PLATFORM if USB_XHCI_HCD
select USB_ROLE_SWITCH
select CDNS_USB_COMMON
help
Say Y here if your system has a Cadence USB3 dual-role controller.
It supports: dual-role switch, Host-only, and Peripheral-only.
@@ -25,6 +32,7 @@ config USB_CDNS3_GADGET
config USB_CDNS3_HOST
bool "Cadence USB3 host controller"
depends on USB=y || USB=USB_CDNS3
select CDNS_USB_HOST
help
Say Y here to enable host controller functionality of the
Cadence driver.