Acidanthera UEFI Development Kit based on EDK II edk2-stable202311
Go to file
Laszlo Ersek 37baf06b44 OvmfPkg: PlatformPei: set SMBIOS entry point version dynamically
Git commit 54753b60 (SVN r16870), "MdeModulePkg: Update SMBIOS revision to
3.0." changed PcdSmbiosVersion from 0x0208 to 0x0300. This controls the
version number of the SMBIOS entry point table (and other things) that
"MdeModulePkg/Universal/SmbiosDxe" installs.

Alas, this change breaks older Linux guests, like RHEL-6 (up to RHEL-6.7);
those are limited to 2.x (both in the guest kernel firmware driver, and in
the dmidecode utility). The SMBIOS 3.0 entry point has a different GUID --
defined in UEFI 2.5 -- pointing to it in the UEFI Configuration Table, and
guest kernels that lack upstream kernel commit e1ccbbc9d5 don't recognize
it.

The v2.1.0+ machine types of QEMU generate SMBIOS payload for the firmware
to install. The payload includes the entry point table ("anchor" table).
OvmfPkg/SmbiosPlatformDxe cannot install the anchor table (because that is
the jurisdiction of the generic "MdeModulePkg/Universal/SmbiosDxe"
driver); however, we can parse the entry point version from QEMU's anchor
table, and instruct "MdeModulePkg/Universal/SmbiosDxe" to adhere to that
version.

On machine types older than v2.1.0, the feature is not available, but
then, should anything in OVMF install SMBIOS tables, version 2.8 is simply
safer / more widely supported than 3.0 -- hence the default 2.8 value for
the dynamic PCD.

We set the PCD in PlatformPei (when not on the S3 resume path), because
that's an easy and certain way to set the PCD before a DXE driver reads
it. This follows the example of PcdEmuVariableNvStoreReserved (which is
read by EmuVariableFvbRuntimeDxe).

RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1232876
Cc: Gabriel Somlo <somlo@cmu.edu>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
Acked-by: Gabriel Somlo <somlo@cmu.edu>

git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17676 6f19259b-4bc3-4df7-8a09-765794883524
2015-06-22 17:11:05 +00:00
AppPkg */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
ArmPkg ArmPkg/ArmLib: Fixed build after recent BaseTools changes 2015-06-15 15:31:29 +00:00
ArmPlatformPkg Renamed ArmPlatformPkg/ArmVirtualizationPkg into ArmVirtPkg 2015-05-29 13:50:43 +00:00
ArmVirtPkg ArmVirtPkg: increase memory preallocations for secure build 2015-06-16 14:27:18 +00:00
BaseTools BaseTools: Fixed Build Option override bugs. 2015-06-19 01:43:45 +00:00
BeagleBoardPkg ArmPlaformPkg: Replaced gArmPlatformTokenSpaceGuid.PcdPlatformBootTimeOut 2015-05-13 18:25:47 +00:00
Conf EDK II: Add .gitignore 2014-10-14 16:08:15 +00:00
CorebootModulePkg CorebootModulePkg/CbSupportPei: Relace tabs with whitespaces 2015-06-03 02:48:07 +00:00
CorebootPayloadPkg CorebootPayloadPkg: Replace PciHostBridge driver with PciRootBridgeNoEnumeration 2015-05-11 15:52:31 +00:00
CryptoPkg CryptoPkg: Add some comments for API usage clarification. 2015-06-19 02:46:51 +00:00
DuetPkg DuetPkg: Use the new PCDs defined in MdePkg. 2015-05-06 03:26:49 +00:00
EdkCompatibilityPkg EdkCompatibilityPkg SmmBaseHelper: Unregister profile image correctly. 2015-06-09 09:42:15 +00:00
EdkShellBinPkg */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
EdkShellPkg */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
EmbeddedPkg EmbeddedPkg/AcpiLib: Introduced LocateAndInstallAcpiFromFvConditional() 2015-05-29 14:39:41 +00:00
EmulatorPkg EmulatorPkg: Use the new PCDs defined in MdePkg. 2015-05-06 03:28:12 +00:00
FatBinPkg FatBinPkg: Update ARM and AArch64 binaries 2015-02-27 17:27:42 +00:00
IntelFrameworkModulePkg IntelFrameworkModulePkg/IsaSerialDxe: Use PcdSerialClockRate instead of hard code value 2015-06-10 04:18:50 +00:00
IntelFrameworkPkg IntelFrameworkPkg: Fix a non ASCII char in LegacyBios.h. 2015-04-16 06:50:38 +00:00
IntelFspPkg IntelFspPkg: correct comments and rename a label 2015-06-03 04:55:58 +00:00
IntelFspWrapperPkg IntelFspWrapperPkg: Update PeiFspHobProcessLibSample to consume PI CapsulePpi 2015-05-08 07:44:30 +00:00
MdeModulePkg MdeModulePkg AcpiTableDxe: Non-Boolean comparisons should use a compare operator. 2015-06-19 12:11:01 +00:00
MdePkg MdePkg: Refine the cod logic of FileHandleLib. 2015-06-19 02:05:10 +00:00
NetworkPkg Remove Framework HII "class\subclass" in all VFR 2015-05-21 07:58:12 +00:00
Nt32Pkg Nt32Pkg: Use different FILE_GUID. 2015-05-18 05:30:01 +00:00
Omap35xxPkg */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
OptionRomPkg Add IPV6 support from UNDI 2015-04-30 02:57:10 +00:00
OvmfPkg OvmfPkg: PlatformPei: set SMBIOS entry point version dynamically 2015-06-22 17:11:05 +00:00
PcAtChipsetPkg PcAtChipsetPkg: Fix PCD expression build failure 2015-06-12 01:43:46 +00:00
PerformancePkg */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
SecurityPkg SecurityPkg: Add UEFI-2.5 PKCS7 Verification Protocol Support 2015-06-19 02:45:06 +00:00
ShellBinPkg ShellBinPkg: Ia32/X64 Shell binary update. 2015-06-12 11:20:53 +00:00
ShellPkg ShellPkg: update Console to clear screen when resetting 2015-06-15 20:21:06 +00:00
SourceLevelDebugPkg SourceLevelDebugPkg/DxeDebugAgent: Initialize Local APIC Timer 2015-06-10 01:45:18 +00:00
StdLib */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
StdLibPrivateInternalFiles */Contributions.txt: Update example email address 2015-02-03 17:29:14 +00:00
UefiCpuPkg UefiCpuPkg/CpuDxe: NumberOfData is not BOOLEAN type 2015-06-19 08:27:35 +00:00
UnixPkg UnixPkg: Remove UnixPkg files (It is replaced by EmulatorPkg) 2013-07-29 21:09:55 +00:00
Vlv2DeviceRefCodePkg Add definitions for Protected Region 1 register. 2015-06-11 02:16:41 +00:00
Vlv2TbltDevicePkg Sync the branch changes to trunk. 2015-06-11 02:50:20 +00:00
.gitignore EDK II: Add .gitignore 2014-10-14 16:08:15 +00:00
BuildNotes2.txt Update to new SVN URL in readme.txt 2013-06-08 05:26:39 +00:00
Edk2Setup.bat Edk2: Update Edk2Setup.bat 2015-06-16 07:23:45 +00:00
Maintainers.txt Maintainers.txt: Added Leif Lindholm as a co-maintainer 2015-05-29 16:23:52 +00:00
edksetup.bat Update edksetup.bat to support Microsoft Visual Studio 2013 when building the Nt32Pkg emulation platform (enabled using the --nt32 flag). 2014-10-30 17:09:25 +00:00
edksetup.sh edksetup.sh: Ensure that WORKSPACE points to the top of an edk2 checkout 2014-07-28 17:37:40 +00:00