diff options
author | Patrick Williams <iawillia@us.ibm.com> | 2013-04-17 14:08:07 -0500 |
---|---|---|
committer | A. Patrick Williams III <iawillia@us.ibm.com> | 2013-04-18 10:34:51 -0500 |
commit | bb42935e42d82c247d81ea03c4242ceccc41b487 (patch) | |
tree | 0ebad282a4c49770e66ed074f927545bf9ec197f /src/kernel | |
parent | e51746288cafd570886dd30625f6a74d15ae3835 (diff) | |
download | talos-hostboot-bb42935e42d82c247d81ea03c4242ceccc41b487.tar.gz talos-hostboot-bb42935e42d82c247d81ea03c4242ceccc41b487.zip |
Uninitialized values in cpumgr.
Change-Id: I1d357cedbd0dc77f2cde0d9071a82860398e09b6
Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/4096
Tested-by: Jenkins Server
Reviewed-by: Dean Sanner <dsanner@us.ibm.com>
Reviewed-by: ADAM R. MUHLE <armuhle@us.ibm.com>
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/kernel')
-rw-r--r-- | src/kernel/cpumgr.C | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/kernel/cpumgr.C b/src/kernel/cpumgr.C index 436930de7..6f641ecb3 100644 --- a/src/kernel/cpumgr.C +++ b/src/kernel/cpumgr.C @@ -91,7 +91,7 @@ void CpuManager::init() // Set up CPU structure. cv_cpus[getPIR() / KERNEL_MAX_SUPPORTED_CPUS_PER_NODE] = - new cpu_t*[KERNEL_MAX_SUPPORTED_CPUS_PER_NODE]; + new cpu_t*[KERNEL_MAX_SUPPORTED_CPUS_PER_NODE](); // Create CPU objects starting at the thread-0 for this core. size_t baseCpu = getCpuId() & ~(threads-1); @@ -184,15 +184,14 @@ void CpuManager::startCPU(ssize_t i) // Initialize node structure. if (NULL == cv_cpus[nodeId]) { - cv_cpus[nodeId] = new cpu_t*[KERNEL_MAX_SUPPORTED_CPUS_PER_NODE]; + cv_cpus[nodeId] = new cpu_t*[KERNEL_MAX_SUPPORTED_CPUS_PER_NODE](); } // Initialize CPU structure. if (NULL == cv_cpus[nodeId][cpuId]) { printk("Starting CPU %ld...", i); - cpu_t* cpu = cv_cpus[nodeId][cpuId] = new cpu_t; - memset(cpu, 0x0, sizeof(cpu_t)); + cpu_t* cpu = cv_cpus[nodeId][cpuId] = new cpu_t(); // Initialize CPU. cpu->cpu = i; |