diff mbox

[edk2,11/17] OvmfPkg: PciHostBridgeLib: clear RootBus->DmaAbove4G

Message ID 1456532616-32475-12-git-send-email-lersek@redhat.com
State Superseded
Headers show

Commit Message

Laszlo Ersek Feb. 27, 2016, 12:23 a.m. UTC
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 <jordan.l.justen@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Marcel Apfelbaum <marcel@redhat.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Laszlo Ersek <lersek@redhat.com>

---
 OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c | 2 ++
 1 file changed, 2 insertions(+)

-- 
1.8.3.1


_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel
diff mbox

Patch

diff --git a/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c b/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c
index d7b01114c4aa..ba08c9b43b54 100644
--- a/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c
+++ b/OvmfPkg/Library/PciHostBridgeLib/PciHostBridgeLib.c
@@ -84,6 +84,8 @@  InitRootBridge (
                         EFI_PCI_ATTRIBUTE_VGA_PALETTE_IO_16;
   RootBus->Attributes = RootBus->Supports;
 
+  RootBus->DmaAbove4G = FALSE;
+
   return EFI_OUT_OF_RESOURCES;
 }