From nobody Mon Apr 29 16:48:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 151318143766162.73596423437152; Wed, 13 Dec 2017 08:10:37 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id A739FC013C4F; Wed, 13 Dec 2017 16:10:35 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0A0F278DB0; Wed, 13 Dec 2017 16:10:35 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4DDBE4A468; Wed, 13 Dec 2017 16:10:34 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id vBDGAX1K027230 for ; Wed, 13 Dec 2017 11:10:33 -0500 Received: by smtp.corp.redhat.com (Postfix) id 33F767BA3D; Wed, 13 Dec 2017 16:10:33 +0000 (UTC) Received: from inaba.usersys.redhat.com (unknown [10.40.205.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A6CB67BA5C for ; Wed, 13 Dec 2017 16:10:31 +0000 (UTC) From: Andrea Bolognani To: libvir-list@redhat.com Date: Wed, 13 Dec 2017 17:10:18 +0100 Message-Id: <20171213161021.28525-2-abologna@redhat.com> In-Reply-To: <20171213161021.28525-1-abologna@redhat.com> References: <20171213161021.28525-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH v2 1/4] tests: Add host CPU data for Moonshot (RHEL 7.4) X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Wed, 13 Dec 2017 16:10:36 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Signed-off-by: Andrea Bolognani --- .../linux-aarch64-rhel74-moonshot.cpuinfo | 72 ++++++++++++++++++= ++++ .../linux-aarch64-rhel74-moonshot.expected | 1 + .../linux-rhel74-moonshot/cpu/cpu0/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu0/online | 1 + .../cpu/cpu0/topology/core_id | 1 + .../cpu/cpu0/topology/core_siblings | 1 + .../cpu/cpu0/topology/core_siblings_list | 1 + .../cpu/cpu0/topology/physical_package_id | 1 + .../cpu/cpu0/topology/thread_siblings | 1 + .../cpu/cpu0/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu1/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu1/online | 1 + .../cpu/cpu1/topology/core_id | 1 + .../cpu/cpu1/topology/core_siblings | 1 + .../cpu/cpu1/topology/core_siblings_list | 1 + .../cpu/cpu1/topology/physical_package_id | 1 + .../cpu/cpu1/topology/thread_siblings | 1 + .../cpu/cpu1/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu2/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu2/online | 1 + .../cpu/cpu2/topology/core_id | 1 + .../cpu/cpu2/topology/core_siblings | 1 + .../cpu/cpu2/topology/core_siblings_list | 1 + .../cpu/cpu2/topology/physical_package_id | 1 + .../cpu/cpu2/topology/thread_siblings | 1 + .../cpu/cpu2/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu3/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu3/online | 1 + .../cpu/cpu3/topology/core_id | 1 + .../cpu/cpu3/topology/core_siblings | 1 + .../cpu/cpu3/topology/core_siblings_list | 1 + .../cpu/cpu3/topology/physical_package_id | 1 + .../cpu/cpu3/topology/thread_siblings | 1 + .../cpu/cpu3/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu4/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu4/online | 1 + .../cpu/cpu4/topology/core_id | 1 + .../cpu/cpu4/topology/core_siblings | 1 + .../cpu/cpu4/topology/core_siblings_list | 1 + .../cpu/cpu4/topology/physical_package_id | 1 + .../cpu/cpu4/topology/thread_siblings | 1 + .../cpu/cpu4/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu5/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu5/online | 1 + .../cpu/cpu5/topology/core_id | 1 + .../cpu/cpu5/topology/core_siblings | 1 + .../cpu/cpu5/topology/core_siblings_list | 1 + .../cpu/cpu5/topology/physical_package_id | 1 + .../cpu/cpu5/topology/thread_siblings | 1 + .../cpu/cpu5/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu6/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu6/online | 1 + .../cpu/cpu6/topology/core_id | 1 + .../cpu/cpu6/topology/core_siblings | 1 + .../cpu/cpu6/topology/core_siblings_list | 1 + .../cpu/cpu6/topology/physical_package_id | 1 + .../cpu/cpu6/topology/thread_siblings | 1 + .../cpu/cpu6/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/cpu7/node0 | 1 + .../linux-rhel74-moonshot/cpu/cpu7/online | 1 + .../cpu/cpu7/topology/core_id | 1 + .../cpu/cpu7/topology/core_siblings | 1 + .../cpu/cpu7/topology/core_siblings_list | 1 + .../cpu/cpu7/topology/physical_package_id | 1 + .../cpu/cpu7/topology/thread_siblings | 1 + .../cpu/cpu7/topology/thread_siblings_list | 1 + .../linux-rhel74-moonshot/cpu/kernel_max | 1 + .../linux-rhel74-moonshot/cpu/offline | 1 + .../linux-rhel74-moonshot/cpu/online | 1 + .../linux-rhel74-moonshot/cpu/possible | 1 + .../linux-rhel74-moonshot/cpu/present | 1 + .../linux-rhel74-moonshot/node/has_cpu | 1 + .../linux-rhel74-moonshot/node/has_memory | 1 + .../linux-rhel74-moonshot/node/has_normal_memory | 1 + .../linux-rhel74-moonshot/node/node0/cpu0 | 1 + .../linux-rhel74-moonshot/node/node0/cpu1 | 1 + .../linux-rhel74-moonshot/node/node0/cpu2 | 1 + .../linux-rhel74-moonshot/node/node0/cpu3 | 1 + .../linux-rhel74-moonshot/node/node0/cpu4 | 1 + .../linux-rhel74-moonshot/node/node0/cpu5 | 1 + .../linux-rhel74-moonshot/node/node0/cpu6 | 1 + .../linux-rhel74-moonshot/node/node0/cpu7 | 1 + .../linux-rhel74-moonshot/node/node0/cpulist | 1 + .../linux-rhel74-moonshot/node/node0/cpumap | 1 + .../linux-rhel74-moonshot/node/online | 1 + .../linux-rhel74-moonshot/node/possible | 1 + tests/virhostcputest.c | 1 + 87 files changed, 158 insertions(+) create mode 100644 tests/virhostcpudata/linux-aarch64-rhel74-moonshot.cpui= nfo create mode 100644 tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expe= cted create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/thread_siblings_list create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/nod= e0 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/onl= ine create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/core_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/core_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/core_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/physical_package_id create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/thread_siblings create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/thread_siblings_list create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/kernel_m= ax create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/offline create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/online create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/possible create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/cpu/present create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_cpu create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_mem= ory create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/has_nor= mal_memory create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu0 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu1 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu2 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu3 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu4 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu5 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu6 create mode 120000 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pu7 create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pulist create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/node0/c= pumap create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/online create mode 100644 tests/virhostcpudata/linux-rhel74-moonshot/node/possible diff --git a/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.cpuinfo b/t= ests/virhostcpudata/linux-aarch64-rhel74-moonshot.cpuinfo new file mode 100644 index 000000000..ae528bf61 --- /dev/null +++ b/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.cpuinfo @@ -0,0 +1,72 @@ +processor : 0 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 1 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 2 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 3 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 4 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 5 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 6 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + +processor : 7 +BogoMIPS : 100.00 +Features : fp asimd evtstrm cpuid +CPU implementer : 0x50 +CPU architecture: 8 +CPU variant : 0x0 +CPU part : 0x000 +CPU revision : 1 + diff --git a/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected b/= tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected new file mode 100644 index 000000000..24ff0ea0b --- /dev/null +++ b/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected @@ -0,0 +1 @@ +CPUs: 8/8, MHz: 100, Nodes: 1, Sockets: 1, Cores: 8, Threads: 1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_= id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topolo= gy/thread_siblings new file mode 100644 index 000000000..8a0f05e16 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/thread_s= iblings @@ -0,0 +1 @@ +01 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/t= opology/thread_siblings_list new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu0/topology/thread_s= iblings_list @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_= id new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_id @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topolo= gy/thread_siblings new file mode 100644 index 000000000..9e22bcb8e --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/thread_s= iblings @@ -0,0 +1 @@ +02 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/t= opology/thread_siblings_list new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu1/topology/thread_s= iblings_list @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_= id new file mode 100644 index 000000000..0cfbf0888 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_id @@ -0,0 +1 @@ +2 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topolo= gy/thread_siblings new file mode 100644 index 000000000..64969239d --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/thread_s= iblings @@ -0,0 +1 @@ +04 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/t= opology/thread_siblings_list new file mode 100644 index 000000000..0cfbf0888 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu2/topology/thread_s= iblings_list @@ -0,0 +1 @@ +2 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_= id new file mode 100644 index 000000000..00750edc0 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_id @@ -0,0 +1 @@ +3 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topolo= gy/thread_siblings new file mode 100644 index 000000000..adb9de8ee --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/thread_s= iblings @@ -0,0 +1 @@ +08 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/t= opology/thread_siblings_list new file mode 100644 index 000000000..00750edc0 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu3/topology/thread_s= iblings_list @@ -0,0 +1 @@ +3 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_= id new file mode 100644 index 000000000..b8626c4cf --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_id @@ -0,0 +1 @@ +4 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topolo= gy/thread_siblings new file mode 100644 index 000000000..f599e28b8 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/thread_s= iblings @@ -0,0 +1 @@ +10 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/t= opology/thread_siblings_list new file mode 100644 index 000000000..b8626c4cf --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu4/topology/thread_s= iblings_list @@ -0,0 +1 @@ +4 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_= id new file mode 100644 index 000000000..7ed6ff82d --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_id @@ -0,0 +1 @@ +5 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topolo= gy/thread_siblings new file mode 100644 index 000000000..209e3ef4b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/thread_s= iblings @@ -0,0 +1 @@ +20 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/t= opology/thread_siblings_list new file mode 100644 index 000000000..7ed6ff82d --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu5/topology/thread_s= iblings_list @@ -0,0 +1 @@ +5 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_= id new file mode 100644 index 000000000..1e8b31496 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_id @@ -0,0 +1 @@ +6 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topolo= gy/thread_siblings new file mode 100644 index 000000000..425151f3a --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/thread_s= iblings @@ -0,0 +1 @@ +40 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/t= opology/thread_siblings_list new file mode 100644 index 000000000..1e8b31496 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu6/topology/thread_s= iblings_list @@ -0,0 +1 @@ +6 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/node0 b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/node0 new file mode 120000 index 000000000..222b6af32 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/node0 @@ -0,0 +1 @@ +../../node/node0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/online b/t= ests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/online new file mode 100644 index 000000000..d00491fd7 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/online @@ -0,0 +1 @@ +1 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/c= ore_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_= id new file mode 100644 index 000000000..7f8f011eb --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_id @@ -0,0 +1 @@ +7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/c= ore_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology= /core_siblings new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_sib= lings @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/c= ore_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/top= ology/core_siblings_list new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/core_sib= lings_list @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/p= hysical_package_id b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/to= pology/physical_package_id new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/physical= _package_id @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/t= hread_siblings b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topolo= gy/thread_siblings new file mode 100644 index 000000000..d15a2cc44 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/thread_s= iblings @@ -0,0 +1 @@ +80 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/t= hread_siblings_list b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/t= opology/thread_siblings_list new file mode 100644 index 000000000..7f8f011eb --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/cpu7/topology/thread_s= iblings_list @@ -0,0 +1 @@ +7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/kernel_max b/te= sts/virhostcpudata/linux-rhel74-moonshot/cpu/kernel_max new file mode 100644 index 000000000..50b0f7906 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/kernel_max @@ -0,0 +1 @@ +4095 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/offline b/tests= /virhostcpudata/linux-rhel74-moonshot/cpu/offline new file mode 100644 index 000000000..8b1378917 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/offline @@ -0,0 +1 @@ + diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/online b/tests/= virhostcpudata/linux-rhel74-moonshot/cpu/online new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/online @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/possible b/test= s/virhostcpudata/linux-rhel74-moonshot/cpu/possible new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/possible @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/cpu/present b/tests= /virhostcpudata/linux-rhel74-moonshot/cpu/present new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/cpu/present @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/has_cpu b/test= s/virhostcpudata/linux-rhel74-moonshot/node/has_cpu new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/has_cpu @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/has_memory b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/has_memory new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/has_memory @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/has_normal_mem= ory b/tests/virhostcpudata/linux-rhel74-moonshot/node/has_normal_memory new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/has_normal_memory @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu0 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu0 new file mode 120000 index 000000000..c841bea28 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu0 @@ -0,0 +1 @@ +../../cpu/cpu0 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu1 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu1 new file mode 120000 index 000000000..5f4536279 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu1 @@ -0,0 +1 @@ +../../cpu/cpu1 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu2 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu2 new file mode 120000 index 000000000..2dcca332c --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu2 @@ -0,0 +1 @@ +../../cpu/cpu2 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu3 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu3 new file mode 120000 index 000000000..c7690e5aa --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu3 @@ -0,0 +1 @@ +../../cpu/cpu3 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu4 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu4 new file mode 120000 index 000000000..9e77a64eb --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu4 @@ -0,0 +1 @@ +../../cpu/cpu4 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu5 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu5 new file mode 120000 index 000000000..cc07c3b97 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu5 @@ -0,0 +1 @@ +../../cpu/cpu5 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu6 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu6 new file mode 120000 index 000000000..2e7576354 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu6 @@ -0,0 +1 @@ +../../cpu/cpu6 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu7 b/t= ests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu7 new file mode 120000 index 000000000..09e3f79b4 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpu7 @@ -0,0 +1 @@ +../../cpu/cpu7 \ No newline at end of file diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpulist = b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpulist new file mode 100644 index 000000000..74fc2fb6b --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpulist @@ -0,0 +1 @@ +0-7 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpumap b= /tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpumap new file mode 100644 index 000000000..fcd15acf9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/node0/cpumap @@ -0,0 +1 @@ +ff diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/online b/tests= /virhostcpudata/linux-rhel74-moonshot/node/online new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/online @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcpudata/linux-rhel74-moonshot/node/possible b/tes= ts/virhostcpudata/linux-rhel74-moonshot/node/possible new file mode 100644 index 000000000..573541ac9 --- /dev/null +++ b/tests/virhostcpudata/linux-rhel74-moonshot/node/possible @@ -0,0 +1 @@ +0 diff --git a/tests/virhostcputest.c b/tests/virhostcputest.c index d1208c373..d3ee18461 100644 --- a/tests/virhostcputest.c +++ b/tests/virhostcputest.c @@ -239,6 +239,7 @@ mymain(void) {"raspberrypi", VIR_ARCH_ARMV6L}, {"f21-mustang", VIR_ARCH_AARCH64}, {"rhelsa-3.19.0-mustang", VIR_ARCH_AARCH64}, + {"rhel74-moonshot", VIR_ARCH_AARCH64}, {"deconf-cpus", VIR_ARCH_PPC64}, /* subcores, default configuration */ {"subcores1", VIR_ARCH_PPC64}, --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Mon Apr 29 16:48:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1513181450127925.6762221078762; Wed, 13 Dec 2017 08:10:50 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 27E19C0828D4; Wed, 13 Dec 2017 16:10:49 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E94FD7BFF2; Wed, 13 Dec 2017 16:10:48 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id B503D3FCFD; Wed, 13 Dec 2017 16:10:48 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id vBDGAZnE027237 for ; Wed, 13 Dec 2017 11:10:35 -0500 Received: by smtp.corp.redhat.com (Postfix) id EE1977BA56; Wed, 13 Dec 2017 16:10:35 +0000 (UTC) Received: from inaba.usersys.redhat.com (unknown [10.40.205.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B1FE87BA3D for ; Wed, 13 Dec 2017 16:10:33 +0000 (UTC) From: Andrea Bolognani To: libvir-list@redhat.com Date: Wed, 13 Dec 2017 17:10:19 +0100 Message-Id: <20171213161021.28525-3-abologna@redhat.com> In-Reply-To: <20171213161021.28525-1-abologna@redhat.com> References: <20171213161021.28525-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH v2 2/4] util: virhostcpu: factor out frequency parsing X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Wed, 13 Dec 2017 16:10:49 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" From: Bjoern Walk All different architectures use the same copy-pasted code to parse processor frequency information from /proc/cpuinfo. Let's extract that code into a function to avoid repetition. We now also tolerate if the parsing of /proc/cpuinfo is not successful and just report a warning instead of bailing out and abandoning the rest of the CPU information. Reviewed-by: Marc Hartmayer Reviewed-by: Boris Fiuczynski Reviewed-by: Andrea Bolognani Signed-off-by: Bjoern Walk --- Changes from Bjoern's original version: * rename virHostCPUParseFrequencyLine() to virHostCPUParseFrequencyString(). src/util/virhostcpu.c | 136 +++++++++++++++++++++-------------------------= ---- 1 file changed, 57 insertions(+), 79 deletions(-) diff --git a/src/util/virhostcpu.c b/src/util/virhostcpu.c index c485a9721..3091a92c0 100644 --- a/src/util/virhostcpu.c +++ b/src/util/virhostcpu.c @@ -508,6 +508,61 @@ virHostCPUHasValidSubcoreConfiguration(int threads_per= _subcore) return ret; } =20 +static int +virHostCPUParseFrequencyString(const char *str, + unsigned int *mhz) +{ + char *p; + unsigned int ui; + + while (*str && c_isspace(*str)) + str++; + + if (*str !=3D ':' || !str[1]) { + virReportError(VIR_ERR_INTERNAL_ERROR, "%s", + _("parsing cpu MHz from cpuinfo")); + return -1; + } + + if (virStrToLong_ui(str + 1, &p, 10, &ui) =3D=3D 0 && + /* Accept trailing fractional part. */ + (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) + *mhz =3D ui; + + return 0; +} + +static int +virHostCPUParseFrequency(FILE *cpuinfo, + virArch arch, + unsigned int *mhz) +{ + const char *prefix =3D NULL; + char line[1024]; + + if (ARCH_IS_X86(arch)) + prefix =3D "cpu MHz"; + else if (ARCH_IS_PPC(arch)) + prefix =3D "clock"; + else if (ARCH_IS_ARM(arch)) + prefix =3D "BogoMIPS"; + + if (!prefix) { + VIR_WARN("Parser for /proc/cpuinfo needs to be adapted for your ar= chitecture"); + return 1; + } + + while (fgets(line, sizeof(line), cpuinfo) !=3D NULL) { + if (!STRPREFIX(line, prefix)) + continue; + + if (virHostCPUParseFrequencyString(line + strlen(prefix), mhz) < 0) + return -1; + } + + return 0; +} + int virHostCPUGetInfoPopulateLinux(FILE *cpuinfo, virArch arch, @@ -520,7 +575,6 @@ virHostCPUGetInfoPopulateLinux(FILE *cpuinfo, { virBitmapPtr present_cpus_map =3D NULL; virBitmapPtr online_cpus_map =3D NULL; - char line[1024]; DIR *nodedir =3D NULL; struct dirent *nodedirent =3D NULL; int nodecpus, nodecores, nodesockets, nodethreads, offline =3D 0; @@ -535,84 +589,8 @@ virHostCPUGetInfoPopulateLinux(FILE *cpuinfo, *cpus =3D *nodes =3D *sockets =3D *cores =3D *threads =3D 0; =20 /* Start with parsing CPU clock speed from /proc/cpuinfo */ - while (fgets(line, sizeof(line), cpuinfo) !=3D NULL) { - if (ARCH_IS_X86(arch)) { - char *buf =3D line; - if (STRPREFIX(buf, "cpu MHz")) { - char *p; - unsigned int ui; - - buf +=3D 7; - while (*buf && c_isspace(*buf)) - buf++; - - if (*buf !=3D ':' || !buf[1]) { - virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("parsing cpu MHz from cpuinfo")); - goto cleanup; - } - - if (virStrToLong_ui(buf+1, &p, 10, &ui) =3D=3D 0 && - /* Accept trailing fractional part. */ - (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) - *mhz =3D ui; - } - } else if (ARCH_IS_PPC(arch)) { - char *buf =3D line; - if (STRPREFIX(buf, "clock")) { - char *p; - unsigned int ui; - - buf +=3D 5; - while (*buf && c_isspace(*buf)) - buf++; - - if (*buf !=3D ':' || !buf[1]) { - virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("parsing cpu MHz from cpuinfo")); - goto cleanup; - } - - if (virStrToLong_ui(buf+1, &p, 10, &ui) =3D=3D 0 && - /* Accept trailing fractional part. */ - (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) - *mhz =3D ui; - /* No other interesting infos are available in /proc/cpuin= fo. - * However, there is a line identifying processor's versio= n, - * identification and machine, but we don't want it to be = caught - * and parsed in next iteration, because it is not in expe= cted - * format and thus lead to error. */ - } - } else if (ARCH_IS_ARM(arch)) { - char *buf =3D line; - if (STRPREFIX(buf, "BogoMIPS")) { - char *p; - unsigned int ui; - - buf +=3D 8; - while (*buf && c_isspace(*buf)) - buf++; - - if (*buf !=3D ':' || !buf[1]) { - virReportError(VIR_ERR_INTERNAL_ERROR, - "%s", _("parsing cpu MHz from cpuinfo")= ); - goto cleanup; - } - - if (virStrToLong_ui(buf+1, &p, 10, &ui) =3D=3D 0 - /* Accept trailing fractional part. */ - && (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) - *mhz =3D ui; - } - } else if (ARCH_IS_S390(arch)) { - /* s390x has no realistic value for CPU speed, - * assign a value of zero to signify this */ - *mhz =3D 0; - } else { - VIR_WARN("Parser for /proc/cpuinfo needs to be adapted for you= r architecture"); - break; - } - } + if (virHostCPUParseFrequency(cpuinfo, arch, mhz) < 0) + VIR_WARN("Unable to parse processor frequency information from /pr= oc/cpuinfo"); =20 /* Get information about what CPUs are present in the host and what * CPUs are online, so that we don't have to so for each node */ --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Mon Apr 29 16:48:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 151318144096721.84503206993861; Wed, 13 Dec 2017 08:10:40 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8FCFF5F739; Wed, 13 Dec 2017 16:10:39 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 68BFA78DE7; Wed, 13 Dec 2017 16:10:39 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 2A0FA4A46A; Wed, 13 Dec 2017 16:10:39 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id vBDGAbth027247 for ; Wed, 13 Dec 2017 11:10:37 -0500 Received: by smtp.corp.redhat.com (Postfix) id 7E3CA7BA5D; Wed, 13 Dec 2017 16:10:37 +0000 (UTC) Received: from inaba.usersys.redhat.com (unknown [10.40.205.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8CA7B7BA3D for ; Wed, 13 Dec 2017 16:10:36 +0000 (UTC) From: Andrea Bolognani To: libvir-list@redhat.com Date: Wed, 13 Dec 2017 17:10:20 +0100 Message-Id: <20171213161021.28525-4-abologna@redhat.com> In-Reply-To: <20171213161021.28525-1-abologna@redhat.com> References: <20171213161021.28525-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH v2 3/4] util: Tweak virHostCPUParseFrequencyString() X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Wed, 13 Dec 2017 16:10:40 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Just a couple of small cosmetic improvements. Signed-off-by: Andrea Bolognani Reviewed-by: Bjoern Walk --- src/util/virhostcpu.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/util/virhostcpu.c b/src/util/virhostcpu.c index 3091a92c0..2259c9f2f 100644 --- a/src/util/virhostcpu.c +++ b/src/util/virhostcpu.c @@ -518,16 +518,19 @@ virHostCPUParseFrequencyString(const char *str, while (*str && c_isspace(*str)) str++; =20 - if (*str !=3D ':' || !str[1]) { - virReportError(VIR_ERR_INTERNAL_ERROR, "%s", - _("parsing cpu MHz from cpuinfo")); + if (str[0] !=3D ':' || !str[1]) { + virReportError(VIR_ERR_INTERNAL_ERROR, + _("Missing or invalid CPU frequency in %s"), + CPUINFO_PATH); return -1; } =20 + /* Accept an unsigned value, optionally followed by + * a fractional part (which gets discarded) */ if (virStrToLong_ui(str + 1, &p, 10, &ui) =3D=3D 0 && - /* Accept trailing fractional part. */ - (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) + (*p =3D=3D '\0' || *p =3D=3D '.' || c_isspace(*p))) { *mhz =3D ui; + } =20 return 0; } --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Mon Apr 29 16:48:30 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1513181450100831.8226709805888; Wed, 13 Dec 2017 08:10:50 -0800 (PST) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 77B4F6A7CA; Wed, 13 Dec 2017 16:10:47 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 49BFE6C503; Wed, 13 Dec 2017 16:10:47 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 11B3C180474C; Wed, 13 Dec 2017 16:10:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id vBDGAdHW027253 for ; Wed, 13 Dec 2017 11:10:39 -0500 Received: by smtp.corp.redhat.com (Postfix) id 0EEF97BA50; Wed, 13 Dec 2017 16:10:39 +0000 (UTC) Received: from inaba.usersys.redhat.com (unknown [10.40.205.29]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1B4A77BA3D for ; Wed, 13 Dec 2017 16:10:37 +0000 (UTC) From: Andrea Bolognani To: libvir-list@redhat.com Date: Wed, 13 Dec 2017 17:10:21 +0100 Message-Id: <20171213161021.28525-5-abologna@redhat.com> In-Reply-To: <20171213161021.28525-1-abologna@redhat.com> References: <20171213161021.28525-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH v2 4/4] util: Don't report CPU frequency for ARM hosts X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Wed, 13 Dec 2017 16:10:48 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Some ARM platforms, such as the original Raspberry Pi, report the CPU frequency in the BogoMIPS field of /proc/cpuinfo, so libvirt parsed that field and returned it through its API. However, not only many more boards don't report any value there, but several - including ARMv8-based server hardware, and even the more recent Raspberry Pi 3 - use this field as originally intended: to report the BogoMIPS value instead of the CPU frequency. Since we have no way of detecting how the field is being used, it's better to report no information at all rather than something ludicrous like "your shiny 96-core aarch64 virtualization host's CPUs are running at a whopping 100 MHz". Signed-off-by: Andrea Bolognani --- src/util/virhostcpu.c | 6 ++++-- tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected | 2 +- tests/virhostcpudata/linux-armv6l-raspberrypi.expected | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/util/virhostcpu.c b/src/util/virhostcpu.c index 2259c9f2f..24fbe42f6 100644 --- a/src/util/virhostcpu.c +++ b/src/util/virhostcpu.c @@ -543,12 +543,14 @@ virHostCPUParseFrequency(FILE *cpuinfo, const char *prefix =3D NULL; char line[1024]; =20 + /* No sensible way to retrieve CPU frequency */ + if (ARCH_IS_ARM(arch)) + return 0; + if (ARCH_IS_X86(arch)) prefix =3D "cpu MHz"; else if (ARCH_IS_PPC(arch)) prefix =3D "clock"; - else if (ARCH_IS_ARM(arch)) - prefix =3D "BogoMIPS"; =20 if (!prefix) { VIR_WARN("Parser for /proc/cpuinfo needs to be adapted for your ar= chitecture"); diff --git a/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected b/= tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected index 24ff0ea0b..6776aa6c2 100644 --- a/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected +++ b/tests/virhostcpudata/linux-aarch64-rhel74-moonshot.expected @@ -1 +1 @@ -CPUs: 8/8, MHz: 100, Nodes: 1, Sockets: 1, Cores: 8, Threads: 1 +CPUs: 8/8, MHz: 0, Nodes: 1, Sockets: 1, Cores: 8, Threads: 1 diff --git a/tests/virhostcpudata/linux-armv6l-raspberrypi.expected b/tests= /virhostcpudata/linux-armv6l-raspberrypi.expected index 146bd073e..1c4c713d5 100644 --- a/tests/virhostcpudata/linux-armv6l-raspberrypi.expected +++ b/tests/virhostcpudata/linux-armv6l-raspberrypi.expected @@ -1 +1 @@ -CPUs: 1/1, MHz: 697, Nodes: 1, Sockets: 1, Cores: 1, Threads: 1 +CPUs: 1/1, MHz: 0, Nodes: 1, Sockets: 1, Cores: 1, Threads: 1 --=20 2.14.3 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list