Changeset 13816 in vbox for trunk/src/VBox/VMM/VMMGC
- Timestamp:
- Nov 4, 2008 10:52:12 PM (16 years ago)
- Location:
- trunk/src/VBox/VMM/VMMGC
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/VMMGC/MMRamGC.cpp
r12989 r13816 109 109 rc = MMGCRamReadNoTrapHandler(pDst, pSrc, cb); 110 110 MMGCRamDeregisterTrapHandler(pVM); 111 if ( VBOX_FAILURE(rc))111 if (RT_FAILURE(rc)) 112 112 TRPMRestoreTrap(pVM); 113 113 … … 132 132 int rc = MMGCRamWriteNoTrapHandler(pDst, pSrc, cb); 133 133 MMGCRamDeregisterTrapHandler(pVM); 134 if ( VBOX_FAILURE(rc))134 if (RT_FAILURE(rc)) 135 135 TRPMRestoreTrap(pVM); 136 136 -
trunk/src/VBox/VMM/VMMGC/SELMGC.cpp
r13577 r13816 66 66 X86DESC Desc; 67 67 int rc = MMGCRamRead(pVM, &Desc, (uint8_t *)GdtrGuest.pGdt + offEntry, sizeof(X86DESC)); 68 if ( VBOX_FAILURE(rc))68 if (RT_FAILURE(rc)) 69 69 return VINF_EM_RAW_EMULATE_INSTR_GDT_FAULT; 70 70 … … 201 201 uint32_t cb; 202 202 rc = EMInterpretInstruction(pVM, pRegFrame, (RTGCPTR)(RTRCUINTPTR)pvFault, &cb); 203 if ( VBOX_SUCCESS(rc) && cb)203 if (RT_SUCCESS(rc) && cb) 204 204 { 205 205 unsigned iGDTE1 = offRange / sizeof(X86DESC); … … 217 217 } 218 218 } 219 if (rc == VINF_SUCCESS || VBOX_FAILURE(rc2))219 if (rc == VINF_SUCCESS || RT_FAILURE(rc2)) 220 220 rc = rc2; 221 221 } 222 222 else 223 223 { 224 Assert( VBOX_FAILURE(rc));224 Assert(RT_FAILURE(rc)); 225 225 if (rc == VERR_EM_INTERPRETER) 226 226 rc = VINF_EM_RAW_EMULATE_INSTR_GDT_FAULT; … … 287 287 uint32_t cb; 288 288 int rc = EMInterpretInstruction(pVM, pRegFrame, (RTGCPTR)(RTRCUINTPTR)pvFault, &cb); 289 if ( VBOX_SUCCESS(rc) && cb)289 if (RT_SUCCESS(rc) && cb) 290 290 { 291 291 PCVBOXTSS pGuestTSS = (PVBOXTSS)pVM->selm.s.GCPtrGuestTss; … … 313 313 { 314 314 rc = MMGCRamRead(pVM, &pVM->selm.s.Tss.IntRedirBitmap[i * 8], (uint8_t *)pGuestTSS + offIntRedirBitmap + i * 8, 8); 315 if ( VBOX_FAILURE(rc))315 if (RT_FAILURE(rc)) 316 316 { 317 317 /* Shadow page table might be out of sync */ 318 318 rc = PGMPrefetchPage(pVM, (RTGCPTR)(RTRCUINTPTR)((uint8_t *)pGuestTSS + offIntRedirBitmap + i*8)); 319 if ( VBOX_FAILURE(rc))319 if (RT_FAILURE(rc)) 320 320 { 321 321 AssertMsg(rc == VINF_SUCCESS, ("PGMPrefetchPage %VGv failed with %Vrc\n", (uint8_t *)pGuestTSS + offIntRedirBitmap + i*8, rc)); … … 333 333 else 334 334 { 335 Assert( VBOX_FAILURE(rc));335 Assert(RT_FAILURE(rc)); 336 336 VM_FF_SET(pVM, VM_FF_SELM_SYNC_TSS); 337 337 STAM_COUNTER_INC(&pVM->selm.s.StatRCWriteGuestTSSUnhandled); … … 427 427 #endif 428 428 429 if ( VBOX_FAILURE(rc))429 if (RT_FAILURE(rc)) 430 430 { 431 431 if (!fTriedAlready) -
trunk/src/VBox/VMM/VMMGC/TRPMGC.cpp
r13635 r13816 126 126 uint32_t cb; 127 127 int rc = EMInterpretInstruction(pVM, pRegFrame, pvFault, &cb); 128 if ( VBOX_SUCCESS(rc) && cb)128 if (RT_SUCCESS(rc) && cb) 129 129 { 130 130 uint32_t iGate1 = (offRange + cb - 1)/sizeof(VBOXIDTE); -
trunk/src/VBox/VMM/VMMGC/TRPMGCHandlers.cpp
r13698 r13816 359 359 RTGCPTR PC; 360 360 rc = SELMValidateAndConvertCSAddr(pVM, pRegFrame->eflags, pRegFrame->ss, pRegFrame->cs, &pRegFrame->csHid, (RTGCPTR)pRegFrame->eip, &PC); 361 if ( VBOX_FAILURE(rc))361 if (RT_FAILURE(rc)) 362 362 { 363 363 Log(("TRPMGCTrap06Handler: Failed to convert %RTsel:%RX32 (cpl=%d) - rc=%Vrc !!\n", pRegFrame->cs, pRegFrame->eip, pRegFrame->ss & X86_SEL_RPL, rc)); … … 368 368 uint32_t cbOp; 369 369 rc = EMInterpretDisasOneEx(pVM, (RTGCUINTPTR)PC, pRegFrame, &Cpu, &cbOp); 370 if ( VBOX_FAILURE(rc))370 if (RT_FAILURE(rc)) 371 371 return trpmGCExitTrap(pVM, VINF_EM_RAW_EMULATE_INSTR, pRegFrame); 372 372 … … 406 406 uint32_t cbIgnored; 407 407 rc = EMInterpretInstructionCPU(pVM, &Cpu, pRegFrame, PC, &cbIgnored); 408 if (RT_LIKELY( VBOX_SUCCESS(rc)))408 if (RT_LIKELY(RT_SUCCESS(rc))) 409 409 pRegFrame->eip += Cpu.opsize; 410 410 } … … 583 583 } 584 584 rc = TRPMForwardTrap(pVM, pRegFrame, (uint32_t)pCpu->param1.parval, pCpu->opsize, TRPM_TRAP_NO_ERRORCODE, TRPM_SOFTWARE_INT, 0xd); 585 if ( VBOX_SUCCESS(rc) && rc != VINF_EM_RAW_GUEST_TRAP)585 if (RT_SUCCESS(rc) && rc != VINF_EM_RAW_GUEST_TRAP) 586 586 return trpmGCExitTrap(pVM, VINF_SUCCESS, pRegFrame); 587 587 … … 627 627 uint32_t cbIgnored; 628 628 rc = EMInterpretInstructionCPU(pVM, pCpu, pRegFrame, PC, &cbIgnored); 629 if ( VBOX_SUCCESS(rc))629 if (RT_SUCCESS(rc)) 630 630 pRegFrame->eip += pCpu->opsize; 631 631 else if (rc == VERR_EM_INTERPRETER) … … 674 674 Assert(pCpu->param1.flags & USE_IMMEDIATE8); 675 675 rc = TRPMForwardTrap(pVM, pRegFrame, (uint32_t)pCpu->param1.parval, pCpu->opsize, TRPM_TRAP_NO_ERRORCODE, TRPM_SOFTWARE_INT, 0xd); 676 if ( VBOX_SUCCESS(rc) && rc != VINF_EM_RAW_GUEST_TRAP)676 if (RT_SUCCESS(rc) && rc != VINF_EM_RAW_GUEST_TRAP) 677 677 return trpmGCExitTrap(pVM, VINF_SUCCESS, pRegFrame); 678 678 … … 705 705 uint32_t cbIgnored; 706 706 rc = EMInterpretInstructionCPU(pVM, pCpu, pRegFrame, PC, &cbIgnored); 707 if ( VBOX_SUCCESS(rc))707 if (RT_SUCCESS(rc)) 708 708 pRegFrame->eip += pCpu->opsize; 709 709 else if (rc == VERR_EM_INTERPRETER) -
trunk/src/VBox/VMM/VMMGC/VMMGC.cpp
r13813 r13816 301 301 */ 302 302 rc = TRPMGCSetTempHandler(pVM, X86_XCPT_PF, uArg != 4 ? vmmGCTestTmpPFHandler : vmmGCTestTmpPFHandlerCorruptFS); 303 if ( VBOX_SUCCESS(rc))303 if (RT_SUCCESS(rc)) 304 304 { 305 305 rc = vmmGCTestTrap0e(); … … 307 307 /* in case it didn't fire. */ 308 308 int rc2 = TRPMGCSetTempHandler(pVM, X86_XCPT_PF, NULL); 309 if ( VBOX_FAILURE(rc2) && VBOX_SUCCESS(rc))309 if (RT_FAILURE(rc2) && RT_SUCCESS(rc)) 310 310 rc = rc2; 311 311 } … … 329 329 * 330 330 * @returns VBox status code (appropriate for GC return). 331 * In this context VBOX_SUCCESS means to restart the instruction.331 * In this context RT_SUCCESS means to restart the instruction. 332 332 * @param pVM VM handle. 333 333 * @param pRegFrame Trap register frame. … … 348 348 * 349 349 * @returns VBox status code (appropriate for GC return). 350 * In this context VBOX_SUCCESS means to restart the instruction.350 * In this context RT_SUCCESS means to restart the instruction. 351 351 * @param pVM VM handle. 352 352 * @param pRegFrame Trap register frame.
Note:
See TracChangeset
for help on using the changeset viewer.