ReBarUEFI: A firmware mod that unlocks Resizable BAR on unsupported motherboards
ReBarUEFI is an open-source UEFI DXE driver that forces Resizable BAR support onto older systems whose firmware never officially shipped with it. The feature lets a CPU address a GPU’s entire video memory in one contiguous block rather than through small 256MB windows, yielding measurable gains — the author reports up to a 12% FPS bump on an Ivy Bridge i5-3470 paired with an RX 580 — and it’s effectively mandatory for Intel Arc GPUs to perform well. The module inserts itself into the firmware’s DXE volume and hooks the PciHostBridgeResourceAllocationProtocol’s PreprocessController function, reprogramming the BAR size (stored in an NVRAM variable set by the companion ReBarState tool) before PCI enumeration allocates the resources.
Making this work on hardware that predates the feature is a firmware-hacking exercise. The project ships a set of UEFIPatch patches, reverse-engineered with Ghidra, to lift artificial BAR size limits, stop 64-bit BARs from being downgraded to 32-bit, and expand usable MMIO space to the full physical address range across Sandy Bridge through Coffee Lake platforms. Additional patches address platform-specific breakage, including USB 3 ports failing under 4G Decoding and NVRAM whitelists that blocked writes. Prerequisites include enabling Above 4G Decoding (sometimes a hidden option), disabling CSM, and on some boards patching the DSDT.
The practical catch is that modifying and reflashing firmware carries real risk, and there’s no way to enable this on Windows without a BIOS mod — though Linux users with 4G Decoding on can often get the kernel to resize BARs automatically via pci=realloc. Notably, most firmware will run the unsigned, patched module even with Secure Boot enabled, which is convenient for users but also a reminder of how loosely many OEM implementations actually enforce that trust boundary. The work builds heavily on EDK2, the AMD amdgpu driver, and community testing across a range of X79/X99 boards.
Read the full article
Continue reading at Hacker News →This is an AI-generated summary. Read the original for the full story.