From patchwork Thu May 21 17:37:55 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gleb Natapov X-Patchwork-Id: 25276 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n4LHc2Qa027718 for ; Thu, 21 May 2009 17:38:03 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753735AbZEURiA (ORCPT ); Thu, 21 May 2009 13:38:00 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753711AbZEURh7 (ORCPT ); Thu, 21 May 2009 13:37:59 -0400 Received: from mx2.redhat.com ([66.187.237.31]:58737 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753461AbZEURh5 (ORCPT ); Thu, 21 May 2009 13:37:57 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n4LHbx32029688 for ; Thu, 21 May 2009 13:37:59 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx2.corp.redhat.com (8.13.1/8.13.1) with ESMTP id n4LHbvS8010536 for ; Thu, 21 May 2009 13:37:59 -0400 Received: from dhcp-1-237.tlv.redhat.com (dhcp-1-237.tlv.redhat.com [10.35.1.237]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id n4LHbu89012233 for ; Thu, 21 May 2009 13:37:56 -0400 Received: by dhcp-1-237.tlv.redhat.com (Postfix, from userid 13519) id A071818D465; Thu, 21 May 2009 20:37:55 +0300 (IDT) From: Gleb Natapov To: kvm@vger.kernel.org Subject: [PATCH 2/2] Advertise X2APIC support. Date: Thu, 21 May 2009 20:37:55 +0300 Message-Id: <1242927475-6140-3-git-send-email-gleb@redhat.com> In-Reply-To: <1242927475-6140-1-git-send-email-gleb@redhat.com> References: <1242927475-6140-1-git-send-email-gleb@redhat.com> X-Scanned-By: MIMEDefang 2.58 on 172.16.27.26 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org Signed-off-by: Gleb Natapov --- target-i386/cpu.h | 1 + target-i386/helper.c | 5 +++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/target-i386/cpu.h b/target-i386/cpu.h index f054af1..29d730e 100644 --- a/target-i386/cpu.h +++ b/target-i386/cpu.h @@ -252,6 +252,7 @@ #define MSR_IA32_APICBASE 0x1b #define MSR_IA32_APICBASE_BSP (1<<8) #define MSR_IA32_APICBASE_ENABLE (1<<11) +#define MSR_IA32_APICBASE_EXTD (1<<10) #define MSR_IA32_APICBASE_BASE (0xfffff<<12) #define MSR_MTRRcap 0xfe diff --git a/target-i386/helper.c b/target-i386/helper.c index 23efcf4..170c3f7 100644 --- a/target-i386/helper.c +++ b/target-i386/helper.c @@ -148,7 +148,7 @@ static x86_def_t x86_defs[] = { CPUID_MTRR | CPUID_CLFLUSH | CPUID_MCA | /* this feature is needed for Solaris and isn't fully implemented */ CPUID_PSE36, - .ext_features = CPUID_EXT_SSE3, + .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_X2APIC, .ext2_features = (PPRO_FEATURES & 0x0183F3FF) | CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX | CPUID_EXT2_3DNOW | CPUID_EXT2_3DNOWEXT, @@ -199,7 +199,8 @@ static x86_def_t x86_defs[] = { /* The original CPU also implements these ext features: CPUID_EXT_DTES64, CPUID_EXT_DSCPL, CPUID_EXT_VMX, CPUID_EXT_EST, CPUID_EXT_TM2, CPUID_EXT_CX16, CPUID_EXT_XTPR, CPUID_EXT_PDCM */ - .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR | CPUID_EXT_SSSE3, + .ext_features = CPUID_EXT_SSE3 | CPUID_EXT_MONITOR | CPUID_EXT_SSSE3 | + CPUID_EXT_X2APIC, .ext2_features = CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX, /* Missing: .ext3_features = CPUID_EXT3_LAHF_LM */ .xlevel = 0x80000008,