VirtualBox

Changeset 36236 in vbox


Ignore:
Timestamp:
Mar 9, 2011 5:27:22 PM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
70458
Message:

HWACCMR0: CPU bounds check. CPUMR0: updated message.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/VMM/VMMR0/CPUMR0.cpp

    r36234 r36236  
    695695    if (RTMpGetArraySize() > RT_ELEMENTS(g_aLApics))
    696696    {
    697         LogRel(("CPUM: Too many real CPUs - %u, max %u\n", RTMpGetArraySize(), RT_ELEMENTS(g_aLApics)));
     697        LogRel(("CPUM: Too many real CPUs/cores/threads - %u, max %u\n", RTMpGetArraySize(), RT_ELEMENTS(g_aLApics)));
    698698        return VERR_TOO_MANY_CPUS;
    699699    }
  • trunk/src/VBox/VMM/VMMR0/HWACCMR0.cpp

    r35346 r36236  
    154154    bool    fAMDVPresent = false;
    155155
    156     memset(&HWACCMR0Globals, 0, sizeof(HWACCMR0Globals));
    157156    HWACCMR0Globals.enmHwAccmState = HWACCMSTATE_UNINITIALIZED;
    158157    for (unsigned i = 0; i < RT_ELEMENTS(HWACCMR0Globals.aCpuInfo); i++)
     
    173172    /* Default is global VT-x/AMD-V init */
    174173    HWACCMR0Globals.fGlobalInit         = true;
     174
     175    /*
     176     * Make sure aCpuInfo is big enough for all the CPUs on this system.
     177     */
     178    if (RTMpGetArraySize() > RT_ELEMENTS(HWACCMR0Globals.aCpuInfo))
     179    {
     180        LogRel(("HWACCM: Too many real CPUs/cores/threads - %u, max %u\n", RTMpGetArraySize(), RT_ELEMENTS(HWACCMR0Globals.aCpuInfo)));
     181        return VERR_TOO_MANY_CPUS;
     182    }
    175183
    176184    /*
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