[PATCH 2/5] tools: inform user which IOMMU was found during validation

Daniel P. Berrangé via Devel posted 5 patches 23 hours ago
[PATCH 2/5] tools: inform user which IOMMU was found during validation
Posted by Daniel P. Berrangé via Devel 23 hours ago
From: Daniel P. Berrangé <berrange@redhat.com>

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---
 tools/virt-host-validate-common.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tools/virt-host-validate-common.c b/tools/virt-host-validate-common.c
index 59f6ac3319..6516d96484 100644
--- a/tools/virt-host-validate-common.c
+++ b/tools/virt-host-validate-common.c
@@ -260,7 +260,7 @@ int virHostValidateIOMMU(const char *hvname,
 
     if (isIntel) {
         if (access("/sys/firmware/acpi/tables/DMAR", F_OK) == 0) {
-            virValidatePass();
+            virValidatePassDetails("DMAR");
             bootarg = "intel_iommu=on";
         } else {
             virValidateFail(level,
@@ -271,7 +271,7 @@ int virHostValidateIOMMU(const char *hvname,
         }
     } else if (isAMD) {
         if (access("/sys/firmware/acpi/tables/IVRS", F_OK) == 0) {
-            virValidatePass();
+            virValidatePassDetails("IVRS");
             bootarg = "iommu=pt iommu=1";
         } else {
             virValidateFail(level,
@@ -318,7 +318,7 @@ int virHostValidateIOMMU(const char *hvname,
                                 "No SMMU found");
                 return VIR_VALIDATE_FAILURE(level);
             } else {
-                virValidatePass();
+                virValidatePassDetails("SMMU");
             }
         }
     } else {
-- 
2.51.1

Re: [PATCH 2/5] tools: inform user which IOMMU was found during validation
Posted by Peter Krempa via Devel 20 hours ago
On Thu, Nov 20, 2025 at 10:14:48 +0000, Daniel P. Berrangé via Devel wrote:
> From: Daniel P. Berrangé <berrange@redhat.com>
> 
> Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
> ---
>  tools/virt-host-validate-common.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

I presume we don't consider virt-host-validate as machine readable and
thus stable, right?

Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Re: [PATCH 2/5] tools: inform user which IOMMU was found during validation
Posted by Daniel P. Berrangé via Devel 19 hours ago
On Thu, Nov 20, 2025 at 02:32:37PM +0100, Peter Krempa wrote:
> On Thu, Nov 20, 2025 at 10:14:48 +0000, Daniel P. Berrangé via Devel wrote:
> > From: Daniel P. Berrangé <berrange@redhat.com>
> > 
> > Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
> > ---
> >  tools/virt-host-validate-common.c | 6 +++---
> >  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> I presume we don't consider virt-host-validate as machine readable and
> thus stable, right?

Yeah, I don't consider it machine readable. Also this additional
information is in the same format as info we print for WARN/FAIL
results.

> Reviewed-by: Peter Krempa <pkrempa@redhat.com>
> 

With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|