[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [RFC PATCH 03/21] i386/kvm: handle Xen HVM cpuid leaves
From: |
David Woodhouse |
Subject: |
Re: [RFC PATCH 03/21] i386/kvm: handle Xen HVM cpuid leaves |
Date: |
Tue, 06 Dec 2022 08:05:01 +0000 |
User-agent: |
Evolution 3.36.5-0ubuntu1 |
On Tue, 2022-12-06 at 08:58 +0100, Philippe Mathieu-Daudé wrote:
> On 6/12/22 01:18, David Woodhouse wrote:
> > On Mon, 2022-12-05 at 22:58 +0100, Philippe Mathieu-Daudé wrote:
> > > >
> > > > diff --git a/target/i386/cpu.c b/target/i386/cpu.c
> > > > index 22b681ca37..45aa9e40a5 100644
> > > > --- a/target/i386/cpu.c
> > > > +++ b/target/i386/cpu.c
> > > > @@ -7069,6 +7069,8 @@ static Property x86_cpu_properties[] = {
> > > > * own cache information (see x86_cpu_load_def()).
> > > > */
> > > > DEFINE_PROP_BOOL("legacy-cache", X86CPU, legacy_cache, true),
> > > > + DEFINE_PROP_BOOL("xen", X86CPU, xen, false),
> > >
> > > Maybe name it 'xen-hvm'?
> >
> > I think I'd prefer it to go away completely. If the *machine* has the
> > Xen feature enabled (which I've made implicit in the 'xen-version'
> > property), perhaps we should *always* disable 'expose_kvm' and enable
> > the Xen CPUID leaves instead?
>
> It would be silly to run a non-Xen guest on the Xen machine, so it is
> not a bad idea :)
Right. I just wasn't sure how to do it as *default* but still let it be
overridden. I may just hard-code it.
> > > > + DEFINE_PROP_BOOL("xen-vapic", X86CPU, xen_vapic, false),
> > >
> > > What happens if we use -cpu host,-kvm,+xen,-xen-vapic ?
> >
> > That's sane; it does the Xen CPUID thing but doesn't advertise the
> > vAPIC feature in the Xen CPUID leaves.
>
> In which case we don't want to use the vAPIC?
Indeed. In that case we won't advertise vAPIC to the guest, and then
the guest will use PIRQ to route MSIs to event channels instead of
directly to guest vCPUs.
smime.p7s
Description: S/MIME cryptographic signature
- Re: [RFC PATCH 08/21] xen_platform: exclude vfio-pci from the PCI platform unplug, (continued)
- [RFC PATCH 04/21] xen-platform-pci: allow its creation with XEN_EMULATE mode, David Woodhouse, 2022/12/05
- [RFC PATCH 06/21] pc_piix: handle XEN_EMULATE backend init, David Woodhouse, 2022/12/05
- [RFC PATCH 19/21] i386/xen: handle event channel upcall related hypercalls, David Woodhouse, 2022/12/05
- [RFC PATCH 02/21] i386/xen: Add xen-version machine property and init KVM Xen support, David Woodhouse, 2022/12/05
- [RFC PATCH 01/21] include: import xen public headers, David Woodhouse, 2022/12/05
- [RFC PATCH 03/21] i386/kvm: handle Xen HVM cpuid leaves, David Woodhouse, 2022/12/05
[RFC PATCH 17/21] i386/xen: handle register_runstate_memory_area, David Woodhouse, 2022/12/05
[RFC PATCH 13/21] i386/xen: implement HYPERVISOR_hvm_op, David Woodhouse, 2022/12/05
[RFC PATCH 05/21] hw/xen_backend: refactor xen_be_init(), David Woodhouse, 2022/12/05
[RFC PATCH 16/21] i386/xen: handle register_vcpu_time_memory_area, David Woodhouse, 2022/12/05
[RFC PATCH 11/21] i386/xen: implement HYPERCALL_xen_version, David Woodhouse, 2022/12/05
[RFC PATCH 09/21] pc_piix: allow xenfv machine with XEN_EMULATE, David Woodhouse, 2022/12/05