From bd9b94d12a6158b6080630085f77e59ac1b7de26 Mon Sep 17 00:00:00 2001 From: Sukadev Bhattiprolu Date: Wed, 25 Nov 2015 12:10:39 -0800 Subject: lscpu: Print physical cpu information lscpu currently prints information for CPUs configured in the system. In case of KVM or other virtualized guest operating systems, this refers to the virtual system, and bears no relation to the physical topology of the system. It would be useful if lscpu could also display the physical topology info when available: $ ./lscpu Architecture: ppc64le Byte Order: Little Endian CPU(s): 16 On-line CPU(s) list: 0-15 Thread(s) per core: 1 Core(s) per socket: 1 Socket(s): 16 NUMA node(s): 1 Model: IBM pSeries (emulated by qemu) Hypervisor vendor: KVM Virtualization type: para L1d cache: 64K L1i cache: 32K NUMA node0 CPU(s): 0-15 Physical sockets: 2 <<< New Physical chips: 4 <<< New Physical cores/chip: 4 <<< New For now, physical topology information is available on platforms that support the following RTAS (Real time abstraction service) call provided by librtas: rtas_get_sysparm(PROCESSOR_MODULE_INFO). Currently this call is available to the PowerVM (pHYP) guests on PowerPC. With a patch propoosed to PowerKVM, this RTAS call would also be available to PowerKVM guests. Based on input from Nishanth Aravamudan and Karel Zak. Signed-off-by: Sukadev Bhattiprolu --- sys-utils/Makemodule.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys-utils/Makemodule.am') diff --git a/sys-utils/Makemodule.am b/sys-utils/Makemodule.am index ff7e1ee12..c62d77c79 100644 --- a/sys-utils/Makemodule.am +++ b/sys-utils/Makemodule.am @@ -324,7 +324,7 @@ lscpu_SOURCES = \ sys-utils/lscpu.c \ sys-utils/lscpu.h \ sys-utils/lscpu-dmi.c -lscpu_LDADD = $(LDADD) libcommon.la libsmartcols.la +lscpu_LDADD = $(LDADD) libcommon.la libsmartcols.la $(RTAS_LIBS) lscpu_CFLAGS = $(AM_CFLAGS) -I$(ul_libsmartcols_incdir) dist_man_MANS += sys-utils/lscpu.1 endif -- cgit v1.2.3-55-g7522