summaryrefslogtreecommitdiff
path: root/drivers/usb/dwc3/core.h
diff options
context:
space:
mode:
authorMugunthan V N <mugunthanvnm@ti.com>2018-05-18 14:15:04 +0300
committerMarek Vasut <marex@denx.de>2018-05-18 14:23:10 +0300
commit23ba2d6372e45479106922c6241a7a09707bbe08 (patch)
treeadcd0f130d98ec85c3cc090a1193bedea0c29632 /drivers/usb/dwc3/core.h
parent3b29121678241078ce08120e18108898ff3b7abd (diff)
downloadu-boot-23ba2d6372e45479106922c6241a7a09707bbe08.tar.xz
usb: dwc3: Add dwc3_init/remove with DM_USB
The patch is preparing dwc3 core for enabling DM_USB with peripheral driver with using driver model support. The driver will be bound by the DWC3 wrapper driver based on the dr_mode device tree entry. Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com> (Remove dwc3-omap changes) Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'drivers/usb/dwc3/core.h')
-rw-r--r--drivers/usb/dwc3/core.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h
index cbe9850a0b..58fe91dc51 100644
--- a/drivers/usb/dwc3/core.h
+++ b/drivers/usb/dwc3/core.h
@@ -712,7 +712,11 @@ struct dwc3 {
/* device lock */
spinlock_t lock;
+#if defined(__UBOOT__) && defined(CONFIG_DM_USB)
+ struct udevice *dev;
+#else
struct device *dev;
+#endif
struct platform_device *xhci;
struct resource xhci_resources[DWC3_XHCI_RESOURCES_NUM];
@@ -987,6 +991,8 @@ struct dwc3_gadget_ep_cmd_params {
/* prototypes */
int dwc3_gadget_resize_tx_fifos(struct dwc3 *dwc);
+int dwc3_init(struct dwc3 *dwc);
+void dwc3_remove(struct dwc3 *dwc);
#ifdef CONFIG_USB_DWC3_HOST
int dwc3_host_init(struct dwc3 *dwc);