VirtualBox

Changeset 15031 in vbox


Ignore:
Timestamp:
Dec 5, 2008 12:08:28 PM (16 years ago)
Author:
vboxsync
Message:

Switcher updates

Location:
trunk/src/VBox/VMM
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/HWACCMInternal.h

    r15017 r15031  
    3535#include <iprt/mp.h>
    3636
    37 #if HC_ARCH_BITS == 64 || defined (VBOX_WITH_64_BITS_GUESTS)
     37#if HC_ARCH_BITS == 64 // || defined (VBOX_WITH_64_BITS_GUESTS)
    3838/* Enable 64 bits guest support. */
    3939# define VBOX_ENABLE_64_BITS_GUESTS
  • trunk/src/VBox/VMM/VMMGC/HWACCMGCA.asm

    r15030 r15031  
    107107; *
    108108; * @returns VBox status code
    109 ; * @param   pCtx       Guest context (rsi)
     109; * @param   pPageCpuPhys   VMXON physical address  [rsp+8]
     110; * @param   pVMCSPhys      VMCS physical address   [rsp+16]
     111; * @param   pCtx           Guest context (rsi)
    110112; */
    111113BEGINPROC VMXGCStartVM64
     
    113115    mov     rbp, rsp
    114116
     117    ; Make sure VT-x instructions are allowed
     118    mov     rax, cr4
     119    or      rax, X86_CR4_VMXE
     120    mov     cr4, rax
     121
     122    ;/* Enter VMX Root Mode */
     123    vmxon   [rbp + 8 + 8]
     124    jnc     .vmxon_success
     125    mov     rax, VERR_VMX_INVALID_VMXON_PTR
     126    jmp     .vmstart64_vmxon_failed
     127   
     128.vmxon_success:
     129    ; Activate the VMCS pointer
     130    vmptrld [rbp + 16 + 8]
     131    jnc     .vmptrld_success
     132    mov     rax, VERR_VMX_INVALID_VMCS_PTR
     133    jmp     .vmstart64_vmoff_end
     134   
     135.vmptrld_success:   
    115136    ; Have to sync half the guest state as we can't access most of the 64 bits state in 32 bits mode. Sigh.
    116137    VMCSWRITE VMX_VMCS64_GUEST_CS_BASE,         [rsi + CPUMCTX.csHid.u64Base]
     
    253274
    254275.vmstart64_end:
     276    ; Write back the data and disable the VMCS
     277    vmclear [rbp + 16 + 8]  ;pVMCS
     278
     279.vmstart64_vmoff_end:
     280    ; Disable VMX root mode
     281    vmxoff
     282.vmstart64_vmxon_failed:
    255283    pop     rbp
    256284    ret
  • trunk/src/VBox/VMM/VMMR0/HWSVMR0.cpp

    r15017 r15031  
    758758    if (pCtx->msrEFER & MSR_K6_EFER_LMA)
    759759    {
    760 #if !defined(VBOX_WITH_64_BITS_GUESTS)
     760#if !defined(VBOX_ENABLE_64_BITS_GUESTS)
    761761        return VERR_PGM_UNSUPPORTED_SHADOW_PAGING_MODE;
    762762#elif HC_ARCH_BITS == 32
  • trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp

    r15017 r15031  
    15021502    if (pCtx->msrEFER & MSR_K6_EFER_LMA)
    15031503    {
    1504 #if !defined(VBOX_WITH_64_BITS_GUESTS)
     1504#if !defined(VBOX_ENABLE_64_BITS_GUESTS)
    15051505        return VERR_PGM_UNSUPPORTED_SHADOW_PAGING_MODE;
    15061506#elif HC_ARCH_BITS == 32
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette