u-boot/drivers/usb
Hans de Goede fcdd8aaa48 dm: usb: Fix finding of first upstream usb-2 hub in the ehci dm code
The ehci driver model code for finding the first upstream usb-2 hub before
this commit has a number of issues:

1) "if (!ttdev->speed != USB_SPEED_HIGH)" does not work because the '!'
   takes presedence over the '!=' this should simply be
   "if (ttdev->speed == USB_SPEED_HIGH)"
2) It makes ttdev point to the first upstream usb-2 hub, but ttdev should
   point to the last usb-1 device before the first usb-2 hub (when going
   upstream from the device), as ttdev is used to find the port of the
   first usb-2 hub to which the the last usb-1 device is connected.
3) parent_devnum however should be set to the devnum of the first usb-2
   hub, so we need to keep pointers around to both usb_device structs.

To complicate things further during enumeration usb_device.dev will point
to the parent udevice, where as during normal use it will point to
the actual udevice, we must handle both cases correctly.

This commit fixes all this making usb-1 devices attached to usb-2 hubs,
including usb-1 devices attached to usb-1 hubs attached to usb-2 hubs, work.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Simon Glass <sjg@chromium.org>
2015-05-05 20:58:42 -06:00
..
dwc3 usb: dwc3: Correct clean up code for requests 2015-04-14 05:48:12 +02:00
emul dm: usb: Add a terminator to the string destructor list 2015-04-22 11:13:24 -06:00
eth net: cosmetic: Fix var naming net <-> eth drivers 2015-04-18 11:11:33 -06:00
gadget net: cosmetic: Fix var naming net <-> eth drivers 2015-04-18 11:11:33 -06:00
host dm: usb: Fix finding of first upstream usb-2 hub in the ehci dm code 2015-05-05 20:58:42 -06:00
musb include: move various macros to include/linux/kernel.h 2014-11-20 11:28:25 -05:00
musb-new sunxi: usb: Do not call phy_probe from hcd code 2015-05-04 16:51:55 +02:00
phy ti: dwc3: Enable clocks in enable_basic_clocks() in hw_data.c 2015-04-16 15:08:36 -04:00
ulpi drivers: usb: convert makefiles to Kbuild style 2013-10-31 13:25:38 -04:00
Kconfig dm: usb: sandbox: Add a uclass for USB device emulation 2015-04-18 11:11:26 -06:00