This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ulpi timeout

Other Parts Discussed in Thread: DM3730

I'm optimizing the boot speed of our custom DM3730 board which use a uSB332x transceiver.
I found that in the kernel  code drivers/usb/host/ehci-omap.c psp 04.02.00.07 after issuing ULPI command the condition tested for the command completion is

while ((ehci_omap_readl(omap->ehci_base, EHCI_INSNREG05_ULPI)
            & (1 << EHCI_INSNREG05_ULPI_CONTROL_SHIFT))) {
        cpu_relax();

        if (time_after(jiffies, timeout)) {
            dev_dbg(omap->dev, "phy reset operation timed out\n");
            break;
        }
    }

This condition is never met and always times out.

Is the same of u-boot/drivers/usb/ulpi/ulpi-viewport.c

static int ulpi_wait(struct ulpi_viewport *ulpi_vp, u32 mask)
{
    int timeout = CONFIG_USB_ULPI_TIMEOUT;

    /* Wait for the bits in mask to become zero. */
    while (--timeout) {
        if ((readl(ulpi_vp->viewport_addr) & mask) == 0)
            return 0;

        udelay(1);
    }

    return ULPI_ERROR;
}

while in the u-boot/drivers/usb/ulpi/omap-ulpi-viewport.c
you changed in
static int ulpi_wait(struct ulpi_viewport *ulpi_vp, u32 mask)
{
    int timeout = CONFIG_USB_ULPI_TIMEOUT;

    while (--timeout) {
        if ((readl(ulpi_vp->viewport_addr) & mask))
            return 0;

        udelay(1);
    }

    return ULPI_ERROR;
}


Is something specific for omap usb host controller or there is some problem in my hardware I should check?
Kind regards
          Andrea