From patchwork Sun Oct 17 10:04:35 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nadav Har'El X-Patchwork-Id: 259731 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id o9HA4ibW014003 for ; Sun, 17 Oct 2010 10:04:44 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932314Ab0JQKEm (ORCPT ); Sun, 17 Oct 2010 06:04:42 -0400 Received: from mtagate3.uk.ibm.com ([194.196.100.163]:35493 "EHLO mtagate3.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932281Ab0JQKEl (ORCPT ); Sun, 17 Oct 2010 06:04:41 -0400 Received: from d06nrmr1707.portsmouth.uk.ibm.com (d06nrmr1707.portsmouth.uk.ibm.com [9.149.39.225]) by mtagate3.uk.ibm.com (8.13.1/8.13.1) with ESMTP id o9HA4cRE003704 for ; Sun, 17 Oct 2010 10:04:38 GMT Received: from d06av10.portsmouth.uk.ibm.com (d06av10.portsmouth.uk.ibm.com [9.149.37.251]) by d06nrmr1707.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id o9HA4cWg3489890 for ; Sun, 17 Oct 2010 11:04:38 +0100 Received: from d06av10.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id o9HA4bSW005223 for ; Sun, 17 Oct 2010 04:04:38 -0600 Received: from rice.haifa.ibm.com (rice.haifa.ibm.com [9.148.8.112]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id o9HA4bOr005220 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 17 Oct 2010 04:04:37 -0600 Received: from rice.haifa.ibm.com (lnx-nyh.haifa.ibm.com [127.0.0.1]) by rice.haifa.ibm.com (8.14.4/8.14.4) with ESMTP id o9HA4aSC029288; Sun, 17 Oct 2010 12:04:36 +0200 Received: (from nyh@localhost) by rice.haifa.ibm.com (8.14.4/8.14.4/Submit) id o9HA4ZYE029286; Sun, 17 Oct 2010 12:04:35 +0200 Date: Sun, 17 Oct 2010 12:04:35 +0200 Message-Id: <201010171004.o9HA4ZYE029286@rice.haifa.ibm.com> X-Authentication-Warning: rice.haifa.ibm.com: nyh set sender to "Nadav Har'El" using -f Cc: gleb@redhat.com, avi@redhat.com To: kvm@vger.kernel.org From: "Nadav Har'El" References: <1287309814-nyh@il.ibm.com> Subject: [PATCH 02/27] nVMX: Add VMX and SVM to list of supported cpuid features Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Sun, 17 Oct 2010 10:04:44 +0000 (UTC) --- .before/arch/x86/kvm/vmx.c 2010-10-17 11:52:00.000000000 +0200 +++ .after/arch/x86/kvm/vmx.c 2010-10-17 11:52:00.000000000 +0200 @@ -4271,6 +4271,8 @@ static void vmx_cpuid_update(struct kvm_ static void vmx_set_supported_cpuid(u32 func, struct kvm_cpuid_entry2 *entry) { + if (func == 1 && nested) + entry->ecx |= bit(X86_FEATURE_VMX); } static struct kvm_x86_ops vmx_x86_ops = {