u-boot-brain/drivers/usb
Matej Frančeškin 8c86501819 MUSB driver: Timeout is never detected as the while loop does not end
Timeout variable is decremented once more when while condition is not met.
Following "if" does not detect correctly that timeout has occurred.
Because of this bug the "usb start" command on AM335X-EVM board did not detect correctly that USB device was not attached.

	timeout = musb_cfg.timeout;
	while (timeout--)
		if (readb(&musbr->devctl) & MUSB_DEVCTL_HM)
 			break;
	/* if musb core is not in host mode, then return */
	if (!timeout)
		return -1;

Signed-off-by: Matej Franceskin <Matej.Franceskin@comtrade.com>
CC: Marek Vasut <matex@denx.de>?
2012-09-01 16:21:53 +02:00
..
eth Merge branch 'next' of git://git.denx.de/u-boot 2012-07-30 20:39:52 +02:00
gadget dfu:usb: DFU USB function (f_dfu) support for g_dnl composite gadget 2012-09-01 16:21:50 +02:00
host USB: Fix strict aliasing in ohci-hcd 2012-09-01 16:21:53 +02:00
musb MUSB driver: Timeout is never detected as the while loop does not end 2012-09-01 16:21:53 +02:00
phy Switch from archive libraries to partial linking 2010-11-17 21:02:18 +01:00
ulpi usb: ulpi: Add omap-ulpi-view port support 2012-02-12 10:11:30 +01:00