]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
qemu: Build correct command line for PCI NICs on ARM
authorPavel Fedin <p.fedin@samsung.com>
Fri, 17 Jul 2015 11:27:46 +0000 (14:27 +0300)
committerMichal Privoznik <mprivozn@redhat.com>
Thu, 6 Aug 2015 12:25:02 +0000 (14:25 +0200)
Legacy -net option works correctly only with embedded device models, which
do not require any bus specification. Therefore, we should use -device for
PCI hardware

Signed-off-by: Pavel Fedin <p.fedin@samsung.com>
src/qemu/qemu_command.c

index c8522fb81c4715256e33d75686a7e8d9d5fddde7..0fe14758ca06756521065020f4132c0186d1cb1b 100644 (file)
@@ -457,7 +457,8 @@ qemuDomainSupportsNicdev(virDomainDefPtr def,
     /* non-virtio ARM nics require legacy -net nic */
     if (((def->os.arch == VIR_ARCH_ARMV7L) ||
         (def->os.arch == VIR_ARCH_AARCH64)) &&
-        net->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_VIRTIO_MMIO)
+        net->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_VIRTIO_MMIO &&
+        net->info.type != VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI)
         return false;
 
     return true;