]> xenbits.xensource.com Git - xen.git/commitdiff
x86/pvh: also print hardware domain pIRQ limit for PVH
authorRoger Pau Monné <roger.pau@citrix.com>
Mon, 25 Nov 2024 10:33:38 +0000 (11:33 +0100)
committerJan Beulich <jbeulich@suse.com>
Mon, 25 Nov 2024 10:33:38 +0000 (11:33 +0100)
Do not return early in the PVH/HVM case, so that the number of pIRQs is also
printed.  While PVH dom0 doesn't have access to the hypercalls to manage pIRQs
itself, nor the knowledge to do so, pIRQs are still used by Xen to map and
bind interrupts to a PVH dom0 behind its back.  Hence the pIRQ limit is still
relevant for a PVH dom0.

Fixes: 17f6d398f765 ('cmdline: document and enforce "extra_guest_irqs" upper bounds')
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/io_apic.c

index bd5ad61c85e4325d48b200535fca5b7b11dce1c6..d9db2efc4f586ba5b5a5548b2ce3d0ec36c4e2cf 100644 (file)
@@ -2754,11 +2754,13 @@ unsigned int __hwdom_init arch_hwdom_irqs(const struct domain *d)
 
     /* PVH (generally: HVM) can't use PHYSDEVOP_pirq_eoi_gmfn_v{1,2}. */
     if ( is_hvm_domain(d) )
-        return nr_irqs;
-
-    if ( !d->domain_id )
-        n = min(n, dom0_max_vcpus());
-    n = min(nr_irqs_gsi + n * NR_DYNAMIC_VECTORS, max_irqs);
+        n = nr_irqs;
+    else
+    {
+        if ( !d->domain_id )
+            n = min(n, dom0_max_vcpus());
+        n = min(nr_irqs_gsi + n * NR_DYNAMIC_VECTORS, max_irqs);
+    }
 
     printk("%pd has maximum %u PIRQs\n", d, n);