VirtualBox

Changeset 6861 in vbox


Ignore:
Timestamp:
Feb 8, 2008 10:04:44 AM (17 years ago)
Author:
vboxsync
Message:

Sketected out new MMIO and MMIO2 interfaces. Not complete or implemented yet as the MM_RAM_FLAGS_* needs eliminating first.

Location:
trunk/src/VBox/VMM
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/PGMPhys.cpp

    r6856 r6861  
    256256
    257257    return VINF_SUCCESS;
     258}
     259
     260
     261/**
     262 * This is the interface IOM is using to register an MMIO region.
     263 *
     264 * It will check for conflicts and ensure that a RAM range structure
     265 * is present before calling the PGMR3HandlerPhysicalRegister API to
     266 * register the callbacks.
     267 *
     268 */
     269PDMR3DECL(int) PGMR3PhysMMIORegister(PVM pVM, RTGCPHYS GCPhys, RTGCPHYS cb)
     270{
     271    return -1;
     272}
     273
     274
     275/**
     276 * This is the interface IOM is using to register an MMIO region.
     277 *
     278 * It will validate the MMIO region, call PGMHandlerPhysicalDeregister,
     279 * and free the RAM range if one was allocated specially for this MMIO
     280 * region.
     281 */
     282PDMR3DECL(int) PGMR3PhysMMIODeregister(PVM pVM, RTGCPHYS GCPhys, RTGCPHYS cb)
     283{
     284    return -1;
     285}
     286
     287
     288/**
     289 * Allocate and register a MMIO2 region.
     290 *
     291 * As mentioned elsewhere, MMIO2 is just RAM spelled differently. It's
     292 * RAM associated with a device. It is also non-shared memory with a
     293 * permanent ring-3 mapping and page backing (presently).
     294 *
     295 * A MMIO2 range may overlap with base memory if a lot of RAM
     296 * is configured for the VM, in which case we'll drop the base
     297 * memory pages. Presently we will make no attempt to preserve
     298 * anything that happens to be present in the base memory that
     299 * is replaced, this is of course incorrectly but it's too much
     300 * effort.
     301 */
     302PDMR3DECL(int) PGMR3PhysMMIO2Register(PVM pVM, PPDMDEVINS pDevIns, RTGCPHYS GCPhys, RTGCPHYS cb, void **ppv, const char *pszDesc)
     303{
     304    return -1;
     305}
     306
     307
     308/**
     309 * Reallocates a MMIO2 region.
     310 *
     311 * This is done when a guest / the bios / state loading changes the
     312 * PCI config. The replacing of base memory has the same restrictions
     313 * as during registration, of course.
     314 */
     315PDMR3DECL(int) PGMR3PhysMMIO2Relocate(PVM pVM, PPDMDEVINS pDevIns, RTGCPHYS GCPhysOld, RTGCPHYS GCPhysNew)
     316{
     317    return -1;
     318}
     319
     320
     321/**
     322 * Deregisters and frees a MMIO2 region.
     323 *
     324 * Any physical (and virtual) access handlers registered for the region must
     325 * be deregistered before calling this function.
     326 */
     327PDMR3DECL(int) PGMR3PhysMMIO2Deregister(PVM pVM, RTGCPHYS GCPhys, void *pv)
     328{
     329    return -1;
    258330}
    259331
  • trunk/src/VBox/VMM/VMMAll/PGMAllHandler.cpp

    r6855 r6861  
    4545*   Internal Functions                                                         *
    4646*******************************************************************************/
    47 static int pgmHandlerPhysicalSetRamFlagsAndFlushShadowPTs(PVM pVM, PPGMPHYSHANDLER pCur, PPGMRAMRANGE pRam);
     47static int  pgmHandlerPhysicalSetRamFlagsAndFlushShadowPTs(PVM pVM, PPGMPHYSHANDLER pCur, PPGMRAMRANGE pRam);
    4848static void pgmHandlerPhysicalDeregisterNotifyREM(PVM pVM, PPGMPHYSHANDLER pCur);
    4949static void pgmHandlerPhysicalResetRamFlags(PVM pVM, PPGMPHYSHANDLER pCur);
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