diff --git a/opal/mca/hwloc/hwloc132/hwloc/src/topology-x86.c b/opal/mca/hwloc/hwloc132/hwloc/src/topology-x86.c index 60df5cdcd4..72df56e01b 100644 --- a/opal/mca/hwloc/hwloc132/hwloc/src/topology-x86.c +++ b/opal/mca/hwloc/hwloc132/hwloc/src/topology-x86.c @@ -208,11 +208,12 @@ static void look_proc(struct procinfo *infos, unsigned highest_cpuid, unsigned h cache->linesize = linesize = (ebx & 0xfff) + 1; cache->linepart = linepart = ((ebx >> 12) & 0x3ff) + 1; + ways = ((ebx >> 22) & 0x3ff) + 1; if (eax & (1 << 9)) /* Fully associative */ cache->ways = -1; else - cache->ways = ways = ((ebx >> 22) & 0x3ff) + 1; + cache->ways = ways; cache->sets = sets = ecx + 1; cache->size = linesize * linepart * ways * sets;