[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 3/3] x86/HVM: don't crash guest upon problems occurring in user mode



>>> On 20.11.14 at 12:06, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 20/11/14 10:13, Jan Beulich wrote:
>> --- a/xen/arch/x86/hvm/svm/svm.c
>> +++ b/xen/arch/x86/hvm/svm/svm.c
>> @@ -90,6 +90,15 @@ static bool_t amd_erratum383_found __rea
>>  static uint64_t osvw_length, osvw_status;
>>  static DEFINE_SPINLOCK(osvw_lock);
>>  
>> +/* Only crash the guest if the problem originates in kernel mode. */
>> +static void svm_crash_or_gp(struct vcpu *v)
>> +{
>> +    if ( vmcb_get_cpl(v->arch.hvm_svm.vmcb) )
>> +        hvm_inject_hw_exception(TRAP_invalid_op, HVM_DELIVER_NO_ERROR_CODE);
> 
> This (and its VMX counterpart) should either deliver a #GP fault, or
> have its name changed to not imply a #GP fault.

Indeed - not sure how I managed to get this mixed up.

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.