[PATCH v8 5/9] usb: add MediaTek USB3 DRD driver

Bin Meng bmeng.cn at gmail.com
Wed Oct 14 10:04:38 CEST 2020


On Wed, Oct 14, 2020 at 3:08 PM Chunfeng Yun <chunfeng.yun at mediatek.com> wrote:
>
> This patch adds support for the MediaTek USB3 DRD controller,
> its host side is based on xHCI, this driver supports device mode
> and host mode.
>
> Signed-off-by: Chunfeng Yun <chunfeng.yun at mediatek.com>
> ---
> v8: Simplify Kconfig suggested by Bin
>
> v7: use xhci quirk flag XHCI_MTK_HOST
>
> v6: no changes
>
> v5: change condition of readl_poll_timeout() when check clocks
>
> v4:
>     1. remove unused member @busy and @wedged, use their flags instead
>     2. support force_vbus mode
>     3. add a glue driver using UCLASS_NOP
>     4. add host driver, and rebuild host flow
>
> v3 changes
>     1. add ->udc_set_speed()
>     2. simplify some code flow
>
> v2: simplify QMU operations
> ---
>  Makefile                           |   1 +
>  drivers/usb/Kconfig                |   2 +
>  drivers/usb/mtu3/Kconfig           |  44 ++
>  drivers/usb/mtu3/Makefile          |  11 +
>  drivers/usb/mtu3/mtu3.h            | 423 +++++++++++++
>  drivers/usb/mtu3/mtu3_core.c       | 838 ++++++++++++++++++++++++++
>  drivers/usb/mtu3/mtu3_dr.h         |  52 ++
>  drivers/usb/mtu3/mtu3_gadget.c     | 686 +++++++++++++++++++++
>  drivers/usb/mtu3/mtu3_gadget_ep0.c | 933 +++++++++++++++++++++++++++++
>  drivers/usb/mtu3/mtu3_host.c       | 141 +++++
>  drivers/usb/mtu3/mtu3_hw_regs.h    | 515 ++++++++++++++++
>  drivers/usb/mtu3/mtu3_plat.c       | 368 ++++++++++++
>  drivers/usb/mtu3/mtu3_qmu.c        | 504 ++++++++++++++++
>  drivers/usb/mtu3/mtu3_qmu.h        |  37 ++
>  14 files changed, 4555 insertions(+)
>  create mode 100644 drivers/usb/mtu3/Kconfig
>  create mode 100644 drivers/usb/mtu3/Makefile
>  create mode 100644 drivers/usb/mtu3/mtu3.h
>  create mode 100644 drivers/usb/mtu3/mtu3_core.c
>  create mode 100644 drivers/usb/mtu3/mtu3_dr.h
>  create mode 100644 drivers/usb/mtu3/mtu3_gadget.c
>  create mode 100644 drivers/usb/mtu3/mtu3_gadget_ep0.c
>  create mode 100644 drivers/usb/mtu3/mtu3_host.c
>  create mode 100644 drivers/usb/mtu3/mtu3_hw_regs.h
>  create mode 100644 drivers/usb/mtu3/mtu3_plat.c
>  create mode 100644 drivers/usb/mtu3/mtu3_qmu.c
>  create mode 100644 drivers/usb/mtu3/mtu3_qmu.h
>

Acked-by: Bin Meng <bmeng.cn at gmail.com>


More information about the U-Boot mailing list