VirtualBox

Changeset 14987 in vbox for trunk/src/VBox/VMM


Ignore:
Timestamp:
Dec 4, 2008 2:32:53 PM (16 years ago)
Author:
vboxsync
Message:

Fully functional switcher

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/CPUMInternal.mac

    r14785 r14987  
    415415; @param   %1   register name
    416416%macro CPUMCPU_FROM_CPUM 1
    417     add     %1, [%1 + CPUM.ulOffCPUMCPU]
     417    add     %1, dword [%1 + CPUM.ulOffCPUMCPU]
    418418%endmacro
    419419
     
    422422; @param   %1   register name
    423423%macro CPUM_FROM_CPUMCPU 1
    424     sub     %1, [%1 + CPUMCPU.ulOffCPUM]
     424    sub     %1, dword [%1 + CPUMCPU.ulOffCPUM]
    425425%endmacro
  • trunk/src/VBox/VMM/VMMSwitcher/LegacyandAMD64.mac

    r14986 r14987  
    242242   
    243243    ; Setup stack; use the lss_esp, ss pair for lss
    244 ;;    DEBUG_CHAR('7')
    245 ;;    mov     rsp, 0
    246 ;;    mov     eax, [rdx + CPUM.Hyper.esp]
    247 ;;    mov     [rdx + CPUM.Hyper.lss_esp], eax
    248 ;;    lss     esp, [rdx + CPUM.Hyper.lss_esp]
     244    DEBUG_CHAR('7')
     245    mov     rsp, 0
     246    mov     eax, [rdx + CPUM.Hyper.esp]
     247    mov     [rdx + CPUM.Hyper.lss_esp], eax
     248    lss     esp, [rdx + CPUM.Hyper.lss_esp]
    249249
    250250    ; call the hypervisor function with rdx=pCpumCpu
    251 ;;    mov     eax, [rdx + r8 + CPUM.Hyper.eip]
    252 ;;    CPUMCPU_FROM_CPUM(rdx)   
    253 ;;    call    rax
     251    mov     eax, [rdx + CPUM.Hyper.eip]
     252    CPUMCPU_FROM_CPUM(edx)
     253    call    rax
    254254   
    255255    ; Load CPUM pointer into rdx
    256256    mov     rdx, [NAME(pCpumIC) wrt rip]
    257 ;;    CPUMCPU_FROM_CPUM(rdx)
     257    CPUMCPU_FROM_CPUM(edx)
    258258   
    259259    ; Save the return code
    260 ;;    mov     [rdx + CPUMCPU.u32RetCode], eax
     260    mov     [rdx + CPUMCPU.u32RetCode], eax
    261261   
    262262    ; now let's switch back
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