All of lore.kernel.org
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Yang, Sheng" <sheng.yang@intel.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	Keir Fraser <keir.fraser@eu.citrix.com>
Subject: Re: x2APIC emulation for HVM guest
Date: Thu, 02 Dec 2010 07:44:05 +0100	[thread overview]
Message-ID: <4CF74035.5020909@redhat.com> (raw)
In-Reply-To: <201012021423.16866.sheng.yang@intel.com>

On 12/02/2010 07:23 AM, Yang, Sheng wrote:
> On Thursday 02 December 2010 13:48:15 Paolo Bonzini wrote:
>> On 12/02/2010 06:43 AM, Yang, Sheng wrote:
>>> I think we can do it step by step. This patch is big enough.
>>
>> Yes, I agree it can go in as a separate patch.
>>
>>> I'd like to work the direct EOI patch out, but I am thinking about how to
>>> test it...
>>
>> Maybe you can run Xen inside an HVM guest, forcing x2apic mode to be
>> enabled?  You do not need nested VMX if you only run PV guests in the
>> guest hypervisor.
> 
> I don't know how much work need to be done for this, and if it's worth to do for
> something was not be used in practice(if it would be used in practice, then it
> would be easy for us to test)...

Maybe it's as easy as this:

diff --git a/xen/arch/x86/genapic/x2apic.c b/xen/arch/x86/genapic/x2apic.c
--- a/xen/arch/x86/genapic/x2apic.c
+++ b/xen/arch/x86/genapic/x2apic.c
@@ -41,13 +41,13 @@ int x2apic_cmdline_disable(void)
 static int probe_x2apic_phys(void)
 {
     return x2apic && x2apic_phys && x2apic_is_available() &&
-        iommu_supports_eim();
+        1;
 }
 
 static int probe_x2apic_cluster(void)
 {
     return x2apic && !x2apic_phys && x2apic_is_available() &&
-        iommu_supports_eim();
+        1;
 }
 
 const struct genapic apic_x2apic_phys = {

The original Xen x2apic code was not conditional on iommu_supports_eim().

Paolo

  reply	other threads:[~2010-12-02  6:44 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-02  2:09 x2APIC emulation for HVM guest Yang, Sheng
2010-12-02  5:31 ` Paolo Bonzini
2010-12-02  5:43   ` Yang, Sheng
2010-12-02  5:48     ` Paolo Bonzini
2010-12-02  6:23       ` Yang, Sheng
2010-12-02  6:44         ` Paolo Bonzini [this message]
2010-12-02  6:49           ` Yang, Sheng
2010-12-02  7:30             ` Paolo Bonzini
2010-12-07  6:06 ` Sheng Yang

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=4CF74035.5020909@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=keir.fraser@eu.citrix.com \
    --cc=sheng.yang@intel.com \
    --cc=xen-devel@lists.xensource.com \
    /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.