[PATCH v3 2/9] qemu: rename qemuDomainArmVirt()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



It's ARM specific.

Signed-off-by: Lubomir Rintel <lkundrak@xxxxx>
---
 src/qemu/qemu_capabilities.c   |  4 ++--
 src/qemu/qemu_command.c        |  4 ++--
 src/qemu/qemu_domain.c         | 16 ++++++++--------
 src/qemu/qemu_domain.h         |  2 +-
 src/qemu/qemu_domain_address.c |  4 ++--
 5 files changed, 15 insertions(+), 15 deletions(-)

diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index d9b1089c59..d2f7e9efa6 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -1787,10 +1787,10 @@ bool virQEMUCapsHasPCIMultiBus(virQEMUCapsPtr qemuCaps,
         return false;
     }
 
-    /* If 'virt' supports PCI, it supports multibus.
+    /* If ARM 'virt' supports PCI, it supports multibus.
      * No extra conditions here for simplicity.
      */
-    if (qemuDomainIsVirt(def))
+    if (qemuDomainIsARMVirt(def))
         return true;
 
     return false;
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index ec46db5c36..334f14913a 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -2948,7 +2948,7 @@ qemuBuildControllerDevCommandLine(virCommandPtr cmd,
             if (cont->type == VIR_DOMAIN_CONTROLLER_TYPE_USB &&
                 cont->model == VIR_DOMAIN_CONTROLLER_MODEL_USB_DEFAULT &&
                 !qemuDomainIsQ35(def) &&
-                !qemuDomainIsVirt(def)) {
+                !qemuDomainIsARMVirt(def)) {
 
                 /* An appropriate default USB controller model should already
                  * have been selected in qemuDomainDeviceDefPostParse(); if
@@ -2986,7 +2986,7 @@ qemuBuildControllerDevCommandLine(virCommandPtr cmd,
 
     if (usbcontroller == 0 &&
         !qemuDomainIsQ35(def) &&
-        !qemuDomainIsVirt(def) &&
+        !qemuDomainIsARMVirt(def) &&
         !ARCH_IS_S390(def->os.arch)) {
         /* We haven't added any USB controller yet, but we haven't been asked
          * not to add one either. Add a legacy USB controller, unless we're
diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c
index ad7f4091f6..fcb37d45e6 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -3199,7 +3199,7 @@ qemuDomainDefAddDefaultDevices(virDomainDefPtr def,
     case VIR_ARCH_AARCH64:
         addDefaultUSB = false;
         addDefaultMemballoon = false;
-        if (qemuDomainIsVirt(def))
+        if (qemuDomainIsARMVirt(def))
             addPCIeRoot = virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_GPEX);
         break;
 
@@ -3380,7 +3380,7 @@ qemuDomainDefEnableDefaultFeatures(virDomainDefPtr def,
      * was not included in the domain XML, we need to choose a suitable
      * GIC version ourselves */
     if ((def->features[VIR_DOMAIN_FEATURE_GIC] == VIR_TRISTATE_SWITCH_ABSENT &&
-         qemuDomainIsVirt(def)) ||
+         qemuDomainIsARMVirt(def)) ||
         (def->features[VIR_DOMAIN_FEATURE_GIC] == VIR_TRISTATE_SWITCH_ON &&
          def->gic_version == VIR_GIC_VERSION_NONE)) {
         virGICVersion version;
@@ -3832,7 +3832,7 @@ qemuDomainDefValidateFeatures(const virDomainDef *def,
 
         case VIR_DOMAIN_FEATURE_GIC:
             if (def->features[i] == VIR_TRISTATE_SWITCH_ON &&
-                !qemuDomainIsVirt(def)) {
+                !qemuDomainIsARMVirt(def)) {
                 virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
                                _("The '%s' feature is not supported for "
                                  "architecture '%s' or machine type '%s'"),
@@ -4245,7 +4245,7 @@ qemuDomainChrDefValidate(const virDomainChrDef *dev,
             isCompatible = false;
         }
 
-        if (!qemuDomainIsVirt(def) &&
+        if (!qemuDomainIsARMVirt(def) &&
             (dev->targetType == VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_SYSTEM ||
              dev->targetModel == VIR_DOMAIN_CHR_SERIAL_TARGET_MODEL_PL011)) {
             isCompatible = false;
@@ -5770,7 +5770,7 @@ qemuDomainDefaultNetModel(const virDomainDef *def,
         if (STREQ(def->os.machine, "versatilepb"))
             return "smc91c111";
 
-        if (qemuDomainIsVirt(def))
+        if (qemuDomainIsARMVirt(def))
             return "virtio";
 
         /* Incomplete. vexpress (and a few others) use this, but not all
@@ -6070,7 +6070,7 @@ qemuDomainChrDefPostParse(virDomainChrDefPtr chr,
             chr->targetType = VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_ISA;
         } else if (qemuDomainIsPSeries(def)) {
             chr->targetType = VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_SPAPR_VIO;
-        } else if (qemuDomainIsVirt(def)) {
+        } else if (qemuDomainIsARMVirt(def)) {
             chr->targetType = VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_SYSTEM;
         } else if (ARCH_IS_S390(def->os.arch)) {
             chr->targetType = VIR_DOMAIN_CHR_SERIAL_TARGET_TYPE_SCLP;
@@ -6264,7 +6264,7 @@ qemuDomainDeviceVideoDefPostParse(virDomainVideoDefPtr video,
     if (video->type == VIR_DOMAIN_VIDEO_TYPE_DEFAULT) {
         if (ARCH_IS_PPC64(def->os.arch))
             video->type = VIR_DOMAIN_VIDEO_TYPE_VGA;
-        else if (qemuDomainIsVirt(def) || ARCH_IS_S390(def->os.arch))
+        else if (qemuDomainIsARMVirt(def) || ARCH_IS_S390(def->os.arch))
             video->type = VIR_DOMAIN_VIDEO_TYPE_VIRTIO;
         else
             video->type = VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
@@ -9453,7 +9453,7 @@ qemuDomainMachineIsS390CCW(const char *machine)
 
 
 bool
-qemuDomainIsVirt(const virDomainDef *def)
+qemuDomainIsARMVirt(const virDomainDef *def)
 {
     return qemuDomainMachineIsARMVirt(def->os.machine, def->os.arch);
 }
diff --git a/src/qemu/qemu_domain.h b/src/qemu/qemu_domain.h
index f883780215..898b5b4479 100644
--- a/src/qemu/qemu_domain.h
+++ b/src/qemu/qemu_domain.h
@@ -809,7 +809,7 @@ bool qemuDomainHasPCIRoot(const virDomainDef *def);
 bool qemuDomainHasPCIeRoot(const virDomainDef *def);
 bool qemuDomainNeedsFDC(const virDomainDef *def);
 bool qemuDomainIsS390CCW(const virDomainDef *def);
-bool qemuDomainIsVirt(const virDomainDef *def);
+bool qemuDomainIsARMVirt(const virDomainDef *def);
 bool qemuDomainIsPSeries(const virDomainDef *def);
 bool qemuDomainHasBuiltinIDE(const virDomainDef *def);
 
diff --git a/src/qemu/qemu_domain_address.c b/src/qemu/qemu_domain_address.c
index 6671eccf6f..6c540a8094 100644
--- a/src/qemu/qemu_domain_address.c
+++ b/src/qemu/qemu_domain_address.c
@@ -468,7 +468,7 @@ qemuDomainAssignARMVirtioMMIOAddresses(virDomainDefPtr def,
         return;
 
     if (!(STRPREFIX(def->os.machine, "vexpress-") ||
-          qemuDomainIsVirt(def)))
+          qemuDomainIsARMVirt(def)))
         return;
 
     /* We use virtio-mmio by default on mach-virt guests only if they already
@@ -2163,7 +2163,7 @@ qemuDomainSupportsPCI(virDomainDefPtr def,
     if (STREQ(def->os.machine, "versatilepb"))
         return true;
 
-    if (qemuDomainIsVirt(def) &&
+    if (qemuDomainIsARMVirt(def) &&
         virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_GPEX))
         return true;
 
-- 
2.17.1

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux