[U-Boot] [PATCH 1/6] usb: dwc3: Add dwc3_init/remove with DM_USB
Marek Vasut
marex at denx.de
Wed May 16 14:40:34 UTC 2018
On 05/16/2018 04:26 PM, Michal Simek wrote:
> From: Mugunthan V N <mugunthanvnm at ti.com>
>
> 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 at ti.com>
> (Remove dwc3-omap changes)
> Signed-off-by: Michal Simek <michal.simek at xilinx.com>
> ---
[...]
> diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h
> index cbe9850a0bda..ad16c9b7c46c 100644
> --- a/drivers/usb/dwc3/core.h
> +++ b/drivers/usb/dwc3/core.h
> @@ -712,7 +712,11 @@ struct dwc3 {
> /* device lock */
> spinlock_t lock;
>
> +#ifndef CONFIG_DM_USB
Shouldnt this be ifdef __UBOOT__ ?
> struct device *dev;
> +#else
> + struct udevice *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);
>
--
Best regards,
Marek Vasut
More information about the U-Boot
mailing list