Changeset 13872 in vbox
- Timestamp:
- Nov 5, 2008 3:00:48 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 38870
- Location:
- trunk
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/hwaccm.h
r13832 r13872 124 124 */ 125 125 VMMR0DECL(int) HWACCMR0SetupVM(PVM pVM); 126 VMMR0DECL(int) HWACCMR0RunGuestCode(PVM pVM );127 VMMR0DECL(int) HWACCMR0Enter(PVM pVM );128 VMMR0DECL(int) HWACCMR0Leave(PVM pVM );126 VMMR0DECL(int) HWACCMR0RunGuestCode(PVM pVM, RTCPUID idVCpu); 127 VMMR0DECL(int) HWACCMR0Enter(PVM pVM, RTCPUID idVCpu); 128 VMMR0DECL(int) HWACCMR0Leave(PVM pVM, RTCPUID idVCpu); 129 129 VMMR0DECL(int) HWACCMR0InvalidatePage(PVM pVM, RTGCPTR GCVirt); 130 130 VMMR0DECL(int) HWACCMR0FlushTLB(PVM pVM); -
trunk/src/VBox/VMM/HWACCMInternal.h
r13750 r13872 519 519 520 520 /* Dummy callback handlers. */ 521 VMMR0DECL(int) HWACCMR0DummyEnter(PVM pVM, PHWACCM_CPUINFO pCpu);522 VMMR0DECL(int) HWACCMR0DummyLeave(PVM pVM, CPUMCTX *pCtx);521 VMMR0DECL(int) HWACCMR0DummyEnter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu); 522 VMMR0DECL(int) HWACCMR0DummyLeave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 523 523 VMMR0DECL(int) HWACCMR0DummyEnableCpu(PHWACCM_CPUINFO pCpu, PVM pVM, void *pvPageCpu, RTHCPHYS pPageCpuPhys); 524 524 VMMR0DECL(int) HWACCMR0DummyDisableCpu(PHWACCM_CPUINFO pCpu, void *pvPageCpu, RTHCPHYS pPageCpuPhys); … … 526 526 VMMR0DECL(int) HWACCMR0DummyTermVM(PVM pVM); 527 527 VMMR0DECL(int) HWACCMR0DummySetupVM(PVM pVM); 528 VMMR0DECL(int) HWACCMR0DummyRunGuestCode(PVM pVM, CPUMCTX *pCtx);529 VMMR0DECL(int) HWACCMR0DummySaveHostState(PVM pVM );530 VMMR0DECL(int) HWACCMR0DummyLoadGuestState(PVM pVM, CPUMCTX *pCtx);528 VMMR0DECL(int) HWACCMR0DummyRunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 529 VMMR0DECL(int) HWACCMR0DummySaveHostState(PVM pVM, RTCPUID idVCpu); 530 VMMR0DECL(int) HWACCMR0DummyLoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 531 531 532 532 #endif /* IN_RING0 */ -
trunk/src/VBox/VMM/VMMInternal.h
r13832 r13872 450 450 * @param pVM The VM handle. 451 451 */ 452 typedef DECLCALLBACK(int) FNVMMR0SETJMP(PVM pVM );452 typedef DECLCALLBACK(int) FNVMMR0SETJMP(PVM pVM, uint32_t idCpu); 453 453 /** Pointer to FNVMMR0SETJMP(). */ 454 454 typedef FNVMMR0SETJMP *PFNVMMR0SETJMP; … … 466 466 * @param pVM The argument of that function. 467 467 */ 468 DECLASM(int) vmmR0CallHostSetJmp(PVMMR0JMPBUF pJmpBuf, PFNVMMR0SETJMP pfn, PVM pVM );468 DECLASM(int) vmmR0CallHostSetJmp(PVMMR0JMPBUF pJmpBuf, PFNVMMR0SETJMP pfn, PVM pVM, uint32_t idCpu); 469 469 470 470 /** -
trunk/src/VBox/VMM/VMMR0/HWACCMR0.cpp
r13825 r13872 65 65 66 66 /** Ring 0 handlers for VT-x and AMD-V. */ 67 DECLR0CALLBACKMEMBER(int, pfnEnterSession,(PVM pVM, PHWACCM_CPUINFO pCpu));68 DECLR0CALLBACKMEMBER(int, pfnLeaveSession,(PVM pVM, CPUMCTX *pCtx));69 DECLR0CALLBACKMEMBER(int, pfnSaveHostState,(PVM pVM ));70 DECLR0CALLBACKMEMBER(int, pfnLoadGuestState,(PVM pVM, CPUMCTX *pCtx));71 DECLR0CALLBACKMEMBER(int, pfnRunGuestCode,(PVM pVM, CPUMCTX *pCtx));67 DECLR0CALLBACKMEMBER(int, pfnEnterSession,(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu)); 68 DECLR0CALLBACKMEMBER(int, pfnLeaveSession,(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx)); 69 DECLR0CALLBACKMEMBER(int, pfnSaveHostState,(PVM pVM, RTCPUID idVCpu)); 70 DECLR0CALLBACKMEMBER(int, pfnLoadGuestState,(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx)); 71 DECLR0CALLBACKMEMBER(int, pfnRunGuestCode,(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx)); 72 72 DECLR0CALLBACKMEMBER(int, pfnEnableCpu, (PHWACCM_CPUINFO pCpu, PVM pVM, void *pvPageCpu, RTHCPHYS pPageCpuPhys)); 73 73 DECLR0CALLBACKMEMBER(int, pfnDisableCpu, (PHWACCM_CPUINFO pCpu, void *pvPageCpu, RTHCPHYS pPageCpuPhys)); … … 865 865 * @returns VBox status code. 866 866 * @param pVM The VM to operate on. 867 */ 868 VMMR0DECL(int) HWACCMR0Enter(PVM pVM) 867 * @param idVCpu VMCPUD id. 868 */ 869 VMMR0DECL(int) HWACCMR0Enter(PVM pVM, RTCPUID idVCpu) 869 870 { 870 871 PCPUMCTX pCtx; … … 894 895 pVM->hwaccm.s.u64RegisterMask = UINT64_C(0xFFFFFFFF); 895 896 896 rc = HWACCMR0Globals.pfnEnterSession(pVM, pCpu);897 rc = HWACCMR0Globals.pfnEnterSession(pVM, idVCpu, pCpu); 897 898 AssertRC(rc); 898 899 /* We must save the host context here (VT-x) as we might be rescheduled on a different cpu after a long jump back to ring 3. */ 899 rc |= HWACCMR0Globals.pfnSaveHostState(pVM );900 rc |= HWACCMR0Globals.pfnSaveHostState(pVM, idVCpu); 900 901 AssertRC(rc); 901 rc |= HWACCMR0Globals.pfnLoadGuestState(pVM, pCtx);902 rc |= HWACCMR0Globals.pfnLoadGuestState(pVM, idVCpu, pCtx); 902 903 AssertRC(rc); 903 904 … … 919 920 * @returns VBox status code. 920 921 * @param pVM The VM to operate on. 921 */ 922 VMMR0DECL(int) HWACCMR0Leave(PVM pVM) 922 * @param idVCpu VMCPUD id. 923 */ 924 VMMR0DECL(int) HWACCMR0Leave(PVM pVM, RTCPUID idVCpu) 923 925 { 924 926 PCPUMCTX pCtx; … … 944 946 } 945 947 946 rc = HWACCMR0Globals.pfnLeaveSession(pVM, pCtx);948 rc = HWACCMR0Globals.pfnLeaveSession(pVM, idVCpu, pCtx); 947 949 948 950 #ifdef VBOX_STRICT … … 961 963 * @returns VBox status code. 962 964 * @param pVM The VM to operate on. 963 */ 964 VMMR0DECL(int) HWACCMR0RunGuestCode(PVM pVM) 965 * @param idVCpu VMCPUD id. 966 */ 967 VMMR0DECL(int) HWACCMR0RunGuestCode(PVM pVM, RTCPUID idVCpu) 965 968 { 966 969 CPUMCTX *pCtx; … … 978 981 pCtx = CPUMQueryGuestCtxPtr(pVM); 979 982 980 return HWACCMR0Globals.pfnRunGuestCode(pVM, pCtx);983 return HWACCMR0Globals.pfnRunGuestCode(pVM, idVCpu, pCtx); 981 984 } 982 985 … … 1277 1280 1278 1281 /* Dummy callback handlers. */ 1279 VMMR0DECL(int) HWACCMR0DummyEnter(PVM pVM, PHWACCM_CPUINFO pCpu)1282 VMMR0DECL(int) HWACCMR0DummyEnter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu) 1280 1283 { 1281 1284 return VINF_SUCCESS; 1282 1285 } 1283 1286 1284 VMMR0DECL(int) HWACCMR0DummyLeave(PVM pVM, PCPUMCTX pCtx)1287 VMMR0DECL(int) HWACCMR0DummyLeave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 1285 1288 { 1286 1289 return VINF_SUCCESS; … … 1312 1315 } 1313 1316 1314 VMMR0DECL(int) HWACCMR0DummyRunGuestCode(PVM pVM, CPUMCTX *pCtx)1317 VMMR0DECL(int) HWACCMR0DummyRunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 1315 1318 { 1316 1319 return VINF_SUCCESS; 1317 1320 } 1318 1321 1319 VMMR0DECL(int) HWACCMR0DummySaveHostState(PVM pVM )1322 VMMR0DECL(int) HWACCMR0DummySaveHostState(PVM pVM, RTCPUID idVCpu) 1320 1323 { 1321 1324 return VINF_SUCCESS; 1322 1325 } 1323 1326 1324 VMMR0DECL(int) HWACCMR0DummyLoadGuestState(PVM pVM, CPUMCTX *pCtx)1327 VMMR0DECL(int) HWACCMR0DummyLoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 1325 1328 { 1326 1329 return VINF_SUCCESS; -
trunk/src/VBox/VMM/VMMR0/HWSVMR0.cpp
r13825 r13872 514 514 * @returns VBox status code. 515 515 * @param pVM The VM to operate on. 516 * @param idVCpu VPCPU id. 516 517 */ 517 VMMR0DECL(int) SVMR0SaveHostState(PVM pVM )518 VMMR0DECL(int) SVMR0SaveHostState(PVM pVM, RTCPUID idVCpu) 518 519 { 520 NOREF(pVM); 521 NOREF(idVCpu); 519 522 /* Nothing to do here. */ 520 523 return VINF_SUCCESS; … … 524 527 * Loads the guest state 525 528 * 526 * NOTE: Don't do anything here that can cause a jump back to ring 3!!!!!527 *528 529 * @returns VBox status code. 529 530 * @param pVM The VM to operate on. 531 * @param idVCpu VPCPU id. 530 532 * @param pCtx Guest context 531 533 */ 532 VMMR0DECL(int) SVMR0LoadGuestState(PVM pVM, CPUMCTX *pCtx)534 VMMR0DECL(int) SVMR0LoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 533 535 { 534 536 RTGCUINTPTR val; … … 781 783 782 784 /** 783 * Runs guest code in an SVM VM. 784 * 785 * @todo This can be much more efficient, when we only sync that which has actually changed. (this is the first attempt only) 785 * Runs guest code in an AMD-V VM. 786 786 * 787 787 * @returns VBox status code. 788 788 * @param pVM The VM to operate on. 789 * @param idVCpu VPCPU id. 789 790 * @param pCtx Guest context 790 791 */ 791 VMMR0DECL(int) SVMR0RunGuestCode(PVM pVM, CPUMCTX *pCtx)792 VMMR0DECL(int) SVMR0RunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 792 793 { 793 794 int rc = VINF_SUCCESS; … … 931 932 932 933 /* Load the guest state; *must* be here as it sets up the shadow cr0 for lazy fpu syncing! */ 933 rc = SVMR0LoadGuestState(pVM, pCtx);934 rc = SVMR0LoadGuestState(pVM, idVCpu, pCtx); 934 935 if (rc != VINF_SUCCESS) 935 936 { … … 2045 2046 * @returns VBox status code. 2046 2047 * @param pVM The VM to operate on. 2048 * @param idVCpu VPCPU id. 2047 2049 * @param pCpu CPU info struct 2048 2050 */ 2049 VMMR0DECL(int) SVMR0Enter(PVM pVM, PHWACCM_CPUINFO pCpu)2051 VMMR0DECL(int) SVMR0Enter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu) 2050 2052 { 2051 2053 Assert(pVM->hwaccm.s.svm.fSupported); … … 2066 2068 * @returns VBox status code. 2067 2069 * @param pVM The VM to operate on. 2070 * @param idVCpu VPCPU id. 2068 2071 * @param pCtx CPU context 2069 2072 */ 2070 VMMR0DECL(int) SVMR0Leave(PVM pVM, PCPUMCTX pCtx)2073 VMMR0DECL(int) SVMR0Leave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 2071 2074 { 2072 2075 SVM_VMCB *pVMCB = (SVM_VMCB *)pVM->hwaccm.s.svm.pVMCB; -
trunk/src/VBox/VMM/VMMR0/HWSVMR0.h
r13514 r13872 47 47 * @returns VBox status code. 48 48 * @param pVM The VM to operate on. 49 * @param idVCpu VPCPU id. 49 50 * @param pCpu CPU info struct 50 51 */ 51 VMMR0DECL(int) SVMR0Enter(PVM pVM, PHWACCM_CPUINFO pCpu);52 VMMR0DECL(int) SVMR0Enter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu); 52 53 53 54 /** … … 56 57 * @returns VBox status code. 57 58 * @param pVM The VM to operate on. 59 * @param idVCpu VPCPU id. 58 60 * @param pCtx CPU context 59 61 */ 60 VMMR0DECL(int) SVMR0Leave(PVM pVM, PCPUMCTX pCtx);62 VMMR0DECL(int) SVMR0Leave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 61 63 62 64 /** … … 111 113 * @returns VBox status code. 112 114 * @param pVM The VM to operate on. 115 * @param idVCpu VPCPU id. 113 116 * @param pCtx Guest context 114 117 */ 115 VMMR0DECL(int) SVMR0RunGuestCode(PVM pVM, CPUMCTX *pCtx);118 VMMR0DECL(int) SVMR0RunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 116 119 117 120 … … 121 124 * @returns VBox status code. 122 125 * @param pVM The VM to operate on. 126 * @param idVCpu VPCPU id. 123 127 */ 124 VMMR0DECL(int) SVMR0SaveHostState(PVM pVM );128 VMMR0DECL(int) SVMR0SaveHostState(PVM pVM, RTCPUID idVCpu); 125 129 126 130 /** … … 129 133 * @returns VBox status code. 130 134 * @param pVM The VM to operate on. 135 * @param idVCpu VPCPU id. 131 136 * @param pCtx Guest context 132 137 */ 133 VMMR0DECL(int) SVMR0LoadGuestState(PVM pVM, CPUMCTX *pCtx);138 VMMR0DECL(int) SVMR0LoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 134 139 135 140 -
trunk/src/VBox/VMM/VMMR0/HWVMXR0.cpp
r13825 r13872 755 755 * @returns VBox status code. 756 756 * @param pVM The VM to operate on. 757 * @param idVCpu VPCPU id. 757 758 */ 758 VMMR0DECL(int) VMXR0SaveHostState(PVM pVM )759 VMMR0DECL(int) VMXR0SaveHostState(PVM pVM, RTCPUID idVCpu) 759 760 { 760 761 int rc = VINF_SUCCESS; … … 935 936 * @returns VBox status code. 936 937 * @param pVM The VM to operate on. 938 * @param idVCpu VPCPU id. 937 939 * @param pCtx Guest context 938 940 */ 939 VMMR0DECL(int) VMXR0LoadGuestState(PVM pVM, CPUMCTX *pCtx)941 VMMR0DECL(int) VMXR0LoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 940 942 { 941 943 int rc = VINF_SUCCESS; … … 1675 1677 * @returns VBox status code. 1676 1678 * @param pVM The VM to operate on. 1679 * @param idVCpu VPCPU id. 1677 1680 * @param pCtx Guest context 1678 1681 */ 1679 VMMR0DECL(int) VMXR0RunGuestCode(PVM pVM, CPUMCTX *pCtx)1682 VMMR0DECL(int) VMXR0RunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 1680 1683 { 1681 1684 int rc = VINF_SUCCESS; … … 1883 1886 #endif 1884 1887 /* Save the host state first. */ 1885 rc = VMXR0SaveHostState(pVM );1888 rc = VMXR0SaveHostState(pVM, idVCpu); 1886 1889 if (rc != VINF_SUCCESS) 1887 1890 { … … 1890 1893 } 1891 1894 /* Load the guest state */ 1892 rc = VMXR0LoadGuestState(pVM, pCtx);1895 rc = VMXR0LoadGuestState(pVM, idVCpu, pCtx); 1893 1896 if (rc != VINF_SUCCESS) 1894 1897 { … … 2960 2963 * @returns VBox status code. 2961 2964 * @param pVM The VM to operate on. 2965 * @param idVCpu VPCPU id. 2962 2966 * @param pCpu CPU info struct 2963 2967 */ 2964 VMMR0DECL(int) VMXR0Enter(PVM pVM, PHWACCM_CPUINFO pCpu)2968 VMMR0DECL(int) VMXR0Enter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu) 2965 2969 { 2966 2970 Assert(pVM->hwaccm.s.vmx.fSupported); … … 2988 2992 * @returns VBox status code. 2989 2993 * @param pVM The VM to operate on. 2994 * @param idVCpu VPCPU id. 2990 2995 * @param pCtx CPU context 2991 2996 */ 2992 VMMR0DECL(int) VMXR0Leave(PVM pVM, PCPUMCTX pCtx)2997 VMMR0DECL(int) VMXR0Leave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx) 2993 2998 { 2994 2999 Assert(pVM->hwaccm.s.vmx.fSupported); -
trunk/src/VBox/VMM/VMMR0/HWVMXR0.h
r13514 r13872 47 47 * @returns VBox status code. 48 48 * @param pVM The VM to operate on. 49 * @param idVCpu VPCPU id. 49 50 * @param pCpu CPU info struct 50 51 */ 51 VMMR0DECL(int) VMXR0Enter(PVM pVM m, PHWACCM_CPUINFO pCpu);52 VMMR0DECL(int) VMXR0Enter(PVM pVM, RTCPUID idVCpu, PHWACCM_CPUINFO pCpu); 52 53 53 54 /** … … 56 57 * @returns VBox status code. 57 58 * @param pVM The VM to operate on. 59 * @param idVCpu VPCPU id. 58 60 * @param pCtx CPU context 59 61 */ 60 VMMR0DECL(int) VMXR0Leave(PVM pVM, PCPUMCTX pCtx);62 VMMR0DECL(int) VMXR0Leave(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 61 63 62 64 … … 112 114 * @returns VBox status code. 113 115 * @param pVM The VM to operate on. 114 */ 115 VMMR0DECL(int) VMXR0SaveHostState(PVM pVM); 116 * @param idVCpu VPCPU id. 117 */ 118 VMMR0DECL(int) VMXR0SaveHostState(PVM pVM, RTCPUID idVCpu); 116 119 117 120 /** … … 120 123 * @returns VBox status code. 121 124 * @param pVM The VM to operate on. 122 * @param pCtx Guest context 123 */ 124 VMMR0DECL(int) VMXR0LoadGuestState(PVM pVM, CPUMCTX *pCtx); 125 * @param idVCpu VPCPU id. 126 * @param pCtx Guest context 127 */ 128 VMMR0DECL(int) VMXR0LoadGuestState(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 125 129 126 130 … … 130 134 * @returns VBox status code. 131 135 * @param pVM The VM to operate on. 132 * @param pCtx Guest context 133 */ 134 VMMR0DECL(int) VMXR0RunGuestCode(PVM pVM, CPUMCTX *pCtx); 136 * @param idVCpu VPCPU id. 137 * @param pCtx Guest context 138 */ 139 VMMR0DECL(int) VMXR0RunGuestCode(PVM pVM, RTCPUID idVCpu, PCPUMCTX pCtx); 135 140 136 141 -
trunk/src/VBox/VMM/VMMR0/VMMR0.cpp
r13871 r13872 633 633 if (!HWACCMR0SuspendPending()) 634 634 { 635 rc = HWACCMR0Enter(pVM );635 rc = HWACCMR0Enter(pVM, idCPU); 636 636 if (RT_SUCCESS(rc)) 637 637 { 638 rc = vmmR0CallHostSetJmp(&pVM->vmm.s.CallHostR0JmpBuf, HWACCMR0RunGuestCode, pVM ); /* this may resume code. */639 int rc2 = HWACCMR0Leave(pVM );638 rc = vmmR0CallHostSetJmp(&pVM->vmm.s.CallHostR0JmpBuf, HWACCMR0RunGuestCode, pVM, idCPU); /* this may resume code. */ 639 int rc2 = HWACCMR0Leave(pVM, idCPU); 640 640 AssertRC(rc2); 641 641 } -
trunk/src/VBox/VMM/VMMR0/VMMR0A.asm
r8155 r13872 44 44 ; 45 45 ; @returns VINF_SUCCESS on success or whatever is passed to vmmR0CallHostLongJmp. 46 ; @param pJmpBuf msc:rcx gcc:rdi x86:[esp+4] Our jmp_buf. 47 ; @param pfn msc:rdx gcc:rsi x86:[esp+8] The function to be called when not resuming. 48 ; @param pvUser msc:r8 gcc:rdx x86:[esp+c] The argument of that function. 46 ; @param pJmpBuf msc:rcx gcc:rdi x86:[esp+0x04] Our jmp_buf. 47 ; @param pfn msc:rdx gcc:rsi x86:[esp+0x08] The function to be called when not resuming. 48 ; @param pvUser1 msc:r8 gcc:rdx x86:[esp+0x0c] The argument of that function. 49 ; @param pvUser2 msc:r9 gcc:rcx x86:[esp+0x10] The argument of that function. 49 50 ; 50 51 BEGINPROC vmmR0CallHostSetJmp … … 70 71 jnz .resume 71 72 72 mov ecx, [esp + 0ch] ; pvArg 73 mov ecx, [esp + 0ch] ; pvArg1 74 mov edx, [esp + 10h] ; pvArg2 73 75 mov eax, [esp + 08h] ; pfn 74 sub esp, 1 2; align the stack on a 16-byte boundrary.76 sub esp, 16 ; align the stack on a 16-byte boundrary. 75 77 mov [esp], ecx 78 mov [esp+4], edx 76 79 call eax 77 add esp, 1 280 add esp, 16 78 81 mov edx, [esp + 4h] ; pJmpBuf 79 82 … … 149 152 %else 150 153 sub rsp, 10h 151 mov r8, rdx ; pvUser (save it like MSC) 154 mov r8, rdx ; pvUser1 (save it like MSC) 155 mov r9, rcx ; pvUser2 (save it like MSC) 152 156 mov r11, rsi ; pfn 153 157 mov rdx, rdi ; pJmpBuf … … 178 182 %ifdef ASM_CALL64_MSC 179 183 mov rcx, r8 ; pvUser -> arg0 184 mov rdx, r9 180 185 %else 181 186 mov rdi, r8 ; pvUser -> arg0 187 mov rsi, r9 182 188 %endif 183 189 call r11 -
trunk/src/VBox/VMM/testcase/tstVMMR0CallHost-1.cpp
r11822 r13872 60 60 61 61 62 DECLCALLBACK(int) tst2(intptr_t i )62 DECLCALLBACK(int) tst2(intptr_t i, intptr_t i2) 63 63 { 64 64 if (i < 0 || i > 8192) 65 65 { 66 66 RTPrintf("tstVMMR0CallHost-1: FAILURE - i=%d is out of range [0..8192]\n", i); 67 return 1; 68 } 69 if (i2 != 0) 70 { 71 RTPrintf("tstVMMR0CallHost-1: FAILURE - i2=%d is out of range [0]\n", i2); 67 72 return 1; 68 73 } … … 81 86 for (int i = iFrom; i < iTo; i += iInc) 82 87 { 83 int rc = vmmR0CallHostSetJmp(&g_Jmp, (PFNVMMR0SETJMP)tst2, (PVM)i );88 int rc = vmmR0CallHostSetJmp(&g_Jmp, (PFNVMMR0SETJMP)tst2, (PVM)i, 0); 84 89 if (rc != 0 && rc != 42) 85 90 {
Note:
See TracChangeset
for help on using the changeset viewer.