From nobody Wed May 15 15:53:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1585738632; cv=none; d=zohomail.com; s=zohoarc; b=cjjCO91Q3aWqjL353niiFd4EoirNp4h5V2XWz73P24JRD+hUaoJ9/3RY0YQoBeWlqETB8h0AxzFpy88LTEK0Ln14WqMUT6fCN0YVsjraz7+LG37A7VcCicUTK0ka2tzy6CSHZFWsM5dBQNHvi0tbAoCQFYYGo8FD00Vq6wGgblw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1585738632; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=6Dpx8YDbroq96N0jpq7bpLDdm6wwJopbze4Qzv7jmTk=; b=Zjj/BD4Hvq/CC/X3SZv/riJ/38WEsMI2MHj+aYn1GLVZy1+Se41X2s7Z8QvhB1lo/rPvO1lqKYyB046Jrd9QIskISm8afSb0YAsNQyvuMxciLVBoI3hHlDwGtTI+6AUcCfqnOeBA5cc8IPzxY3sFmo6URTnKqlK0gU9XulY7hG8= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1585738632016166.7485915777446; Wed, 1 Apr 2020 03:57:12 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-417-1p98ok5wMvuIXjoj_zzZXA-1; Wed, 01 Apr 2020 06:57:08 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 76D45100DFC1; Wed, 1 Apr 2020 10:57:00 +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 2646E99DF2; Wed, 1 Apr 2020 10:56:59 +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 7F8C238A1; Wed, 1 Apr 2020 10:56:55 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 031AusOE025272 for ; Wed, 1 Apr 2020 06:56:54 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0738E2166B2F; Wed, 1 Apr 2020 10:56:54 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast02.extmail.prod.ext.rdu2.redhat.com [10.11.55.18]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 02C2B2166B31 for ; Wed, 1 Apr 2020 10:56:51 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id D9FE08007CB for ; Wed, 1 Apr 2020 10:56:51 +0000 (UTC) Received: from mail-qk1-f195.google.com (mail-qk1-f195.google.com [209.85.222.195]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-476-0670qzEINgyrS5Go1XwBtg-1; Wed, 01 Apr 2020 06:56:49 -0400 Received: by mail-qk1-f195.google.com with SMTP id v7so26538877qkc.0 for ; Wed, 01 Apr 2020 03:56:49 -0700 (PDT) Received: from rekt.redhat.com ([2804:431:c7c7:7711:d2ec:eb37:616b:35b1]) by smtp.gmail.com with ESMTPSA id f71sm1189075qke.57.2020.04.01.03.56.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2020 03:56:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1585738630; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=6Dpx8YDbroq96N0jpq7bpLDdm6wwJopbze4Qzv7jmTk=; b=VmSou/3p2VdSOAyI8p/gSZe5KlLmqRcUl8MJlW8CxodBr+YfDpZF8kj81GNz0A8rTJlW8v GoA6JSG5+pcHFlOXJHuNjkLO73YUXfLZdO4pB3cpZ7ax7UEbqyq8jSLQxKFRfUdA49Rb+S mSrXIRkeVf/QIx6NJt1qiTuMTciPTRE= X-MC-Unique: 1p98ok5wMvuIXjoj_zzZXA-1 X-MC-Unique: 0670qzEINgyrS5Go1XwBtg-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=WPv/Q1Hia/AiNeIgMZpoW0xgEbgCVcDRcQwtU4jwICE=; b=HS2zIviSpqiACU0bS9OPBE23UlIjooxNM8tu7pZUhuEkjeyIHKcIyzagwOsUhrhQp5 jLUSD6tJm40+p6gNCp86mzS0SBtKz+chcligvcbFg2Qw9w3P3gCGdHXB53vBlE0y4Stc zGy5LXpMzXpXGyq3iK2U3PRdzHG75Bol0e4GJqIs6O3rdMGfhA/YRL9cadgD9HdTcIzs d0Xz4NOmHXhuuZE4gSj8vlx6et/IOkQi7KtHpPP+69R528R5GrUulvgvOdKdxqjBOjKX GtkhqAU280n7IAPbCTXK3LiojcZ1Kz7XHdVMczBaszbXQiDvV20L/0RP33C3XBmnAZOO l9Ag== X-Gm-Message-State: ANhLgQ1ANwGkmvQDWMy6SeZ8KczTC9m2tyHCGrc+iFQaeMW2XOMiGeP9 CbIVwVWQDQ3A4XySD3T/Y2oEdMOs X-Google-Smtp-Source: ADFU+vvzrCesCpERAErnLivio2bJC6mSGS6w5yUMhg7Mz6qhk1IXHdE8ccSWnqjLbU4aH99kfcaJjQ== X-Received: by 2002:a37:981:: with SMTP id 123mr9355834qkj.154.1585738608872; Wed, 01 Apr 2020 03:56:48 -0700 (PDT) From: Daniel Henrique Barboza To: libvir-list@redhat.com Subject: [PATCH] formatdomain.html.in: fix 'sockets' info in topology element Date: Wed, 1 Apr 2020 07:56:37 -0300 Message-Id: <20200401105638.612183-1-danielhb413@gmail.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-MIME-Autoconverted: from quoted-printable to 8bit by lists01.pubmisc.prod.ext.phx2.redhat.com id 031AusOE025272 X-loop: libvir-list@redhat.com Cc: Daniel Henrique Barboza 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: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" In the 'topology' element it is mentioned, regarding the sockets value, "They refer to the total number of CPU sockets". This is not accurate. What we're doing is calculating the number of sockets per NUMA node, which can be checked in the current implementation of virHostCPUGetInfoPopulateLinux(). Calculating the total number of sockets would break the topology sanity check nodes*sockets*cores*threads=3Donline_cpus. This documentation fix is important to avoid user confusion when seeing the output of 'virsh capabilities' and expecting it to be equal to the output of 'lscpu'. E.g in a Power 9 host this 'lscpu' output: Architecture: ppc64le Byte Order: Little Endian CPU(s): 160 On-line CPU(s) list: 0-159 Thread(s) per core: 4 Core(s) per socket: 20 Socket(s): 2 NUMA node(s): 2 Model: 2.2 (pvr 004e 1202) Model name: POWER9, altivec supported And this XML output from virsh capabilities: ppc64le POWER9 IBM (...) Both are correct, as long as we mention in the Libvirt documentation that 'sockets' in the topology element represents the number of sockets per NUMA node. Signed-off-by: Daniel Henrique Barboza Reviewed-by: Michal Privoznik --- docs/formatdomain.html.in | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index aaeb05961f..7940d6ace5 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -1675,9 +1675,9 @@
The topology element specifies requested topology of virtual CPU provided to the guest. Four attributes, sockets<= /code>, dies, cores, and threads, - accept non-zero positive integer values. They refer to the total n= umber - of CPU sockets, number of dies per socket, number of cores per die= , and - number of threads per core, respectively. The dies + accept non-zero positive integer values. They refer to the number = of + CPU sockets per NUMA node, number of dies per socket, number of co= res + per die, and number of threads per core, respectively. The d= ies attribute is optional and will default to 1 if omitted, while the = other attributes are all mandatory. Hypervisors may require that the max= imum number of vCPUs specified by the cpus element equals = to --=20 2.25.1