Re: [PATCH] tools/virt-host-validate: Fix IOMMU check on s390x

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

 



On Tue, Feb 26, 2019 at 12:02:20PM +0100, Thomas Huth wrote:
When running virt-host-validate on an s390x host, the tool currently
warns that it is "Unknown if this platform has IOMMU support".
We can use the common check for entries in sys/kernel/iommu_groups here,
too, but it only makes sense to check it if there are also PCI devices
available. It's also common on s390x that there are no PCI devices
assigned to the LPAR, and in that case there is no need for the
PCI-related IOMMU, so without PCI devices we should simply skip this
test.

Signed-off-by: Thomas Huth <thuth@xxxxxxxxxx>
---
tools/virt-host-validate-common.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/tools/virt-host-validate-common.c b/tools/virt-host-validate-common.c
index 73e3bdb..75c7cfc 100644
--- a/tools/virt-host-validate-common.c
+++ b/tools/virt-host-validate-common.c
@@ -337,7 +337,7 @@ int virHostValidateIOMMU(const char *hvname,
    virBitmapPtr flags;
    struct stat sb;
    const char *bootarg = NULL;
-    bool isAMD = false, isIntel = false, isPPC = false;
+    bool isAMD = false, isIntel = false, isPPC, isS390;

Also, please don't put more variable declaration on the same line.
The removal of isPPC initialization is also unrelated.

Jano

    flags = virHostValidateGetCPUFlags();

    if (flags && virBitmapIsBitSet(flags, VIR_HOST_VALIDATE_CPU_FLAG_VMX))

Attachment: signature.asc
Description: PGP signature

--
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