[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 3 of 7 v2] x86: fix logical ANDs used to mask bitfields
# HG changeset patch # User Tim Deegan <tim@xxxxxxx> # Date 1333640955 -3600 # Node ID 4674ce03c62a3e916954fd445b4510ffe72e64f4 # Parent 08612e81926857363618746fd01f9b08b7c3ac73 x86: fix logical ANDs used to mask bitfields. Signed-off-by: Tim Deegan <tim@xxxxxxx> Acked-by: Jan Beulich <jbeulich@xxxxxxxx> diff -r 08612e819268 -r 4674ce03c62a xen/arch/x86/hvm/svm/svm.c --- a/xen/arch/x86/hvm/svm/svm.c Thu Apr 05 16:49:15 2012 +0100 +++ b/xen/arch/x86/hvm/svm/svm.c Thu Apr 05 16:49:15 2012 +0100 @@ -752,7 +752,7 @@ static void svm_lwp_interrupt(struct cpu ack_APIC_irq(); vlapic_set_irq( vcpu_vlapic(curr), - (curr->arch.hvm_svm.guest_lwp_cfg >> 40) && 0xff, + (curr->arch.hvm_svm.guest_lwp_cfg >> 40) & 0xff, 0); } diff -r 08612e819268 -r 4674ce03c62a xen/arch/x86/hvm/vmx/vmx.c --- a/xen/arch/x86/hvm/vmx/vmx.c Thu Apr 05 16:49:15 2012 +0100 +++ b/xen/arch/x86/hvm/vmx/vmx.c Thu Apr 05 16:49:15 2012 +0100 @@ -1382,7 +1382,7 @@ void vmx_inject_extint(int trap) if ( nestedhvm_vcpu_in_guestmode(v) ) { pin_based_cntrl = __get_vvmcs(vcpu_nestedhvm(v).nv_vvmcx, PIN_BASED_VM_EXEC_CONTROL); - if ( pin_based_cntrl && PIN_BASED_EXT_INTR_MASK ) { + if ( pin_based_cntrl & PIN_BASED_EXT_INTR_MASK ) { nvmx_enqueue_n2_exceptions (v, INTR_INFO_VALID_MASK | (X86_EVENTTYPE_EXT_INTR<<8) | trap, HVM_DELIVER_NO_ERROR_CODE); @@ -1401,7 +1401,7 @@ void vmx_inject_nmi(void) if ( nestedhvm_vcpu_in_guestmode(v) ) { pin_based_cntrl = __get_vvmcs(vcpu_nestedhvm(v).nv_vvmcx, PIN_BASED_VM_EXEC_CONTROL); - if ( pin_based_cntrl && PIN_BASED_NMI_EXITING ) { + if ( pin_based_cntrl & PIN_BASED_NMI_EXITING ) { nvmx_enqueue_n2_exceptions (v, INTR_INFO_VALID_MASK | (X86_EVENTTYPE_NMI<<8) | TRAP_nmi, HVM_DELIVER_NO_ERROR_CODE); _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |