Changeset 21656 in vbox for trunk/src/VBox/VMM
- Timestamp:
- Jul 16, 2009 3:49:53 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 50191
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/VMM/HWACCM.cpp
r21653 r21656 1543 1543 rc = PGMPhysSimpleWriteGCPtr(pVCpu, pCtx->rip, aVMMCall, sizeof(aVMMCall)); 1544 1544 AssertRC(rc); 1545 1546 memcpy(pPatch->aNewOpcode, aVMMCall, sizeof(aVMMCall)); 1547 pPatch->cbNewOp = sizeof(aVMMCall); 1545 1548 } 1546 1549 else … … 1567 1570 && pDis->param2.flags == USE_IMMEDIATE8 1568 1571 && pDis->param2.parval == 4 1569 && oldcbOp + cbOp < sizeof(pVM->hwaccm.s.svm.aPatches[idx] ))1572 && oldcbOp + cbOp < sizeof(pVM->hwaccm.s.svm.aPatches[idx].aOpcode)) 1570 1573 { 1571 1574 uint8_t szInstr[15]; … … 1582 1585 szInstr[2] = 0x20; 1583 1586 szInstr[3] = 0xC0 | pDis->param1.base.reg_gen; 1584 for (unsigned i = 4; i < 5+cbOp; i++)1587 for (unsigned i = 4; i < pPatch->cbOp; i++) 1585 1588 szInstr[i] = 0x90; /* nop */ 1586 1589 1587 rc = PGMPhysSimpleWriteGCPtr(pVCpu, pCtx->rip, szInstr, 5+cbOp);1590 rc = PGMPhysSimpleWriteGCPtr(pVCpu, pCtx->rip, szInstr, pPatch->cbOp); 1588 1591 AssertRC(rc); 1592 1593 memcpy(pPatch->aNewOpcode, szInstr, pPatch->cbOp); 1594 pPatch->cbNewOp = pPatch->cbOp; 1589 1595 1590 1596 Log(("Acceptable read/shr candidate!\n")); … … 1598 1604 rc = PGMPhysSimpleWriteGCPtr(pVCpu, pCtx->rip, aVMMCall, sizeof(aVMMCall)); 1599 1605 AssertRC(rc); 1606 1607 memcpy(pPatch->aNewOpcode, aVMMCall, sizeof(aVMMCall)); 1608 pPatch->cbNewOp = sizeof(aVMMCall); 1600 1609 } 1601 1610 }
Note:
See TracChangeset
for help on using the changeset viewer.