VirtualBox

Changeset 52110 in vbox for trunk/src/VBox/VMM/VMMR3


Ignore:
Timestamp:
Jul 21, 2014 12:53:59 PM (11 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
95132
Message:

VMM/GIM: Make guest-OS Id as part of the saved states as it could be useful in the future to have it in there.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR3/GIM.cpp

    r51797 r52110  
    122122    AssertLogRelRCReturn(rc, rc);
    123123    if (uGuestOsId < GIMOSID_END)
     124    {
    124125        GuestOsId = (GIMOSID)uGuestOsId;
     126        pVM->gim.s.enmGuestOsId = GuestOsId;
     127    }
    125128    else
    126129    {
     
    145148        {
    146149            pVM->gim.s.enmProviderId = GIMPROVIDERID_MINIMAL;
    147             rc = GIMR3MinimalInit(pVM, GuestOsId);
     150            rc = GIMR3MinimalInit(pVM);
    148151        }
    149152        else if (!RTStrCmp(szProvider, "HyperV"))
     
    267270    rc = SSMR3PutU32(pSSM, pVM->gim.s.u32Version);
    268271    AssertRCReturn(rc, rc);
     272    rc = SSMR3PutU32(pSSM, pVM->gim.s.enmGuestOsId);
     273    AssertRCReturn(rc, rc);
    269274
    270275    /*
     
    320325    AssertRCReturn(rc, rc);
    321326    rc = SSMR3GetU32(pSSM, &pVM->gim.s.u32Version);
     327    AssertRCReturn(rc, rc);
     328    rc = SSMR3GetU32(pSSM, (uint32_t *)&pVM->gim.s.enmGuestOsId);
    322329    AssertRCReturn(rc, rc);
    323330
     
    603610
    604611/**
    605  * Checks if the given Guest OS identifier implies an OS X family of guests.
     612 * Checks if the GIM Guest OS identifier for this VM implies an OS X family of
     613 * guests.
    606614 *
    607615 * @returns true if it's an OS X guest, false otherwise.
    608  * @param   enmGuestOs      The Guest OS Id.
    609  */
    610 VMMR3_INT_DECL(bool) GIMR3IsOSXGuest(GIMOSID enmGuestOs)
    611 {
    612     switch (enmGuestOs)
     616 * @param   pVM         Pointer to the VM.
     617 */
     618VMMR3_INT_DECL(bool) GIMR3IsOSXGuest(PVM pVM)
     619{
     620    switch (pVM->gim.s.enmGuestOsId)
    613621    {
    614622        case GIMOSID_OSX:
  • trunk/src/VBox/VMM/VMMR3/GIMHv.cpp

    r52027 r52110  
    659659        {
    660660            /** @todo Handle raw-mode hypercall page patching. */
    661             LogRel(("GIM: HyperV: Raw-mode not yet implemented!\n"));
     661            LogRel(("GIM: HyperV: Raw-mode hypercalls not yet implemented!\n"));
    662662        }
    663663        GIMR3Mmio2Unmap(pVM, pRegion);
  • trunk/src/VBox/VMM/VMMR3/GIMMinimal.cpp

    r52009 r52110  
    3333*******************************************************************************/
    3434
    35 VMMR3_INT_DECL(int) GIMR3MinimalInit(PVM pVM, GIMOSID enmGuest)
     35VMMR3_INT_DECL(int) GIMR3MinimalInit(PVM pVM)
    3636{
    3737    AssertReturn(pVM, VERR_INVALID_PARAMETER);
     
    4343    CPUMSetGuestCpuIdFeature(pVM, CPUMCPUIDFEATURE_HVP);
    4444
    45     if (GIMR3IsOSXGuest(enmGuest))
     45    if (GIMR3IsOSXGuest(pVM))
    4646    {
    4747        /*
     
    5858        {
    5959            uint32_t uMaxIntelFamilyModelStep = UINT32_MAX;
    60             switch (enmGuest)
     60            switch (pVM->gim.s.enmGuestOsId)
    6161            {
    6262                case GIMOSID_OSX:
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette