• Ye Li's avatar
    MLK-17821-1 USB: gadget: Add the cadence USB3 gadget driver · 70514bd0
    Ye Li authored
    Porting the cadence USB3 (CDNS3) driver from kernel to u-boot. We only support
    the gadget (device mode), while the host mode is not supported. Users remains
    to use xhci-imx8 driver for host mode.
    
    Some changes in the CDNS3 driver porting:
    
    1. Add match_ep call back to usb_gadget_ops. The CDNS3 gadget driver replies
       on this operation to bind the usb_ep/usb_ss_ep with the endpoint descriptor
       when function layer uses usb_ep_autoconfig to add endpoint descriptors to gadget.
       So that CDNS3 driver can know the EP information and configure the EP once the
       set configuration request is received.
    
    2. U-boot does not have CMA, so it won't allocate uncached memory. Need to flush
       TRB and its DMA buffer before prime to usb controller and after complete transfer.
    
    3. In core.c, we add functions to hook with u-boot. It needs uplayer like
       to pass the register base address of each part of the USB controller.
    
    4. Force the CDNS3 gadget max speed to HS. The SuperSpeed is not supported by u-boot,
       so disable it in gadget driver. A configuration USB_CDNS3_GADGET_FORCE_HIGHSPEED is
       selected.
    
    5. Added gadget_is_cdns3 checking to provide bcdUSB value in device descriptor.
    
    6. Moved some new fields in usb_ep structure to usb_ss_ep, since u-boot does not have them.
    
    7. Remove host part codes as it is not supported by this driver.
    Signed-off-by: default avatarYe Li <ye.li@nxp.com>
    Acked-by: default avatarPeter Chen <peter.chen@nxp.com>
    70514bd0
Name
Last commit
Last update
..
adc Loading commit data...
bios_emulator Loading commit data...
block Loading commit data...
bootcount Loading commit data...
clk Loading commit data...
core Loading commit data...
cpu Loading commit data...
crypto Loading commit data...
ddr Loading commit data...
demo Loading commit data...
dfu Loading commit data...
dma Loading commit data...
fpga Loading commit data...
gpio Loading commit data...
hwmon Loading commit data...
i2c Loading commit data...
input Loading commit data...
led Loading commit data...
mailbox Loading commit data...
memory Loading commit data...
misc Loading commit data...
mmc Loading commit data...
mtd Loading commit data...
net Loading commit data...
pch Loading commit data...
pci Loading commit data...
pcmcia Loading commit data...
phy/marvell Loading commit data...
pinctrl Loading commit data...
power Loading commit data...
pwm Loading commit data...
qe Loading commit data...
ram Loading commit data...
remoteproc Loading commit data...
reset Loading commit data...
rtc Loading commit data...
serial Loading commit data...
soc Loading commit data...
sound Loading commit data...
spi Loading commit data...
spmi Loading commit data...
sysreset Loading commit data...
thermal Loading commit data...
timer Loading commit data...
tpm Loading commit data...
twserial Loading commit data...
usb Loading commit data...
video Loading commit data...
watchdog Loading commit data...
Kconfig Loading commit data...
Makefile Loading commit data...