Changeset 34991 in vbox
- Timestamp:
- Dec 13, 2010 11:20:04 AM (14 years ago)
- Location:
- trunk/src/VBox/VMM/VMMSwitcher
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMSwitcher/LegacyandAMD64.mac
r33935 r34991 57 57 ; 58 58 BEGINPROC vmmR0HostToGuest 59 59 %ifdef DEBUG_STUFF 60 60 COM32_S_NEWLINE 61 61 COM32_S_CHAR '^' 62 63 64 62 %endif 63 64 %ifdef VBOX_WITH_STATISTICS 65 65 ; 66 66 ; Switcher stats. … … 69 69 mov edx, 0ffffffffh 70 70 STAM_PROFILE_ADV_START edx 71 71 %endif 72 72 73 73 push ebp … … 85 85 push cs ; allow for far return and restore cs correctly. 86 86 call NAME(vmmR0HostToGuestAsm) 87 88 %ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI 89 CPUM_FROM_CPUMCPU(edx) 90 ; Restore blocked Local APIC NMI vectors 91 mov ecx, [edx + CPUM.fApicDisVectors] 92 mov edx, [edx + CPUM.pvApicBase] 93 shr ecx, 1 94 jnc gth_nolint0 95 and dword [edx + APIC_REG_LVT_LINT0], ~APIC_REG_LVT_MASKED 96 gth_nolint0: 97 shr ecx, 1 98 jnc gth_nolint1 99 and dword [edx + APIC_REG_LVT_LINT1], ~APIC_REG_LVT_MASKED 100 gth_nolint1: 101 shr ecx, 1 102 jnc gth_nopc 103 and dword [edx + APIC_REG_LVT_PC], ~APIC_REG_LVT_MASKED 104 gth_nopc: 105 shr ecx, 1 106 jnc gth_notherm 107 and dword [edx + APIC_REG_LVT_THMR], ~APIC_REG_LVT_MASKED 108 gth_notherm: 109 %endif 87 110 88 111 ; restore original flags … … 626 649 ;mov cr2, ecx 627 650 628 %ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI629 ; Restore blocked Local APIC NMI vectors630 CPUM_FROM_CPUMCPU_WITH_OFFSET edx, ebp631 mov ebx, [edx + CPUM.pvApicBase]632 mov ecx, [edx + CPUM.fApicDisVectors]633 CPUMCPU_FROM_CPUM_WITH_OFFSET edx, ebp634 shr ecx, 1635 jnc gth_nolint0636 and dword [ebx + APIC_REG_LVT_LINT0], ~APIC_REG_LVT_MASKED637 gth_nolint0:638 shr ecx, 1639 jnc gth_nolint1640 and dword [ebx + APIC_REG_LVT_LINT1], ~APIC_REG_LVT_MASKED641 gth_nolint1:642 shr ecx, 1643 jnc gth_nopc644 and dword [ebx + APIC_REG_LVT_PC], ~APIC_REG_LVT_MASKED645 gth_nopc:646 shr ecx, 1647 jnc gth_notherm648 and dword [ebx + APIC_REG_LVT_THMR], ~APIC_REG_LVT_MASKED649 gth_notherm:650 %endif651 652 651 ; restore general registers. 653 652 mov edi, [edx + CPUMCPU.Host.edi] -
trunk/src/VBox/VMM/VMMSwitcher/PAEand32Bit.mac
r33935 r34991 80 80 push cs ; allow for far return and restore cs correctly. 81 81 call NAME(vmmR0HostToGuestAsm) 82 83 %ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI 84 CPUM_FROM_CPUMCPU(edx) 85 ; Restore blocked Local APIC NMI vectors 86 ; Do this here to ensure the host CS is already restored 87 mov ecx, [edx + CPUM.fApicDisVectors] 88 mov edx, [edx + CPUM.pvApicBase] 89 shr ecx, 1 90 jnc gth_nolint0 91 and dword [edx + APIC_REG_LVT_LINT0], ~APIC_REG_LVT_MASKED 92 gth_nolint0: 93 shr ecx, 1 94 jnc gth_nolint1 95 and dword [edx + APIC_REG_LVT_LINT1], ~APIC_REG_LVT_MASKED 96 gth_nolint1: 97 shr ecx, 1 98 jnc gth_nopc 99 and dword [edx + APIC_REG_LVT_PC], ~APIC_REG_LVT_MASKED 100 gth_nopc: 101 shr ecx, 1 102 jnc gth_notherm 103 and dword [edx + APIC_REG_LVT_THMR], ~APIC_REG_LVT_MASKED 104 gth_notherm: 105 %endif 82 106 83 107 %ifdef VBOX_WITH_STATISTICS … … 994 1018 gth_debug_regs_no: 995 1019 996 %ifdef VBOX_WITH_VMMR0_DISABLE_LAPIC_NMI997 mov esi, edx998 CPUM_FROM_CPUMCPU(edx)999 ; Restore blocked Local APIC NMI vectors1000 mov ebx, [edx + CPUM.pvApicBase]1001 mov ecx, [edx + CPUM.fApicDisVectors]1002 mov edx, esi1003 shr ecx, 11004 jnc gth_nolint01005 and dword [ebx + APIC_REG_LVT_LINT0], ~APIC_REG_LVT_MASKED1006 gth_nolint0:1007 shr ecx, 11008 jnc gth_nolint11009 and dword [ebx + APIC_REG_LVT_LINT1], ~APIC_REG_LVT_MASKED1010 gth_nolint1:1011 shr ecx, 11012 jnc gth_nopc1013 and dword [ebx + APIC_REG_LVT_PC], ~APIC_REG_LVT_MASKED1014 gth_nopc:1015 shr ecx, 11016 jnc gth_notherm1017 and dword [ebx + APIC_REG_LVT_THMR], ~APIC_REG_LVT_MASKED1018 gth_notherm:1019 %endif1020 1021 1020 ; restore general registers. 1022 1021 mov eax, edi ; restore return code. eax = return code !!
Note:
See TracChangeset
for help on using the changeset viewer.