From mboxrd@z Thu Jan 1 00:00:00 1970 From: Weidong Han Subject: Re: [PATCH 0/3 v2] XSAVE/XRSTOR fixes and enhancements Date: Wed, 01 Sep 2010 16:26:50 +0800 Message-ID: <4C7E0E4A.9040104@intel.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: Tim Deegan , Xen-devel , Jan Beulich List-Id: xen-devel@lists.xenproject.org Keir Fraser wrote: > On 01/09/2010 08:56, "Weidong Han" wrote: > > >>> Well that's how it was explained to me at the time. Was that in fact wrong >>> and we are already broken for save/restore for some subtle unexplained >>> reason? >>> >>> >> When XSAVE is enabled, it saves states to xsave_area in struct hvm_vcpu. >> But hvm_save_cpu_ctxt and hvm_load_cpu_ctxt don't save/restore FPU/SSE >> from xsave_area. So FPU/SSE states are incorrect after guest save/restore. >> > > Ignoring AVX, that needs fixing in 4.0 branch. The state needs pulling out > of the xsave area and into the existing hvm_hw_cpu structure. Or, we disable > xsave by default on 4.0.x branch. What do you think? > > I prefer to disable it by default on 4.0 branch now. After finish guest save/restore with XSAVE/XRSTOR in xen-unstable, we can port code to 4.0 branch and enable it again. Regards, Weidong