VirtualBox

Changeset 47988 in vbox for trunk/src/VBox/VMM/VMMAll


Ignore:
Timestamp:
Aug 22, 2013 1:01:54 PM (11 years ago)
Author:
vboxsync
Message:

Solaris reads MSR_RAPL_POWER_UNIT, give it some fake values.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMAll/CPUMAllRegs.cpp

    r47942 r47988  
    11031103        case MSR_IA32_MC0_CTL:
    11041104        case MSR_IA32_MC0_STATUS:
     1105        case MSR_RAPL_POWER_UNIT:
    11051106            *puValue = 0;
    11061107            if (CPUMGetGuestCpuVendor(pVCpu->CTX_SUFF(pVM)) != CPUMCPUVENDOR_INTEL)
     
    11081109                Log(("MSR %#x is Intel, the virtual CPU isn't an Intel one -> #GP\n", idMsr));
    11091110                rc = VERR_CPUM_RAISE_GP_0;
     1111                break;
     1112            }
     1113
     1114            /* Provide more plausive values for some of them. */
     1115            switch (idMsr)
     1116            {
     1117                case MSR_RAPL_POWER_UNIT:
     1118                    *puValue = RT_MAKE_U32_FROM_U8(3 /* power units (1/8 W)*/,
     1119                                                   16 /* 15.3 micro-Joules */,
     1120                                                   10 /* 976 microseconds increments */,
     1121                                                   0);
     1122                    break;
    11101123            }
    11111124            break;
  • trunk/src/VBox/VMM/VMMAll/IEMAllCImpl.cpp.h

    r47821 r47988  
    46684668    if (rc != VINF_SUCCESS)
    46694669    {
     4670#ifdef IN_RING3
     4671        static uint32_t s_cTimes = 0;
     4672        if (s_cTimes++ < 10)
     4673            LogRel(("IEM: rdmsr(%#x) -> GP(0)\n", pCtx->ecx));
     4674#endif
    46704675        Log(("IEM: rdmsr(%#x) -> GP(0)\n", pCtx->ecx));
    46714676        AssertMsgReturn(rc == VERR_CPUM_RAISE_GP_0, ("%Rrc\n", rc), VERR_IPE_UNEXPECTED_STATUS);
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