VirtualBox

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


Ignore:
Timestamp:
Jun 5, 2009 3:54:01 PM (16 years ago)
Author:
vboxsync
Message:

Updates

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR0/HWSVMR0.cpp

    r20343 r20344  
    24062406static int svmR0ReplaceTprInstr(PVM pVM, PVMCPU pVCpu, PCPUMCTX pCtx)
    24072407{
     2408    RTGCPTR     oldrip = pCtx->rip;
    24082409    DISCPUSTATE Cpu;
    2409     unsigned cbOp;
     2410    unsigned    cbOp;
    24102411
    24112412    Log(("Replace TPR access at %RGv\n", pCtx->rip));
     
    24162417        &&  Cpu.pCurInstr->opcode == OP_MOV)
    24172418    {
    2418         rc = svmR0EmulateTprMov(pVCpu, &Cpu, pCtx, cbOp);
    2419         if (rc != VINF_SUCCESS)
    2420             return rc;
    2421 
    24222419        uint8_t szInstr[15];
    24232420        if (    cbOp == 10
     
    24412438             * it does, then we can safely use it ourselves.
    24422439             */
     2440            pCtx->rip += cbOp;
    24432441            rc = EMInterpretDisasOne(pVM, pVCpu, CPUMCTX2CORE(pCtx), &Cpu, &cbOp);
     2442            pCtx->rip = oldrip;
    24442443            if (    rc == VINF_SUCCESS
    24452444                &&  Cpu.pCurInstr->opcode == OP_MOV
     
    24802479                 *   mov ecx, dword [fffe0080]        (5 bytes)
    24812480                 */
     2481                pCtx->rip += cbOp;
    24822482                rc = EMInterpretDisasOne(pVM, pVCpu, CPUMCTX2CORE(pCtx), &Cpu, &cbOp);
     2483                pCtx->rip = oldrip;
    24832484                if (    rc == VINF_SUCCESS
    24842485                    &&  Cpu.pCurInstr->opcode == OP_MOV
     
    25272528                 *   shr eax, 4
    25282529                 */
     2530                pCtx->rip += cbOp;
    25292531                rc = EMInterpretDisasOne(pVM, pVCpu, CPUMCTX2CORE(pCtx), &Cpu, &cbOp);
     2532                pCtx->rip = oldrip;
    25302533                if (    rc == VINF_SUCCESS
    25312534                    &&  Cpu.pCurInstr->opcode == OP_SHR
     
    25512554            }
    25522555        }
     2556        rc = svmR0EmulateTprMov(pVCpu, &Cpu, pCtx, cbOp);
     2557        if (rc != VINF_SUCCESS)
     2558            return rc;
     2559
    25532560        /* Emulated successfully, so continue. */
    25542561        return VINF_SUCCESS;
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