From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from blyat.fensystems.co.uk (blyat.fensystems.co.uk [54.246.183.96]) by mx.groups.io with SMTP id smtpd.web10.64969.1643811507666916221 for ; Wed, 02 Feb 2022 06:18:28 -0800 Authentication-Results: mx.groups.io; dkim=missing; spf=pass (domain: ipxe.org, ip: 54.246.183.96, mailfrom: mcb30@ipxe.org) Received: from pudding.home (unknown [188.94.42.109]) by blyat.fensystems.co.uk (Postfix) with ESMTPSA id 8BD85442D4; Wed, 2 Feb 2022 14:18:23 +0000 (UTC) Subject: Re: [edk2-devel] [PATCH] MdeModulePkg/Frontpage: Get SMBIOS Data from table directly To: Sean Rhodes , devel@edk2.groups.io References: <16423.1643792532398151864@groups.io> From: "Michael Brown" Message-ID: <92f01a8f-5ef3-2002-c2a7-c32c2a5132f9@ipxe.org> Date: Wed, 2 Feb 2022 14:18:22 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <16423.1643792532398151864@groups.io> X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on blyat.fensystems.co.uk Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit On 02/02/2022 09:02, Sean Rhodes wrote: > Not quite sure how to implement that, are there any existing use cases > that I can look at? From the way that your patch uses SMBIOS data, I'm assuming that your use case involves a pre-existing SMBIOS table structure that is constructed by something (e.g. coreboot) before UEFI starts up, and that you want to extract information from this table. If this assumption is correct, then the use case looks similar to the way that OvmfPkg handles a pre-existing SMBIOS table constructed by the hypervisor: the binary table is minimally parsed and all structures are handed over to UEFI via EFI_SMBIOS_PROTOCOL.Add(). This means that all structures from the pre-existing SMBIOS table are available to any UEFI SMBIOS consumers. See, for example OvmfPkg/SmbiosPlatformDxe/SmbiosPlatformDxe.c. HTH, Michael