From: Roger Pau Monne <roger.pau@citrix.com>
To: xen-devel@lists.xenproject.org
Cc: Roger Pau Monne <roger.pau@citrix.com>,
Jan Beulich <jbeulich@suse.com>,
Andrew Cooper <andrew.cooper3@citrix.com>
Subject: [PATCH 2/2] x86/pvh: also print hardware domain pIRQ limit for PVH
Date: Wed, 20 Nov 2024 12:35:55 +0100 [thread overview]
Message-ID: <20241120113555.38146-3-roger.pau@citrix.com> (raw)
In-Reply-To: <20241120113555.38146-1-roger.pau@citrix.com>
Do not return early in the PVH/HVM case, so that the number of pIRQs is also
printed.
Fixes: 17f6d398f765 ('cmdline: document and enforce "extra_guest_irqs" upper bounds')
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
---
xen/arch/x86/io_apic.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)
diff --git a/xen/arch/x86/io_apic.c b/xen/arch/x86/io_apic.c
index bd5ad61c85e4..d9db2efc4f58 100644
--- a/xen/arch/x86/io_apic.c
+++ b/xen/arch/x86/io_apic.c
@@ -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);
--
2.46.0
next prev parent reply other threads:[~2024-11-20 11:36 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-20 11:35 [PATCH 0/2] x86/irq: fix calculation of maximum pIRQs for dom0 Roger Pau Monne
2024-11-20 11:35 ` [PATCH 1/2] x86/irq: fix calculation of max PV dom0 pIRQs Roger Pau Monne
2024-11-20 12:06 ` Andrew Cooper
2024-11-21 10:49 ` Jan Beulich
2024-11-21 11:04 ` Roger Pau Monné
2024-11-21 11:39 ` Jan Beulich
2024-11-22 8:01 ` Roger Pau Monné
2024-11-22 9:27 ` Jan Beulich
2024-11-20 11:35 ` Roger Pau Monne [this message]
2024-11-20 11:45 ` [PATCH 2/2] x86/pvh: also print hardware domain pIRQ limit for PVH Andrew Cooper
2024-11-21 10:54 ` Jan Beulich
2024-11-21 11:08 ` Roger Pau Monné
2024-11-21 11:14 ` Andrew Cooper
2024-11-21 11:24 ` Roger Pau Monné
2024-11-21 11:27 ` Jan Beulich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241120113555.38146-3-roger.pau@citrix.com \
--to=roger.pau@citrix.com \
--cc=andrew.cooper3@citrix.com \
--cc=jbeulich@suse.com \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.