lkml.org 
[lkml]   [2009]   [Nov]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 17/35] KVM: VMX: Use macros instead of hex value on cr0 initialization
    Date
    From: Eduardo Habkost <ehabkost@redhat.com>

    This should have no effect, it is just to make the code clearer.

    Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
    Signed-off-by: Avi Kivity <avi@redhat.com>
    ---
    arch/x86/kvm/vmx.c | 2 +-
    1 files changed, 1 insertions(+), 1 deletions(-)

    diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
    index 364263a..1773017 100644
    --- a/arch/x86/kvm/vmx.c
    +++ b/arch/x86/kvm/vmx.c
    @@ -2538,7 +2538,7 @@ static int vmx_vcpu_reset(struct kvm_vcpu *vcpu)
    if (vmx->vpid != 0)
    vmcs_write16(VIRTUAL_PROCESSOR_ID, vmx->vpid);

    - vmx->vcpu.arch.cr0 = 0x60000010;
    + vmx->vcpu.arch.cr0 = X86_CR0_NW | X86_CR0_CD | X86_CR0_ET;
    vmx_set_cr0(&vmx->vcpu, vmx->vcpu.arch.cr0); /* enter rmode */
    vmx_set_cr4(&vmx->vcpu, 0);
    vmx_set_efer(&vmx->vcpu, 0);
    --
    1.6.5.2


    \
     
     \ /
      Last update: 2009-11-19 14:47    [W:0.020 / U:34.980 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site