Skip to content

Enabling hidden 4G decoding

Curi0 edited this page Sep 12, 2023 · 29 revisions

Some motherboards do support 4G decoding even though it's not visible in the BIOS setup. Here you can find out how to enable the hidden option using UEFITool, Universal IFR Extractor and grub-mod-setup_var. This guide is only for Windows currently unless you can figure out how to use IFR Extractor on Linux. You can also use this guide to enable other hidden BIOS settings, just search for the setting you're looking for instead.

Before enabling 4G decoding make sure that CSM is off otherwise you might face issues such as black screen or unable to enter BIOS. When CSM is off boot logo will be at full monitor resolution with no stretching/blurring

  1. Open your BIOS in UEFITool and search for 4G Decod (NOT Decode) with Unicode enabled. If it doesn't find anything try searching for Above 4G or MMIO.

image

  1. Extract body of the section that search finds.

image

  1. Open IRFExtractor.exe that you downloaded from IRFExtractor_0.3.6_win.zip (i didn't make the typo). Select the file that you extracted it should show Protocol: UEFI and click Extract to save the output file.

image

  1. Open the file that you saved and search 4G Decod or Above 4G in it. The value after VarStoreInfo (VarOffset/VarName): on the 4G Decoding entry is the offset which stores the setting. You may find multiple entries with the same VarOffset.

  2. Copy modGRUBShell.efi from grub-mod-setup_var to EFI/Boot/bootx64.efi on a USB drive that's bootable (such as one with a Linux or Windows installer on it). Make sure that Secure Boot is disabled and then boot the drive. Note that you can re-enable Secure Boot once finished doing this guide if you need it.

  3. Run setup_var (offset) replacing (offset) with what you got in step 4. If it already shows 0x1 despite being not enabled that's not an issue as you can easily solve it by doing setup_var (offset) 0x0, rebooting, doing setup_var (offset) 0x1 and again rebooting. If the variable is 0x0 you can simply enable it doing setup_var (offset) 0x1 and rebooting. If you get an error about GUID mismatch it is safe to ignore. If the above doesn't work you can retry using setup_var_3 instead of setup_var.

  4. 4G decoding should work now. Re-enable Secure Boot if you need it.

Alternative method by enabling hidden menu, not recommended
An alternative method is by using AMIBCP (Aptio IV, typically from before ~2016) or UEFI-Editor (Aptio V, AMIBCP will give error on these) to enable access to the hidden menu. This method is not recommended as it requires modifications to the BIOS file and can result in boot failure if done incorrectly. This method also won't work on any non-Aptio BIOS such as prebuilts.

AMIBCP

  • Locate the hidden menu with 4G Decoding.

image

  • Change Access to USER.

image

  • File -> Save to save the modified BIOS.

UEFI-Editor

TODO, usually these will already have the 4G decoding option exposed.

See [TOOL] UEFI Editor for more information.

Clone this wiki locally