[PATCH v2 02/11] 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 f335a0149c..e025f50068 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -1748,10 +1748,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 bb956a77f4..e873cc8a20 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -2909,7 +2909,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
@@ -2947,7 +2947,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 17177c3547..dfaba677b1 100644
--- a/src/qemu/qemu_domain.c
+++ b/src/qemu/qemu_domain.c
@@ -3174,7 +3174,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;
 
@@ -3355,7 +3355,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;
@@ -3807,7 +3807,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'"),
@@ -4200,7 +4200,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;
@@ -5572,7 +5572,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
@@ -5872,7 +5872,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;
@@ -6066,7 +6066,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;
@@ -9022,7 +9022,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 c016d543a2..3d783b337d 100644
--- a/src/qemu/qemu_domain.h
+++ b/src/qemu/qemu_domain.h
@@ -771,7 +771,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 e9f460d77a..01cfdbeadf 100644
--- a/src/qemu/qemu_domain_address.c
+++ b/src/qemu/qemu_domain_address.c
@@ -485,7 +485,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
@@ -2180,7 +2180,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