]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
am33xx: board: probe misc drivers to register musb devices
authorMugunthan V N <mugunthanvnm@ti.com>
Thu, 17 Nov 2016 09:08:09 +0000 (14:38 +0530)
committerSimon Glass <sjg@chromium.org>
Sat, 3 Dec 2016 04:04:07 +0000 (21:04 -0700)
MUSB wrapper driver is bound as MISC device and underlying usb
devices are bind to usb drivers based on dr_mode, so probing the
MISC wrapper driver to register musb devices.

Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com>
Reviewed-by: Tom Rini <trini@konsulko.com>
arch/arm/mach-omap2/am33xx/board.c

index 80b729aa13c063e5513d0049abaed29c32d198b0..2ce7790be6c7daa3a8ce07e74ddec2f31e498083 100644 (file)
@@ -197,6 +197,13 @@ int arch_misc_init(void)
        musb_register(&otg1_plat, &otg1_board_data,
                (void *)USB1_OTG_BASE);
 #endif
+#else
+       struct udevice *dev;
+       int ret;
+
+       ret = uclass_first_device(UCLASS_MISC, &dev);
+       if (ret || !dev)
+               return ret;
 #endif
        return 0;
 }