Changeset 17251 in vbox for trunk/include
- Timestamp:
- Mar 2, 2009 1:55:31 PM (16 years ago)
- svn:sync-xref-src-repo-rev:
- 43584
- Location:
- trunk/include/VBox
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/VBox/mm.h
r14597 r17251 44 44 */ 45 45 46 #ifndef VBOX_WITH_NEW_PHYS_CODE 46 47 /** @name RAM Page Flags 47 48 * Since internal ranges have a byte granularity it's possible for a … … 53 54 * @{ 54 55 */ 55 #if 156 56 /** Reserved - Not RAM, ROM nor MMIO2. 57 57 * If this bit is cleared the memory is assumed to be some kind of RAM. … … 82 82 */ 83 83 #define MM_RAM_FLAGS_MMIO2 RT_BIT(3) 84 #endif 85 86 #ifndef VBOX_WITH_NEW_PHYS_CODE 84 87 85 /** Physical backing memory is allocated dynamically. Not set implies a one time static allocation. */ 88 86 #define MM_RAM_FLAGS_DYNAMIC_ALLOC RT_BIT(11) 89 #endif /* !VBOX_WITH_NEW_PHYS_CODE */90 87 91 88 /** The shift used to get the reference count. */ … … 107 104 /** @} */ 108 105 109 #ifndef VBOX_WITH_NEW_PHYS_CODE110 106 /** @name MMR3PhysRegisterEx registration type 111 107 * @{ … … 121 117 } MMPHYSREG; 122 118 /** @} */ 123 #endif 119 #endif /* !VBOX_WITH_NEW_PHYS_CODE */ 124 120 125 121 /** … … 353 349 * @ingroup grp_mm_r3 354 350 * @{ */ 351 #ifndef VBOX_WITH_NEW_PHYS_CODE 355 352 VMMR3DECL(int) MMR3PhysRegister(PVM pVM, void *pvRam, RTGCPHYS GCPhys, unsigned cb, unsigned fFlags, const char *pszDesc); 356 #ifndef VBOX_WITH_NEW_PHYS_CODE357 353 VMMR3DECL(int) MMR3PhysRegisterEx(PVM pVM, void *pvRam, RTGCPHYS GCPhys, unsigned cb, unsigned fFlags, MMPHYSREG enmType, const char *pszDesc); 358 #endif359 354 VMMR3DECL(int) MMR3PhysRomRegister(PVM pVM, PPDMDEVINS pDevIns, RTGCPHYS GCPhys, RTUINT cbRange, const void *pvBinary, bool fShadow, const char *pszDesc); 360 355 VMMR3DECL(int) MMR3PhysRomProtect(PVM pVM, RTGCPHYS GCPhys, RTUINT cbRange); 361 356 VMMR3DECL(int) MMR3PhysReserve(PVM pVM, RTGCPHYS GCPhys, RTUINT cbRange, const char *pszDesc); 357 #endif 362 358 VMMR3DECL(uint64_t) MMR3PhysGetRamSize(PVM pVM); 363 359 /** @} */ -
trunk/include/VBox/pdmdev.h
r16021 r17251 41 41 #include <VBox/cfgm.h> 42 42 #include <VBox/dbgf.h> 43 #include <VBox/mm.h> 43 #ifndef VBOX_WITH_NEW_PHYS_CODE 44 # include <VBox/mm.h> 45 #endif 44 46 #include <VBox/err.h> 45 47 #include <VBox/pci.h> … … 2660 2662 2661 2663 /** 2662 * Write protects a shadow ROM mapping. 2663 * 2664 * This is intented for use by the system BIOS or by the device that 2665 * employs a shadow ROM BIOS, so that the shadow ROM mapping can be 2666 * write protected once the POST is over. 2664 * Changes the protection of shadowed ROM mapping. 2665 * 2666 * This is intented for use by the system BIOS, chipset or device in question to 2667 * change the protection of shadowed ROM code after init and on reset. 2667 2668 * 2668 2669 * @param pDevIns Device instance. 2669 * @param GCPhysStart Where the shadow ROM mapping starts. 2670 * @param cbRange The size of the shadow ROM mapping. 2671 */ 2672 DECLR3CALLBACKMEMBER(int, pfnROMProtectShadow,(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTUINT cbRange)); 2670 * @param GCPhysStart Where the mapping starts. 2671 * @param cbRange The size of the mapping. 2672 * @param enmProt The new protection type. 2673 */ 2674 DECLR3CALLBACKMEMBER(int, pfnROMProtectShadow,(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTUINT cbRange, PGMROMPROT enmProt)); 2673 2675 2674 2676 /** … … 3294 3296 * @copydoc PDMDEVHLPR3::pfnROMProtectShadow 3295 3297 */ 3296 DECLINLINE(int) PDMDevHlpROMProtectShadow(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTUINT cbRange )3297 { 3298 return pDevIns->pDevHlpR3->pfnROMProtectShadow(pDevIns, GCPhysStart, cbRange );3298 DECLINLINE(int) PDMDevHlpROMProtectShadow(PPDMDEVINS pDevIns, RTGCPHYS GCPhysStart, RTUINT cbRange, PGMROMPROT enmProt) 3299 { 3300 return pDevIns->pDevHlpR3->pfnROMProtectShadow(pDevIns, GCPhysStart, cbRange, enmProt); 3299 3301 } 3300 3302 … … 3511 3513 } 3512 3514 3515 #ifndef VBOX_WITH_NEW_PHYS_CODE 3513 3516 /** 3514 3517 * @copydoc PDMDEVHLPR3::pfnPhysReserve … … 3518 3521 return pDevIns->pDevHlpR3->pfnPhysReserve(pDevIns, GCPhys, cbRange, pszDesc); 3519 3522 } 3523 #endif 3520 3524 3521 3525 /** -
trunk/include/VBox/pgm.h
r17134 r17251 273 273 */ 274 274 #define PGMMODE_IS_LONG_MODE(enmMode) ((enmMode) == PGMMODE_AMD64_NX || (enmMode) == PGMMODE_AMD64) 275 276 /**277 * The current ROM page protection.278 */279 typedef enum PGMROMPROT280 {281 /** The customary invalid value. */282 PGMROMPROT_INVALID = 0,283 /** Read from the virgin ROM page, ignore writes.284 * Map the virgin page, use write access handler to ignore writes. */285 PGMROMPROT_READ_ROM_WRITE_IGNORE,286 /** Read from the virgin ROM page, write to the shadow RAM.287 * Map the virgin page, use write access handler change the RAM. */288 PGMROMPROT_READ_ROM_WRITE_RAM,289 /** Read from the shadow ROM page, ignore writes.290 * Map the shadow page read-only, use write access handler to ignore writes. */291 PGMROMPROT_READ_RAM_WRITE_IGNORE,292 /** Read from the shadow ROM page, ignore writes.293 * Map the shadow page read-write, disabled write access handler. */294 PGMROMPROT_READ_RAM_WRITE_RAM,295 /** The end of valid values. */296 PGMROMPROT_END,297 /** The usual 32-bit type size hack. */298 PGMROMPROT_32BIT_HACK = 0x7fffffff299 } PGMROMPROT;300 275 301 276 /** -
trunk/include/VBox/rem.h
r13832 r17251 82 82 #endif 83 83 REMR3DECL(void) REMR3NotifyPhysRomRegister(PVM pVM, RTGCPHYS GCPhys, RTUINT cb, void *pvCopy, bool fShadow); 84 REMR3DECL(void) REMR3NotifyPhysR eserve(PVM pVM, RTGCPHYS GCPhys, RTUINT cb);84 REMR3DECL(void) REMR3NotifyPhysRamDeregister(PVM pVM, RTGCPHYS GCPhys, RTUINT cb); 85 85 REMR3DECL(void) REMR3NotifyHandlerPhysicalRegister(PVM pVM, PGMPHYSHANDLERTYPE enmType, RTGCPHYS GCPhys, RTGCPHYS cb, bool fHasHCHandler); 86 86 REMR3DECL(void) REMR3NotifyHandlerPhysicalDeregister(PVM pVM, PGMPHYSHANDLERTYPE enmType, RTGCPHYS GCPhys, RTGCPHYS cb, bool fHasHCHandler, bool fRestoreAsRAM); -
trunk/include/VBox/types.h
r17136 r17251 543 543 typedef PDMDATASEG const *PCPDMDATASEG; 544 544 545 546 /** 547 * The current ROM page protection. 548 */ 549 typedef enum PGMROMPROT 550 { 551 /** The customary invalid value. */ 552 PGMROMPROT_INVALID = 0, 553 /** Read from the virgin ROM page, ignore writes. 554 * Map the virgin page, use write access handler to ignore writes. */ 555 PGMROMPROT_READ_ROM_WRITE_IGNORE, 556 /** Read from the virgin ROM page, write to the shadow RAM. 557 * Map the virgin page, use write access handler change the RAM. */ 558 PGMROMPROT_READ_ROM_WRITE_RAM, 559 /** Read from the shadow ROM page, ignore writes. 560 * Map the shadow page read-only, use write access handler to ignore writes. */ 561 PGMROMPROT_READ_RAM_WRITE_IGNORE, 562 /** Read from the shadow ROM page, ignore writes. 563 * Map the shadow page read-write, disabled write access handler. */ 564 PGMROMPROT_READ_RAM_WRITE_RAM, 565 /** The end of valid values. */ 566 PGMROMPROT_END, 567 /** The usual 32-bit type size hack. */ 568 PGMROMPROT_32BIT_HACK = 0x7fffffff 569 } PGMROMPROT; 570 571 545 572 /** @} */ 546 573
Note:
See TracChangeset
for help on using the changeset viewer.