From nobody Mon Feb 9 19:06:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) client-ip=66.175.222.12; envelope-from=bounce+27952+48565+1787277+3901457@groups.io; helo=web01.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+48565+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1570534044; cv=none; d=zoho.com; s=zohoarc; b=cnugygX57TB63HUYN6YTDdg8Imqy119HEcPdGx5qcsjvTry3YGNMb4LBxufuXKhqWXXOqo1tb0wGg89LHu+MZIYdgSidFnrTQCBDVuupKZB8pAI3fcCg031R1o08ihclrY46DVrxOPavB4d3UU1LcevegxXq133/IrgP5dSYPmI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1570534044; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Id:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:References:Sender:Subject:To:ARC-Authentication-Results; bh=l1UIsCz+/JYNQd7LeKKpBkc3yRG28czjKHUEXGaMopI=; b=FMWfju97kiZRGB0rJzPdaNv9jlMokIM23xx1CBTjS+ERtUFdIYc0oNc0ujjwQ510jcZgx7E599Xof30XdfUcR4qEdlGtnpf8ItshPCsw31ApmDRvDP5QAieDixyLH662HPdAPbnRJOnd91Uq80+WGmv1AQfLvef6UvKRGo1bgns= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass; spf=pass (zoho.com: domain of groups.io designates 66.175.222.12 as permitted sender) smtp.mailfrom=bounce+27952+48565+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) header.from= Received: from web01.groups.io (web01.groups.io [66.175.222.12]) by mx.zohomail.com with SMTPS id 1570534044769144.32381034450327; Tue, 8 Oct 2019 04:27:24 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id AsTnYY1788612xeDUT9ncPJt; Tue, 08 Oct 2019 04:27:24 -0700 X-Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by groups.io with SMTP; Tue, 08 Oct 2019 04:27:23 -0700 X-Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 8167D87633; Tue, 8 Oct 2019 11:27:23 +0000 (UTC) X-Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-109.rdu2.redhat.com [10.10.120.109]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5D871600CE; Tue, 8 Oct 2019 11:27:22 +0000 (UTC) From: "Laszlo Ersek" To: edk2-devel-groups-io Cc: Ard Biesheuvel , Igor Mammedov , Jordan Justen Subject: [edk2-devel] [PATCH 3/4] OvmfPkg/IndustryStandard: define FW_CFG_X86_TOPOLOGY structure type Date: Tue, 8 Oct 2019 13:27:13 +0200 Message-Id: <20191008112714.6215-4-lersek@redhat.com> In-Reply-To: <20191008112714.6215-1-lersek@redhat.com> References: <20191008112714.6215-1-lersek@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Tue, 08 Oct 2019 11:27:23 +0000 (UTC) Precedence: Bulk List-Unsubscribe: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,lersek@redhat.com X-Gm-Message-State: gK0MmG3PmUQAyMA3K5nQAPUBx1787277AA= Content-Transfer-Encoding: quoted-printable DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1570534044; bh=rdssITTH953k3eD6qI+Uq0vryF20Ra/PC+F+7NILo4A=; h=Cc:Date:From:Reply-To:Subject:To; b=KgEjcxegUK0yXNAQRFmY8oyh5SNN8mmNyybytwHwhqM9p2EBCFEqYQQesyR4C+XPxJC qpDlF3dI5QvPBJwKd1hksFUnqrKyJvLzFq14Ka56Xg4CkAkcWDdVB8FqiYU6e970/jzmt 2HASR1MhSIglEymIQxMvgU8WG6BnuxjheEc= X-ZohoMail-DKIM: pass (identity @groups.io) Content-Type: text/plain; charset="utf-8" pc-q35-4.2+ and pc-i440fx-4.2+ machine types report CPU topology info in the "etc/x86-smp-topology" fw_cfg file. Add a structure type for parsing this blob. Cc: Ard Biesheuvel Cc: Igor Mammedov Cc: Jordan Justen Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=3D1515 Signed-off-by: Laszlo Ersek --- OvmfPkg/Include/IndustryStandard/QemuFwCfg.h | 22 ++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/OvmfPkg/Include/IndustryStandard/QemuFwCfg.h b/OvmfPkg/Include= /IndustryStandard/QemuFwCfg.h index 7969aba3ca61..fe410d4a3fc2 100644 --- a/OvmfPkg/Include/IndustryStandard/QemuFwCfg.h +++ b/OvmfPkg/Include/IndustryStandard/QemuFwCfg.h @@ -95,4 +95,26 @@ typedef struct { } FW_CFG_DMA_ACCESS; #pragma pack () =20 +// +// Structure describing the VCPU topology on IA32 and X64, in the fw_cfg f= ile +// named "etc/x86-smp-topology". +// +// All fields are little endian. +// +// The number of sockets (aka packages) can be calculated by dividing +// MaxLogicalProcessors by (DiesPerSocket * CoresPerDie * ThreadsPerCore),= and +// rounding up the quotient. +// +// APIC ID field widths and offsets can be derived with the standard method +// described in "Intel(R) 64 Architecture Processor Topology Enumeration" +// . +// +#pragma pack (1) +typedef struct { + UINT32 DiesPerSocket; + UINT32 CoresPerDie; + UINT32 ThreadsPerCore; + UINT32 MaxLogicalProcessors; +} FW_CFG_X86_TOPOLOGY; +#pragma pack () #endif --=20 2.19.1.3.g30247aa5d201 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#48565): https://edk2.groups.io/g/devel/message/48565 Mute This Topic: https://groups.io/mt/34441230/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-