]> git.ipfire.org Git - thirdparty/libvirt.git/commit
nodeinfo: fix to parse present cpus rather than possible cpus
authorKothapally Madhu Pavan <kmp@linux.vnet.ibm.com>
Fri, 26 Jun 2015 22:27:29 +0000 (03:57 +0530)
committerJohn Ferlan <jferlan@redhat.com>
Mon, 13 Jul 2015 20:07:44 +0000 (16:07 -0400)
commitbb31f4532b285a7392911f420bcdf05a126be8a0
tree18116baf37528f6539f29f2db074e4b59e19a81d
parentc71f0654fc8ed9e69b75b24eac83a3369e4e64b3
nodeinfo: fix to parse present cpus rather than possible cpus

This patch resolves a situation where a core is defective and is not
in the present mask during boot. Optionally a host can have empty sockets
could be brought online if the socket is added. In this case the present
mask contains the cpu's that are actually there in the sockets even though
they might be offline for some reason. This patch excludes the cpu's that
are offline because the socket is defective/empty by checking the present
mask before reading the cpu directory. Otherwise, the nodeinfo on such
hosts always displays wrong output which includes the defective/empty
sockets as set of offline cpu's.

Signed-off-by: Kothapally Madhu Pavan <kmp@linux.vnet.ibm.com>
src/nodeinfo.c