]> git.ipfire.org Git - thirdparty/util-linux.git/commit
lscpu: add helper to get physical sockets
authorMasayoshi Mizuma <m.mizuma@jp.fujitsu.com>
Fri, 20 Nov 2020 05:06:08 +0000 (00:06 -0500)
committerKarel Zak <kzak@redhat.com>
Fri, 20 Nov 2020 08:17:12 +0000 (09:17 +0100)
commit788f90d69a43198e648442399967542e98e44d11
treee3e785526baba3d325bcd66111b6321c8f05dd32
parent3cd676f5ec9800e4eabafc578f31c292992d6396
lscpu: add helper to get physical sockets

Add a helper function, get_number_of_physical_sockets_from_dmi(),
to get physical sockets from DMI table in case of the sysfs for
cpu topology doesn't have the physical socket information.

get_number_of_physical_sockets_from_dmi() parse the DMI table
and counts the number of SMBIOS Processor Information (Type04)
structure.

Signed-off-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
sys-utils/lscpu-dmi.c
sys-utils/lscpu.h