WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [Patch 2/4] Refining Xsave/Xrestore support

To: Haitao Shan <maillists.shan@xxxxxxxxx>
Subject: Re: [Xen-devel] [Patch 2/4] Refining Xsave/Xrestore support
From: Jeremy Fitzhardinge <jeremy@xxxxxxxx>
Date: Thu, 28 Oct 2010 18:11:40 -0700
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx, "Han, Weidong" <weidong.han@xxxxxxxxx>, Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Delivery-date: Thu, 28 Oct 2010 18:12:30 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <AANLkTin7Ei3-Jiq9dzExXih1KPNUNT=ymQaZE9hENbmD@xxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AANLkTimWUuyHvZ06=2cRBhvw2fcfMzA5QAuJZJso7=gY@xxxxxxxxxxxxxx> <4CC85D7E.2010201@xxxxxxxx> <AANLkTimEWZ7VP5FFQCg=kZDNh2iLqZaU_N2shqhnA1c8@xxxxxxxxxxxxxx> <4CC9A242.5040202@xxxxxxxx> <AANLkTin7Ei3-Jiq9dzExXih1KPNUNT=ymQaZE9hENbmD@xxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.9) Gecko/20100921 Fedora/3.1.4-1.fc13 Lightning/1.0b3pre Thunderbird/3.1.4
 On 10/28/2010 05:57 PM, Haitao Shan wrote:
> Then what about the approach that Jan uses in 2.6.27 tree, which is
> reading CPUID-OSXSAVE? If supported, Xen will always set CR4.OSXSAVE.

Sure, if CR4.OSXSAVE is set iff xsave is available, then it should work
fine if we test that.

    J

> Shan Haitao
>
> 2010/10/29 Jeremy Fitzhardinge <jeremy@xxxxxxxx>:
>>  On 10/27/2010 07:57 PM, Haitao Shan wrote:
>>> Hi, Jeremy,
>>>
>>> My approach is based an old PV-OPS kernel source. Kernel tries to set
>>> CR4.OSXSAVE and read it back to determine whether Xsave is actually
>>> available.
>>> Could you still use that?
>> No, because some older versions of Xen kill the domain when they try to
>> set unknown bits in CR4.
>>
>>    J
>>
>>> Shan Haitao
>>>
>>> 2010/10/28 Jeremy Fitzhardinge <jeremy@xxxxxxxx>:
>>>>  On 10/27/2010 12:04 AM, Haitao Shan wrote:
>>>>> Hi, Keir,
>>>>>
>>>>> This is patch #2, which adds PV guest Xsave support.
>>>> How does a PV guest know whether Xsave support is available?  Previous
>>>> versions of Xen left the xsave cpu feature flag set even though xsave
>>>> wasn't usable by the domain, so I had to forceably mask it from the
>>>> cpuid features within the domain.  Given that a PV domain can't rely on
>>>> X86_FEATURE_XSAVE, how can it tell that the feature is actually usable?
>>>>
>>>> Thanks,
>>>>    J
>>>>
>>


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel