From: "Roger Pau Monné" <roger.pau@citrix.com>
To: dmkhn@proton.me
Cc: xen-devel@lists.xenproject.org, andrew.cooper3@citrix.com,
anthony.perard@vates.tech, jbeulich@suse.com, julien@xen.org,
michal.orzel@amd.com, sstabellini@kernel.org, dmukhin@ford.com
Subject: Re: [PATCH v2 1/2] xen/domain: introduce non-x86 hardware emulation flags
Date: Wed, 21 May 2025 16:05:04 +0200 [thread overview]
Message-ID: <aC3dkKyiIHRF8YO1@macbook.local> (raw)
In-Reply-To: <20250516022855.1146121-2-dmukhin@ford.com>
On Fri, May 16, 2025 at 02:29:09AM +0000, dmkhn@proton.me wrote:
> From: Denis Mukhin <dmukhin@ford.com>
>
> Define per-architecture emulation_flags for configuring domain emulation
> features.
>
> Print d->arch.emulation_flags from 'q' keyhandler for better traceability
> while debugging.
>
> Signed-off-by: Denis Mukhin <dmukhin@ford.com>
> ---
> Changes since v1:
> - dropped comments
> ---
> xen/arch/arm/include/asm/domain.h | 1 +
> xen/arch/ppc/include/asm/domain.h | 1 +
> xen/arch/riscv/include/asm/domain.h | 1 +
> xen/common/keyhandler.c | 1 +
> 4 files changed, 4 insertions(+)
>
> diff --git a/xen/arch/arm/include/asm/domain.h b/xen/arch/arm/include/asm/domain.h
> index a3487ca713..70e6e7d49b 100644
> --- a/xen/arch/arm/include/asm/domain.h
> +++ b/xen/arch/arm/include/asm/domain.h
> @@ -121,6 +121,7 @@ struct arch_domain
> void *tee;
> #endif
>
> + uint32_t emulation_flags;
> } __cacheline_aligned;
>
> struct arch_vcpu
> diff --git a/xen/arch/ppc/include/asm/domain.h b/xen/arch/ppc/include/asm/domain.h
> index 3a447272c6..001116a0ab 100644
> --- a/xen/arch/ppc/include/asm/domain.h
> +++ b/xen/arch/ppc/include/asm/domain.h
> @@ -21,6 +21,7 @@ struct arch_vcpu {
>
> struct arch_domain {
> struct hvm_domain hvm;
> + uint32_t emulation_flags;
> };
>
> #include <xen/sched.h>
> diff --git a/xen/arch/riscv/include/asm/domain.h b/xen/arch/riscv/include/asm/domain.h
> index c3d965a559..7bc242da55 100644
> --- a/xen/arch/riscv/include/asm/domain.h
> +++ b/xen/arch/riscv/include/asm/domain.h
> @@ -18,6 +18,7 @@ struct arch_vcpu {
>
> struct arch_domain {
> struct hvm_domain hvm;
> + uint32_t emulation_flags;
> };
>
> #include <xen/sched.h>
> diff --git a/xen/common/keyhandler.c b/xen/common/keyhandler.c
> index 0bb842ec00..73f5134b68 100644
> --- a/xen/common/keyhandler.c
> +++ b/xen/common/keyhandler.c
> @@ -306,6 +306,7 @@ static void cf_check dump_domains(unsigned char key)
> if ( test_bit(i, &d->watchdog_inuse_map) )
> printk(" watchdog %d expires in %d seconds\n",
> i, (u32)((d->watchdog_timer[i].expires - NOW()) >> 30));
> + printk(" emulation_flags %#x\n", d->arch.emulation_flags);
>
> arch_dump_domain_info(d);
Hello,
I think it might be easier to print emulation_flags in
arch_dump_domain_info(), ideally it would be helpful if this could be
printed in a user friendly way apart from the raw dump:
printk(" emulation_flags:%s%s... (%#x)\n",
!d->arch.emulation_flags ? " none" : "",
has_vlapic(d) ? " lapic" : "", ...
d->arch.emulation_flags);
Regards, Roger.
next prev parent reply other threads:[~2025-05-21 14:05 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-16 2:29 [PATCH v2 0/2] xen/domain: updates to hardware emulation flags dmkhn
2025-05-16 2:29 ` [PATCH v2 1/2] xen/domain: introduce non-x86 " dmkhn
2025-05-20 15:21 ` Jan Beulich
2025-05-20 21:39 ` dmkhn
2025-05-21 6:01 ` Jan Beulich
2025-05-21 14:05 ` Roger Pau Monné [this message]
2025-05-28 21:17 ` dmkhn
2025-05-16 2:29 ` [PATCH v2 2/2] xen/domain: rewrite emulation_flags_ok() dmkhn
2025-05-20 15:24 ` Jan Beulich
2025-05-20 22:38 ` dmkhn
2025-05-20 23:00 ` Stefano Stabellini
2025-05-21 6:51 ` Jan Beulich
2025-05-21 6:04 ` Jan Beulich
2025-05-21 15:07 ` Roger Pau Monné
2025-05-22 0:26 ` dmkhn
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=aC3dkKyiIHRF8YO1@macbook.local \
--to=roger.pau@citrix.com \
--cc=andrew.cooper3@citrix.com \
--cc=anthony.perard@vates.tech \
--cc=dmkhn@proton.me \
--cc=dmukhin@ford.com \
--cc=jbeulich@suse.com \
--cc=julien@xen.org \
--cc=michal.orzel@amd.com \
--cc=sstabellini@kernel.org \
--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.