From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756109AbYA0Iki (ORCPT ); Sun, 27 Jan 2008 03:40:38 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750936AbYA0Ik3 (ORCPT ); Sun, 27 Jan 2008 03:40:29 -0500 Received: from bzq-179-150-194.static.bezeqint.net ([212.179.150.194]:56321 "EHLO il.qumranet.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750792AbYA0Ik3 (ORCPT ); Sun, 27 Jan 2008 03:40:29 -0500 Message-ID: <479C4379.8090005@qumranet.com> Date: Sun, 27 Jan 2008 10:40:25 +0200 From: Avi Kivity User-Agent: Thunderbird 2.0.0.9 (X11/20071115) MIME-Version: 1.0 To: Joerg Roedel CC: kvm-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org Subject: Re: [kvm-devel] [PATCH 4/8] X86: export information about NPT to generic x86 code References: <1201294393-22613-1-git-send-email-joerg.roedel@amd.com> <1201294393-22613-5-git-send-email-joerg.roedel@amd.com> In-Reply-To: <1201294393-22613-5-git-send-email-joerg.roedel@amd.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Joerg Roedel wrote: > The generic x86 code has to know if the specific implementation uses Nested > Paging. In the generic code Nested Paging is called Hardware Assisted Paging > (HAP) to avoid confusion with (future) HAP implementations of other vendors. > This patch exports the availability of HAP to the generic x86 code. > > int (*set_tss_addr)(struct kvm *kvm, unsigned int addr); > + > + bool (*hap_enabled)(void); > }; > > Since the value doesn't change during the lifetime of the VM, it can be a data field instead of a function. Or, if we find that npt/ept is always a win, a static field in mmu.c. -- error compiling committee.c: too many arguments to function From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 4/8] X86: export information about NPT to generic x86 code Date: Sun, 27 Jan 2008 10:40:25 +0200 Message-ID: <479C4379.8090005@qumranet.com> References: <1201294393-22613-1-git-send-email-joerg.roedel@amd.com> <1201294393-22613-5-git-send-email-joerg.roedel@amd.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Joerg Roedel Return-path: In-Reply-To: <1201294393-22613-5-git-send-email-joerg.roedel-5C7GfCeVMHo@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Joerg Roedel wrote: > The generic x86 code has to know if the specific implementation uses Nested > Paging. In the generic code Nested Paging is called Hardware Assisted Paging > (HAP) to avoid confusion with (future) HAP implementations of other vendors. > This patch exports the availability of HAP to the generic x86 code. > > int (*set_tss_addr)(struct kvm *kvm, unsigned int addr); > + > + bool (*hap_enabled)(void); > }; > > Since the value doesn't change during the lifetime of the VM, it can be a data field instead of a function. Or, if we find that npt/ept is always a win, a static field in mmu.c. -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/