aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/dwc3
diff options
context:
space:
mode:
authorPaul Zimmerman <Paul.Zimmerman@synopsys.com>2011-09-30 03:58:43 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2011-10-04 13:25:53 -0400
commit82828ca77b8b63b817d9bb540145a4cafa9be582 (patch)
treeb30010f498ea66c2ef29f90d6b39ace733cd187d /drivers/usb/dwc3
parentb23c843992b659d537514e6493d673284f5d6724 (diff)
usb: dwc3: gadget: driver should not wait for RxFIFO to drain
An older version of the databook said to wait for the FIFO to drain, but that has been removed from the newer databooks. Waiting for RxFIFO to drain caused problems when testing against one of the host controllers available in the market. After talking to one of the RTL engineers, he stated that we should _not_ wait for RxFIFO to drain. Signed-off-by: Paul Zimmerman <paulz@synopsys.com> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/dwc3')
-rw-r--r--drivers/usb/dwc3/gadget.c19
1 files changed, 0 insertions, 19 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index 9c0174a8f46..fd5d2bd9b7e 100644
--- a/drivers/usb/dwc3/gadget.c
+++ b/drivers/usb/dwc3/gadget.c
@@ -1656,25 +1656,6 @@ static void dwc3_gadget_reset_interrupt(struct dwc3 *dwc)
1656 reg = dwc3_readl(dwc->regs, DWC3_DCFG); 1656 reg = dwc3_readl(dwc->regs, DWC3_DCFG);
1657 reg &= ~(DWC3_DCFG_DEVADDR_MASK); 1657 reg &= ~(DWC3_DCFG_DEVADDR_MASK);
1658 dwc3_writel(dwc->regs, DWC3_DCFG, reg); 1658 dwc3_writel(dwc->regs, DWC3_DCFG, reg);
1659
1660 /*
1661 * Wait for RxFifo to drain
1662 *
1663 * REVISIT probably shouldn't wait forever.
1664 * In case Hardware ends up in a screwed up
1665 * case, we error out, notify the user and,
1666 * maybe, WARN() or BUG() but leave the rest
1667 * of the kernel working fine.
1668 *
1669 * REVISIT the below is rather CPU intensive,
1670 * maybe we should read and if it doesn't work
1671 * sleep (not busy wait) for a few useconds.
1672 *
1673 * REVISIT why wait until the RXFIFO is empty anyway?
1674 */
1675 while (!(dwc3_readl(dwc->regs, DWC3_DSTS)
1676 & DWC3_DSTS_RXFIFOEMPTY))
1677 cpu_relax();
1678} 1659}
1679 1660
1680static void dwc3_update_ram_clk_sel(struct dwc3 *dwc, u32 speed) 1661static void dwc3_update_ram_clk_sel(struct dwc3 *dwc, u32 speed)