summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2016-04-20 09:31:58 -0400
committerTom Rini <trini@konsulko.com>2016-04-20 09:31:58 -0400
commiteb6b50f631628f48b7e72432ae878e6ff0e306c3 (patch)
tree40a37edba62f5769156b543ea7a5e9c9377d5a15 /drivers
parentec3ab3f9b5c75b5a11f8f6f52951fa8dd45990be (diff)
parente6c0bc0643e5a4387fecbcf83080d0b796eb067c (diff)
downloadu-boot-imx-eb6b50f631628f48b7e72432ae878e6ff0e306c3.zip
u-boot-imx-eb6b50f631628f48b7e72432ae878e6ff0e306c3.tar.gz
u-boot-imx-eb6b50f631628f48b7e72432ae878e6ff0e306c3.tar.bz2
Merge branch 'master' of git://git.denx.de/u-boot-usb
Conflicts: configs/bcm28155_ap_defconfig configs/dra72_evm_defconfig configs/dra74_evm_defconfig configs/ma5d4evk_defconfig Signed-off-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/Kconfig2
-rw-r--r--drivers/usb/dwc3/Kconfig57
-rw-r--r--drivers/usb/gadget/Kconfig67
-rw-r--r--drivers/usb/gadget/g_dnl.c6
-rw-r--r--drivers/usb/musb-new/Kconfig1
5 files changed, 130 insertions, 3 deletions
diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig
index bccf43e..da3ec2f 100644
--- a/drivers/usb/Kconfig
+++ b/drivers/usb/Kconfig
@@ -49,6 +49,8 @@ config DM_USB
source "drivers/usb/host/Kconfig"
+source "drivers/usb/dwc3/Kconfig"
+
source "drivers/usb/musb-new/Kconfig"
source "drivers/usb/emul/Kconfig"
diff --git a/drivers/usb/dwc3/Kconfig b/drivers/usb/dwc3/Kconfig
new file mode 100644
index 0000000..e93398f
--- /dev/null
+++ b/drivers/usb/dwc3/Kconfig
@@ -0,0 +1,57 @@
+config USB_DWC3
+ bool "DesignWare USB3 DRD Core Support"
+ depends on (USB && USB_GADGET)
+ select USB_GADGET_DUALSPEED
+ help
+ Say Y here if your system has a Dual Role SuperSpeed
+ USB controller based on the DesignWare USB3 IP Core.
+
+if USB_DWC3
+
+choice
+ bool "DWC3 Mode Selection"
+
+config USB_DWC3_HOST
+ bool "Host only mode"
+ depends on USB
+ help
+ Select this when you want to use DWC3 in host mode only,
+ thereby the gadget feature will be regressed.
+
+config USB_DWC3_GADGET
+ bool "Gadget only mode"
+ depends on USB_GADGET
+ help
+ Select this when you want to use DWC3 in gadget mode only,
+ thereby the host feature will be regressed.
+
+endchoice
+
+comment "Platform Glue Driver Support"
+
+config USB_DWC3_OMAP
+ bool "Texas Instruments OMAP5 and similar Platforms"
+ help
+ Some platforms from Texas Instruments like OMAP5, DRA7xxx and
+ AM437x use this IP for USB2/3 functionality.
+
+ Say 'Y' here if you have one such device
+
+menu "PHY Subsystem"
+
+config USB_DWC3_PHY_OMAP
+ bool "TI OMAP SoC series USB DRD PHY driver"
+ help
+ Enable single driver for both USB2 PHY programming and USB3 PHY
+ programming for TI SoCs.
+
+config USB_DWC3_PHY_SAMSUNG
+ bool "Exynos5 SoC series USB DRD PHY driver"
+ help
+ Enable USB DRD PHY support for Exynos 5 SoC series.
+ This driver provides PHY interface for USB 3.0 DRD controller
+ present on Exynos5 SoC series.
+
+endmenu
+
+endif
diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
index f4698f4..a35a1c7 100644
--- a/drivers/usb/gadget/Kconfig
+++ b/drivers/usb/gadget/Kconfig
@@ -33,3 +33,70 @@ menuconfig USB_GADGET
a USB peripheral device. Configure one hardware driver for your
peripheral/device side bus controller, and a "gadget driver" for
your peripheral protocol.
+
+if USB_GADGET
+
+config USB_GADGET_ATMEL_USBA
+ bool "Atmel USBA"
+ select USB_GADGET_DUALSPEED
+ help
+ USBA is the integrated high-speed USB Device controller on
+ the AT32AP700x, some AT91SAM9 and AT91CAP9 processors from Atmel.
+
+config USB_GADGET_DWC2_OTG
+ bool "DesignWare USB2.0 HS OTG controller (gadget mode)"
+ select USB_GADGET_DUALSPEED
+ help
+ The Designware USB2.0 high-speed gadget controller
+ integrated into many SoCs. Select this option if you want the
+ driver to operate in Peripheral mode. This option requires
+ USB_GADGET to be enabled.
+
+config CI_UDC
+ bool "ChipIdea device controller"
+ select USB_GADGET_DUALSPEED
+ help
+ Say Y here to enable device controller functionality of the
+ ChipIdea driver.
+
+config USB_GADGET_VBUS_DRAW
+ int "Maximum VBUS Power usage (2-500 mA)"
+ range 2 500
+ default 2
+ help
+ Some devices need to draw power from USB when they are
+ configured, perhaps to operate circuitry or to recharge
+ batteries. This is in addition to any local power supply,
+ such as an AC adapter or batteries.
+
+ Enter the maximum power your device draws through USB, in
+ milliAmperes. The permitted range of values is 2 - 500 mA;
+ 0 mA would be legal, but can make some hosts misbehave.
+
+ This value will be used except for system-specific gadget
+ drivers that have more specific information.
+
+# Selected by UDC drivers that support high-speed operation.
+config USB_GADGET_DUALSPEED
+ bool
+
+config USB_GADGET_DOWNLOAD
+ bool "Enable USB download gadget"
+ help
+ Composite USB download gadget support (g_dnl) for download functions.
+ This code works on top of composite gadget.
+
+if USB_GADGET_DOWNLOAD
+
+config G_DNL_MANUFACTURER
+ string "Vendor name of USB device"
+
+config G_DNL_VENDOR_NUM
+ hex "Vendor ID of USB device"
+
+config G_DNL_PRODUCT_NUM
+ hex "Product ID of USB device"
+
+endif # USB_GADGET_DOWNLOAD
+
+endif # USB_GADGET
diff --git a/drivers/usb/gadget/g_dnl.c b/drivers/usb/gadget/g_dnl.c
index 2fa6da4..45a484c 100644
--- a/drivers/usb/gadget/g_dnl.c
+++ b/drivers/usb/gadget/g_dnl.c
@@ -27,7 +27,7 @@
* CONFIG_G_DNL_VENDOR_NUM
* CONFIG_G_DNL_PRODUCT_NUM
* CONFIG_G_DNL_MANUFACTURER
- * at e.g. ./include/configs/<board>.h
+ * at e.g. ./configs/<board>_defconfig
*/
#define STRING_MANUFACTURER 25
@@ -58,8 +58,8 @@ static struct usb_device_descriptor device_desc = {
.bDescriptorType = USB_DT_DEVICE,
.bcdUSB = __constant_cpu_to_le16(0x0200),
- .bDeviceClass = USB_CLASS_COMM,
- .bDeviceSubClass = 0x02, /*0x02:CDC-modem , 0x00:CDC-serial*/
+ .bDeviceClass = USB_CLASS_PER_INTERFACE,
+ .bDeviceSubClass = 0, /*0x02:CDC-modem , 0x00:CDC-serial*/
.idVendor = __constant_cpu_to_le16(CONFIG_G_DNL_VENDOR_NUM),
.idProduct = __constant_cpu_to_le16(CONFIG_G_DNL_PRODUCT_NUM),
diff --git a/drivers/usb/musb-new/Kconfig b/drivers/usb/musb-new/Kconfig
index 4e8a543..c264859 100644
--- a/drivers/usb/musb-new/Kconfig
+++ b/drivers/usb/musb-new/Kconfig
@@ -10,6 +10,7 @@ config USB_MUSB_HOST
config USB_MUSB_GADGET
bool "MUSB gadget mode support"
+ select USB_GADGET_DUALSPEED
help
Enables the MUSB USB dual-role controller in gadget mode.