From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mukesh Rathor Subject: Re: [PATCH 10/18 V2]: PVH xen: introduce vmx_pvh.c and pvh.c Date: Wed, 3 Apr 2013 18:01:59 -0700 Message-ID: <20130403180159.4c1bd681@mantra.us.oracle.com> References: <20130315174145.4bc0e78f@mantra.us.oracle.com> <20130318163206.GM24560@phenom.dumpdata.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20130318163206.GM24560@phenom.dumpdata.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Konrad Rzeszutek Wilk Cc: "Xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On Mon, 18 Mar 2013 12:32:06 -0400 Konrad Rzeszutek Wilk wrote: > On Fri, Mar 15, 2013 at 05:41:45PM -0700, Mukesh Rathor wrote: > > + return 1; > > + } > > + > > + new_cr0 &= ~HVM_CR0_GUEST_RESERVED_BITS; > > + /* ET is reserved and should be always be 1. */ > > + new_cr0 |= X86_CR0_ET; > > + > > + /* pvh cannot change to real mode */ > > + if ( (new_cr0 & (X86_CR0_PE|X86_CR0_PG)) != > > (X86_CR0_PG|X86_CR0_PE) ) { > > + printk("PVH attempting to turn off PE/PG. CR0:%lx\n", > > new_cr0); > > + return 1; > > + } > > + /* TS going from 1 to 0 */ > > + if ( (old_cr0 & X86_CR0_TS) && ((new_cr0 & > > X86_CR0_TS)==0) ) > > + vmx_fpu_enter(vp); > > Does this really happen? I thought in the PV mode you would be using > the hypercalls for the fpu swap? Should it be print out an error > saying something to the effect: > > "PVH guest is using cr0 instead of the paravirt lazy FPU > switch!" and include the EIP? Yes. At present in linux PVH, we use native_clts and not xen_clts pv ops call. But another PVH guest might not want to use hypercalls, right? thanks, Mukesh