Skip to content

OvmfPkg/FdtPciHostBridgeLib: mark PCI host MMIO mappings as non-executable#12878

Open
apop5 wants to merge 1 commit into
tianocore:masterfrom
apop5:personal/apop5/ovmfmapxp
Open

OvmfPkg/FdtPciHostBridgeLib: mark PCI host MMIO mappings as non-executable#12878
apop5 wants to merge 1 commit into
tianocore:masterfrom
apop5:personal/apop5/ovmfmapxp

Conversation

@apop5

@apop5 apop5 commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Description

Add EFI_MEMORY_XP to all MapMmioMemory() calls in ProcessPciHost() for:

  • ECAM space
  • Translated I/O window
  • 32-bit MMIO window
  • 64-bit MMIO window

These regions are data/MMIO only and should not be executable. Marking them with EFI_MEMORY_XP improves memory protection hardening without changing intended runtime behavior.

  • Breaking change?
  • Impacts security?
  • Includes tests?

How This Was Tested

#12874

Attempting to set Nx asserted because the MMIO regions were not reported as Nx capiable.
After making the change, the system was able to boot.

Integration Instructions

No integration necessary.

…table

Add EFI_MEMORY_XP to all MapMmioMemory() calls in ProcessPciHost() for:
- ECAM space
- Translated I/O window
- 32-bit MMIO window
- 64-bit MMIO window

These regions are data/MMIO only and should not be executable. Marking them
with EFI_MEMORY_XP improves memory protection hardening without changing
intended runtime behavior.

Signed-off-by: Aaron Pop <aaronpop@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant