diff options
-rwxr-xr-x | scripts/runqemu | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/scripts/runqemu b/scripts/runqemu index 605bcf25d6..f0ddeea1bf 100755 --- a/scripts/runqemu +++ b/scripts/runqemu | |||
@@ -992,12 +992,15 @@ class BaseConfig(object): | |||
992 | logger.info('Using ide drive') | 992 | logger.info('Using ide drive') |
993 | vm_drive = "%s,format=%s" % (self.rootfs, rootfs_format) | 993 | vm_drive = "%s,format=%s" % (self.rootfs, rootfs_format) |
994 | else: | 994 | else: |
995 | logger.warn("Unknown QB_DRIVE_TYPE: %s" % drive_type) | 995 | # virtio might have been selected explicitly (just use it), or |
996 | 996 | # is used as fallback (then warn about that). | |
997 | if not vm_drive: | 997 | if not drive_type.startswith("/dev/vd"): |
998 | logger.warn("Failed to figure out drive type, consider define or fix QB_DRIVE_TYPE") | 998 | logger.warn("Unknown QB_DRIVE_TYPE: %s" % drive_type) |
999 | logger.warn('Trying to use virtio block drive') | 999 | logger.warn("Failed to figure out drive type, consider define or fix QB_DRIVE_TYPE") |
1000 | vm_drive = '-drive if=virtio,file=%s,format=%s' % (self.rootfs, rootfs_format) | 1000 | logger.warn('Trying to use virtio block drive') |
1001 | vm_drive = '-drive if=virtio,file=%s,format=%s' % (self.rootfs, rootfs_format) | ||
1002 | |||
1003 | # All branches above set vm_drive. | ||
1001 | self.rootfs_options = '%s -no-reboot' % vm_drive | 1004 | self.rootfs_options = '%s -no-reboot' % vm_drive |
1002 | self.kernel_cmdline = 'root=%s rw highres=off' % (self.get('QB_KERNEL_ROOT')) | 1005 | self.kernel_cmdline = 'root=%s rw highres=off' % (self.get('QB_KERNEL_ROOT')) |
1003 | 1006 | ||