]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lscpu: fix cpu map array sizes
authorHeiko Carstens <heiko.carstens@de.ibm.com>
Wed, 10 Aug 2011 08:34:28 +0000 (10:34 +0200)
committerKarel Zak <kzak@redhat.com>
Tue, 18 Oct 2011 05:12:17 +0000 (07:12 +0200)
commit0ee7da4d8021e2b1f24b4d04b96a3b953fe7d5a0
tree2abfa1b942fa627943eb9fff7a066eac961cc24f
parentd25ad908fdbe098dbee7b5e46bc71a3c10476d6d
lscpu: fix cpu map array sizes

Completely virtualized architectures like s390 may have multiple
virtual sockets and/or cores where each of them has a different
number of cores and cpus.
So the general assumption within the allocation scheme that e.g.
each socket contains the same number of cores is not necessarily
true. To make sure the arrays are always large enough we simply
allocate enough memory so that each array could hold cpu masks
for all present cpus.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
sys-utils/lscpu.c