Changeset 18677 in vbox
- Timestamp:
- Apr 3, 2009 11:03:49 AM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 45612
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/pgm.h
r18660 r18677 346 346 VMMDECL(int) PGMHandlerPhysicalPageAlias(PVM pVM, RTGCPHYS GCPhys, RTGCPHYS GCPhysPage, RTGCPHYS GCPhysPageRemap); 347 347 VMMDECL(int) PGMHandlerPhysicalReset(PVM pVM, RTGCPHYS GCPhys); 348 VMMDECL(int) PGMHandlerPhysicalPageReset(PVM pVM, RTGCPHYS GCPhys, RTGCPHYS GCPhysPage);349 348 VMMDECL(bool) PGMHandlerPhysicalIsRegistered(PVM pVM, RTGCPHYS GCPhys); 350 349 VMMDECL(bool) PGMHandlerVirtualIsRegistered(PVM pVM, RTGCPTR GCPtr); -
trunk/src/VBox/VMM/VMMAll/PGMAllHandler.cpp
r18666 r18677 1050 1050 1051 1051 1052 #if 0/**@todo delete this. */1053 /**1054 * Turns access monitoring of a page within a monitored1055 * physical write/all page access handler regio back on.1056 *1057 * The caller must do required page table modifications.1058 *1059 * @returns VBox status code.1060 * @param pVM VM Handle1061 * @param GCPhys Start physical address earlier passed to PGMR3HandlerPhysicalRegister().1062 * This must be a fully page aligned range or we risk messing up other1063 * handlers installed for the start and end pages.1064 * @param GCPhysPage Physical address of the page to turn on access monitoring for.1065 */1066 VMMDECL(int) PGMHandlerPhysicalPageReset(PVM pVM, RTGCPHYS GCPhys, RTGCPHYS GCPhysPage)1067 {1068 /*1069 * Validate the range.1070 */1071 PPGMPHYSHANDLER pCur = (PPGMPHYSHANDLER)RTAvlroGCPhysGet(&pVM->pgm.s.CTX_SUFF(pTrees)->PhysHandlers, GCPhys);1072 if (RT_LIKELY(pCur))1073 {1074 if (RT_LIKELY( GCPhysPage >= pCur->Core.Key1075 && GCPhysPage <= pCur->Core.KeyLast))1076 {1077 Assert(!(pCur->Core.Key & PAGE_OFFSET_MASK));1078 Assert((pCur->Core.KeyLast & PAGE_OFFSET_MASK) == PAGE_OFFSET_MASK);1079 1080 AssertReturn( pCur->enmType == PGMPHYSHANDLERTYPE_PHYSICAL_WRITE1081 || pCur->enmType == PGMPHYSHANDLERTYPE_PHYSICAL_ALL1082 || pCur->enmType == PGMPHYSHANDLERTYPE_MMIO,1083 VERR_ACCESS_DENIED);1084 1085 /*1086 * Change the page status.1087 */1088 PPGMPAGE pPage;1089 int rc = pgmPhysGetPageEx(&pVM->pgm.s, GCPhysPage, &pPage);1090 AssertRCReturn(rc, rc);1091 PGM_PAGE_SET_HNDL_PHYS_STATE(pPage, pgmHandlerPhysicalCalcState(pCur));1092 1093 #ifndef IN_RC1094 HWACCMInvalidatePhysPage(pVM, GCPhysPage);1095 #endif1096 return VINF_SUCCESS;1097 }1098 1099 AssertMsgFailed(("The page %#x is outside the range %#x-%#x\n",1100 GCPhysPage, pCur->Core.Key, pCur->Core.KeyLast));1101 return VERR_INVALID_PARAMETER;1102 }1103 1104 AssertMsgFailed(("Specified physical handler start address %#x is invalid.\n", GCPhys));1105 return VERR_PGM_HANDLER_NOT_FOUND;1106 }1107 #endif1108 1109 1110 1052 /** 1111 1053 * Checks if a physical range is handled
Note:
See TracChangeset
for help on using the changeset viewer.