summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.azurepipelines/templates/defaults.yml2
-rw-r--r--BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py3
-rw-r--r--DynamicTablesPkg/Library/Acpi/Common/AcpiSratLib/SratGenerator.c16
-rw-r--r--Maintainers.txt1
-rw-r--r--OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxe.c8
-rw-r--r--OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxeLib.inf5
-rw-r--r--OvmfPkg/README8
-rw-r--r--SecurityPkg/Library/SecureBootVariableProvisionLib/SecureBootVariableProvisionLib.c8
8 files changed, 27 insertions, 24 deletions
diff --git a/.azurepipelines/templates/defaults.yml b/.azurepipelines/templates/defaults.yml
index bc1cd058cc..e6d02cd0e5 100644
--- a/.azurepipelines/templates/defaults.yml
+++ b/.azurepipelines/templates/defaults.yml
@@ -9,4 +9,4 @@
variables:
default_python_version: "3.12"
- default_linux_image: "ghcr.io/tianocore/containers/fedora-37-test:a0dd931"
+ default_linux_image: "ghcr.io/tianocore/containers/fedora-40-test:c98ff99"
diff --git a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py
index 31d13b2ee7..9fb8a19c6d 100644
--- a/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py
+++ b/BaseTools/Plugin/HostBasedUnitTestRunner/HostBasedUnitTestRunner.py
@@ -156,7 +156,8 @@ class HostBasedUnitTestRunner(IUefiBuildPlugin):
return 1
# Coverage data for tested files only
- ret = RunCmd("lcov", f"--capture --directory {buildOutputBase}/ --output-file {buildOutputBase}/coverage-test.info --rc lcov_branch_coverage=1")
+ # `--ignore-errors mismatch` needed to make lcov v2.0+/gcov work.
+ ret = RunCmd("lcov", f"--capture --directory {buildOutputBase}/ --output-file {buildOutputBase}/coverage-test.info --rc lcov_branch_coverage=1 --ignore-errors mismatch")
if ret != 0:
logging.error("UnitTest Coverage: Failed to build coverage data for tested files.")
return 1
diff --git a/DynamicTablesPkg/Library/Acpi/Common/AcpiSratLib/SratGenerator.c b/DynamicTablesPkg/Library/Acpi/Common/AcpiSratLib/SratGenerator.c
index 20e1a4bfd3..fd83a92dda 100644
--- a/DynamicTablesPkg/Library/Acpi/Common/AcpiSratLib/SratGenerator.c
+++ b/DynamicTablesPkg/Library/Acpi/Common/AcpiSratLib/SratGenerator.c
@@ -80,9 +80,9 @@ GET_OBJECT_LIST (
/** Return the PCI Device information in BDF format
- PCI Bus Number - Max 256 busses (Bits 15:8 of BDF)
- PCI Device Number - Max 32 devices (Bits 7:3 of BDF)
- PCI Function Number - Max 8 functions (Bits 2:0 of BDF)
+ PCI Bus Number - Max 256 busses (Bits 7:0 of byte 0 of BDF)
+ PCI Device Number - Max 32 devices (Bits 7:3 of byte 1 of BDF)
+ PCI Function Number - Max 8 functions (Bits 2:0 of byte 1 BDF)
@param [in] DeviceHandlePci Pointer to the PCI Device Handle.
@@ -94,12 +94,12 @@ GetBdf (
IN CONST CM_ARCH_COMMON_DEVICE_HANDLE_PCI *DeviceHandlePci
)
{
- UINT16 Bdf;
+ UINT8 Bdf[2];
- Bdf = (UINT16)DeviceHandlePci->BusNumber << 8;
- Bdf |= (DeviceHandlePci->DeviceNumber & 0x1F) << 3;
- Bdf |= DeviceHandlePci->FunctionNumber & 0x7;
- return Bdf;
+ Bdf[0] = DeviceHandlePci->BusNumber;
+ Bdf[1] = (DeviceHandlePci->DeviceNumber & 0x1F) << 3;
+ Bdf[1] |= DeviceHandlePci->FunctionNumber & 0x7;
+ return *(UINT16 *)Bdf;
}
/** Add the Memory Affinity Structures in the SRAT Table.
diff --git a/Maintainers.txt b/Maintainers.txt
index ef1cb60f37..8c860283f4 100644
--- a/Maintainers.txt
+++ b/Maintainers.txt
@@ -206,6 +206,7 @@ FatPkg
F: FatPkg/
W: https://github.com/tianocore/tianocore.github.io/wiki/Edk2-fat-driver
M: Ray Ni <ray.ni@intel.com> [niruiyu]
+M: Oliver Smith-Denny <osde@microsoft.com> [os-d]
T: svn - https://svn.code.sf.net/p/edk2-fatdriver2/code/trunk/EnhancedFat
T: git - https://github.com/tianocore/edk2-FatPkg.git
diff --git a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxe.c b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxe.c
index 4250e633b5..c86f5914c7 100644
--- a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxe.c
+++ b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxe.c
@@ -56,6 +56,7 @@ QemuFwCfgInitialize (
{
UINT32 Signature;
UINT32 Revision;
+ UINT64 CcGuestAttr;
//
// Enable the access routines while probing to see if it is supported.
@@ -86,7 +87,10 @@ QemuFwCfgInitialize (
DEBUG ((DEBUG_INFO, "QemuFwCfg interface (DMA) is supported.\n"));
}
- if (mQemuFwCfgDmaSupported && (MemEncryptSevIsEnabled () || (MemEncryptTdxIsEnabled ()))) {
+ CcGuestAttr = PcdGet64 (PcdConfidentialComputingGuestAttr);
+ if (mQemuFwCfgDmaSupported && (CC_GUEST_IS_SEV (CcGuestAttr) ||
+ CC_GUEST_IS_TDX (CcGuestAttr)))
+ {
EFI_STATUS Status;
//
@@ -415,7 +419,7 @@ InternalQemuFwCfgDmaBytes (
// When SEV or TDX is enabled, map Buffer to DMA address before issuing the DMA
// request
//
- if (MemEncryptSevIsEnabled () || MemEncryptTdxIsEnabled ()) {
+ if (mIoMmuProtocol != NULL) {
VOID *AccessBuffer;
EFI_PHYSICAL_ADDRESS DataBufferAddress;
diff --git a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxeLib.inf b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxeLib.inf
index ce3eaa5ed8..11fbcdab98 100644
--- a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxeLib.inf
+++ b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgDxeLib.inf
@@ -42,11 +42,12 @@
DebugLib
IoLib
MemoryAllocationLib
- MemEncryptSevLib
- MemEncryptTdxLib
[Protocols]
gEdkiiIoMmuProtocolGuid ## SOMETIMES_CONSUMES
+[Pcd]
+ gEfiMdePkgTokenSpaceGuid.PcdConfidentialComputingGuestAttr
+
[Depex]
gEdkiiIoMmuProtocolGuid OR gIoMmuAbsentProtocolGuid
diff --git a/OvmfPkg/README b/OvmfPkg/README
index a5b447dae3..8c19b4c490 100644
--- a/OvmfPkg/README
+++ b/OvmfPkg/README
@@ -28,9 +28,11 @@ Current capabilities:
Pre-requisites:
* Build environment capable of build the edk2 MdeModulePkg.
* A properly configured ASL compiler:
- - Intel ASL compiler: Available from http://www.acpica.org
- - Microsoft ASL compiler: Available from http://www.acpi.info
-* NASM: http://www.nasm.us/
+ - Intel ASL compiler: Available from
+ https://www.intel.com/content/www/us/en/developer/topic-technology/open/acpica/download.html
+ - Microsoft ASL compiler: Available from
+ https://learn.microsoft.com/en-us/windows-hardware/drivers/bringup/microsoft-asl-compiler
+* NASM: https://www.nasm.us/
Update Conf/target.txt ACTIVE_PLATFORM for OVMF:
PEI arch DXE arch UEFI interfaces
diff --git a/SecurityPkg/Library/SecureBootVariableProvisionLib/SecureBootVariableProvisionLib.c b/SecurityPkg/Library/SecureBootVariableProvisionLib/SecureBootVariableProvisionLib.c
index d6046c85d2..7f9fdd22d7 100644
--- a/SecurityPkg/Library/SecureBootVariableProvisionLib/SecureBootVariableProvisionLib.c
+++ b/SecurityPkg/Library/SecureBootVariableProvisionLib/SecureBootVariableProvisionLib.c
@@ -46,7 +46,6 @@ SecureBootFetchData (
OUT EFI_SIGNATURE_LIST **SigListOut
)
{
- EFI_SIGNATURE_LIST *EfiSig;
EFI_STATUS Status;
VOID *Buffer;
VOID *RsaPubKey;
@@ -57,7 +56,6 @@ SecureBootFetchData (
SECURE_BOOT_CERTIFICATE_INFO *NewCertInfo;
KeyIndex = 0;
- EfiSig = NULL;
*SigListOut = NULL;
*SigListsSize = 0;
CertInfo = AllocatePool (sizeof (SECURE_BOOT_CERTIFICATE_INFO));
@@ -82,10 +80,6 @@ SecureBootFetchData (
RsaPubKey = NULL;
if (RsaGetPublicKeyFromX509 (Buffer, Size, &RsaPubKey) == FALSE) {
DEBUG ((DEBUG_ERROR, "%a: Invalid key format: %d\n", __func__, KeyIndex));
- if (EfiSig != NULL) {
- FreePool (EfiSig);
- }
-
FreePool (Buffer);
Status = EFI_INVALID_PARAMETER;
break;
@@ -162,7 +156,7 @@ EnrollFromDefault (
DataSize = 0;
Status = GetVariable2 (DefaultName, &gEfiGlobalVariableGuid, &Data, &DataSize);
if (EFI_ERROR (Status)) {
- DEBUG ((DEBUG_ERROR, "error: GetVariable (\"%s): %r\n", DefaultName, Status));
+ DEBUG ((DEBUG_ERROR, "Error: GetVariable (\"%s\"): %r\n", DefaultName, Status));
return Status;
}