riscv: Move virtio scan to board_late_init()
[platform/kernel/u-boot.git] / board / emulation / qemu-riscv / qemu-riscv.c
index 181abbb..173245b 100644 (file)
@@ -31,12 +31,6 @@ int is_flash_available(void)
 
 int board_init(void)
 {
-       /*
-        * Make sure virtio bus is enumerated so that peripherals
-        * on the virtio bus can be discovered by their drivers
-        */
-       virtio_init();
-
        return 0;
 }
 
@@ -46,6 +40,12 @@ int board_late_init(void)
        if (CONFIG_IS_ENABLED(USB_KEYBOARD))
                usb_init();
 
+       /*
+        * Make sure virtio bus is enumerated so that peripherals
+        * on the virtio bus can be discovered by their drivers
+        */
+       virtio_init();
+
        return 0;
 }