From c789d61dcb6b1990133a947351f67751cf0c4e31 Mon Sep 17 00:00:00 2001 From: Laszlo Ersek Date: Mon, 25 Jan 2016 23:50:14 +0100 Subject: [PATCH] OvmfPkg: PciHostBridgeLib: clear RootBus->DmaAbove4G When this BOOLEAN member is FALSE, and the caller tries to set up a DMA transfer between a PCI device and a host buffer not entirely under 4GB, then "MdeModulePkg/Bus/Pci/PciHostBridgeDxe" sets up a bounce buffer under 4GB, in the implementation of EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL.Map(). Since that's exactly what RootBridgeIoMap() does in "OvmfPkg/PciHostBridgeDxe/PciRootBridgeIo.c", stick with it in this conversion. Cc: Jordan Justen Cc: Ruiyu Ni Cc: Marcel Apfelbaum Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Laszlo Ersek Reviewed-by: Ruiyu Ni Reviewed-by: Jordan Justen --- OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c b/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c index db260291b8..f1cefe4169 100644 --- a/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c +++ b/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c @@ -82,6 +82,8 @@ InitRootBridge ( EFI_PCI_ATTRIBUTE_VGA_PALETTE_IO_16; RootBus->Attributes = RootBus->Supports; + RootBus->DmaAbove4G = FALSE; + return EFI_OUT_OF_RESOURCES; } -- 2.39.2