]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
dm: usb: Do not use bus->seq before device_probe(bus)
authorHans de Goede <hdegoede@redhat.com>
Mon, 4 May 2015 19:33:26 +0000 (21:33 +0200)
committerLothar Waßmann <LW@KARO-electronics.de>
Tue, 8 Sep 2015 20:37:15 +0000 (22:37 +0200)
Do not use bus->seq before device_probe(bus), as bus->seq is not set until
after the device_probe() call. This fixes u-boot printing: "USB-1:   " for
each bus it scans.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Simon Glass <sjg@chromium.org>
drivers/usb/host/usb-uclass.c

index 714bc0e9588fb99899d0c42fe8d5dc9c203baa7e..8dc18236aba8a21d929d6e4b4a1b213bb03195ab 100644 (file)
@@ -145,9 +145,8 @@ int usb_init(void)
 
        uclass_foreach_dev(bus, uc) {
                /* init low_level USB */
+               printf("USB%d:   ", count);
                count++;
-               printf("USB");
-               printf("%d:   ", bus->seq);
                ret = device_probe(bus);
                if (ret == -ENODEV) {   /* No such device. */
                        puts("Port not available.\n");