VirtualBox

Changeset 7613 in vbox for trunk/src


Ignore:
Timestamp:
Mar 28, 2008 8:25:54 AM (17 years ago)
Author:
vboxsync
Message:

better fix for r29105 (see #2680): Make PGM3PhysGrowRange() take PCRTGCPHYS not RTGCPHYS to be able to call it with VMR3ReqCall()

Location:
trunk/src
Files:
5 edited

Legend:

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

    r6830 r7613  
    331331         * If requested, allocated the rest too.
    332332         */
    333         rc = PGM3PhysGrowRange(pVM, (RTGCPHYS)0);
     333        RTGCPHYS GCPhys = (RTGCPHYS)0;
     334        rc = PGM3PhysGrowRange(pVM, &GCPhys);
    334335        if (RT_SUCCESS(rc) && fPreAlloc)
    335             for (RTGCPHYS GCPhys = PGM_DYNAMIC_CHUNK_SIZE;
     336            for (GCPhys = PGM_DYNAMIC_CHUNK_SIZE;
    336337                 GCPhys < cbRam && RT_SUCCESS(rc);
    337338                 GCPhys += PGM_DYNAMIC_CHUNK_SIZE)
    338                 rc = PGM3PhysGrowRange(pVM, GCPhys);
     339                rc = PGM3PhysGrowRange(pVM, &GCPhys);
    339340    }
    340341#endif
  • trunk/src/VBox/VMM/PGMPhys.cpp

    r7605 r7613  
    11641164 * @param   GCPhys          GC physical address of the RAM range. (page aligned)
    11651165 */
    1166 PGMR3DECL(int) PGM3PhysGrowRange(PVM pVM, RTGCPHYS GCPhys)
    1167 {
     1166PGMR3DECL(int) PGM3PhysGrowRange(PVM pVM, PCRTGCPHYS pGCPhys)
     1167{
     1168    RTGCPHYS GCPhys = *pGCPhys;
     1169
    11681170    /*
    11691171     * Walk range list.
     
    12151217    {
    12161218        PVMREQ pReq;
     1219        const RTGCPHYS GCPhysParam = GCPhys;
    12171220
    12181221        AssertMsg(!PDMCritSectIsOwner(&pVM->pgm.s.CritSect), ("We own the PGM lock -> deadlock danger!!\n"));
    12191222
    1220         rc = VMR3ReqCall(pVM, &pReq, RT_INDEFINITE_WAIT, (PFNRT)PGM3PhysGrowRange, 1 + sizeof(RTGCPHYS)/sizeof(uintptr_t), pVM, GCPhys);
     1223        rc = VMR3ReqCall(pVM, &pReq, RT_INDEFINITE_WAIT, (PFNRT)PGM3PhysGrowRange, 2, pVM, &GCPhysParam);
    12211224        if (VBOX_SUCCESS(rc))
    12221225        {
  • trunk/src/VBox/VMM/VMM.cpp

    r7015 r7613  
    22132213        case VMMCALLHOST_PGM_RAM_GROW_RANGE:
    22142214        {
    2215             pVM->vmm.s.rcCallHost = PGM3PhysGrowRange(pVM, pVM->vmm.s.u64CallHostArg);
     2215            pVM->vmm.s.rcCallHost = PGM3PhysGrowRange(pVM, &pVM->vmm.s.u64CallHostArg);
    22162216            break;
    22172217        }
  • trunk/src/recompiler/VBoxREMWrapper.cpp

    r6546 r7613  
    664664{
    665665    { REMPARMDESC_FLAGS_INT,        sizeof(PVM), NULL },
    666     { REMPARMDESC_FLAGS_GCPHYS,     sizeof(RTGCPHYS), NULL }
     666    { REMPARMDESC_FLAGS_GCPHYS,     sizeof(PCRTGCPHYS), NULL }
    667667};
    668668static const REMPARMDESC g_aArgsPGMPhysIsGCPhysValid[] =
  • trunk/src/recompiler/VBoxRecompiler.c

    r6546 r7613  
    25582558
    25592559    Log(("remR3GrowDynRange %VGp\n", physaddr));
    2560     rc = PGM3PhysGrowRange(pVM, (RTGCPHYS)physaddr);
     2560    RTGCPHYS GCPhys = physaddr;
     2561    rc = PGM3PhysGrowRange(pVM, &GCPhys);
    25612562    if (VBOX_SUCCESS(rc))
    25622563        return;
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