VirtualBox

Changeset 91958 in vbox for trunk/src


Ignore:
Timestamp:
Oct 21, 2021 2:34:49 PM (3 years ago)
Author:
vboxsync
Message:

VMM/NEM/win: No mapping limits when in simplified memory management mode. bugref:10122

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/NEMAllNativeTemplate-win.cpp.h

    r91848 r91958  
    18081808    LogRel(("nemHCWinHandleMemoryAccessPageCheckerCallback/unmap: GCPhysDst=%RGp rc=%Rrc\n", GCPhys, rc));
    18091809    return rc;
     1810# elif defined(VBOX_WITH_PGM_NEM_MODE)
     1811    LogRel(("nemHCWinHandleMemoryAccessPageCheckerCallback/unmap: GCPhysDst=%RGp %s hrc=%Rhrc (%#x)\n",
     1812            GCPhys, g_apszPageStates[u2State], hrc, hrc));
     1813    return VERR_NEM_UNMAP_PAGES_FAILED;
    18101814# else
    18111815    LogRel(("nemHCWinHandleMemoryAccessPageCheckerCallback/unmap: GCPhysDst=%RGp %s hrc=%Rhrc (%#x) Last=%#x/%u (cMappedPages=%u)\n",
     
    42094213    for (unsigned iLoop = 0;; iLoop++)
    42104214    {
    4211 # ifndef NEM_WIN_USE_HYPERCALLS_FOR_PAGES
     4215# if !defined(NEM_WIN_USE_HYPERCALLS_FOR_PAGES) && !defined(VBOX_WITH_PGM_NEM_MODE)
    42124216        /*
    42134217         * Hack alert!
  • trunk/src/VBox/VMM/VMMR3/NEMR3Native-win.cpp

    r91848 r91958  
    13641364                        STAMR3Register(pVM, (void *)&pVM->nem.s.StatRemapPage, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS,
    13651365                                       "/NEM/PagesRemapFails", STAMUNIT_PAGES, "Calls to HvCallMapGpaPages for changing page protection failed");
    1366 #else
     1366#elif !defined(VBOX_WITH_PGM_NEM_MODE)
    13671367                        STAMR3Register(pVM, (void *)&pVM->nem.s.StatUnmapAllPages, STAMTYPE_COUNTER, STAMVISIBILITY_ALWAYS,
    13681368                                       "/NEM/PagesUnmapAll", STAMUNIT_PAGES, "Times we had to unmap all the pages");
  • trunk/src/VBox/VMM/include/NEMInternal.h

    r91848 r91958  
    5151 * Windows: Code configuration.
    5252 */
    53 # define NEM_WIN_USE_HYPERCALLS_FOR_PAGES
     53# ifndef VBOX_WITH_PGM_NEM_MODE
     54#  define NEM_WIN_USE_HYPERCALLS_FOR_PAGES
     55#endif
    5456//# define NEM_WIN_USE_HYPERCALLS_FOR_REGISTERS   /**< Applies to ring-3 code only. Useful for testing VID API. */
    5557//# define NEM_WIN_USE_OUR_OWN_RUN_API            /**< Applies to ring-3 code only. Useful for testing VID API. */
     
    208210    STAMCOUNTER                 StatRemapPage;
    209211    STAMCOUNTER                 StatRemapPageFailed;
    210 #  else
     212#  elif !defined(VBOX_WITH_PGM_NEM_MODE)
    211213    STAMCOUNTER                 StatUnmapAllPages;
    212214#  endif
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