[Guide] How to make Z370 chipset MBs compatible with 128GB RAM

@bios_guy May Mac OS need Intel ME not been disabled. But ME on 22nm PCH now won’t let us use 128G RAM.

@rootuser123 Use UEFITool to search that hex pattern , and it will report you the offset. And about the HAP bit , at offset 0x102h of SPI dump , put this value into calculator and do "or" with 0x1 ,then write this value back to 0x102h.

@dsanke , @Lost_N_BIOS

I’m borrowing a X99 Motherboard to do some testing so I’m hoping to be able to test some modified BIOS ROMs to see if I can access 32GB DDR4 memory per memory slot. I won’t have this motherboard for too long so if it can be done asap before I have to return it soon possibly in a few days and a week max.

Has anyone ever attempted to modify an X99 BIOS to support 32GB DDR4 memory modules?

The motherboard can support 128GB in total with 8 slots but when booting the motherboard I get Asrock Debug Error Code 55 which means it is a memory issue.

I only need BIOS v3.10 modified as v3.40 removes all underclocking options for my CPU so I prefer v3.10 only. No need to add any CPU Microcodes as it contains everything.

BIOS ROM file for modification:
https://download.asrock.com/BIOS/2011/X9…er(3.10)ROM.zip

I would like to minimize the amount of changes required to just read 32GB DDR4 memory modules. So trying to keep the ME and anything else untouched if that’s possible.


UEFI Tool search I found these matching:
Hex pattern “C786…000000…00” found as “C786B000000000040000” in Compressed section/PE32 image section at header-offset E99Dh
Hex pattern “C786…000000…00” found as “C786B0000000000C0000” in Compressed section/PE32 image section at header-offset E9ADh
Hex pattern “C786…000000…00” found as “C7864803000000004000” in UncoreInitPeim/PE32 image section at header-offset 7FB78h
Hex pattern “C786…000000…00” found as “C7864803000000004000” in UncoreInitPeim/PE32 image section at header-offset 7FD05h
Hex pattern “C786…000000…00” found as “C7864C03000000400000” in UncoreInitPeim/PE32 image section at header-offset 8031Eh
Hex pattern “C786…000000…00” found as “C7864803000000400000” in UncoreInitPeim/PE32 image section at header-offset 8032Ah


Can dsanke, Lost_N_BIOS figure how to modify the BIOS for testing and upload it?

2nd step if this works is seeing if there is an inherent 128GB maximum ram limit and if so can this be changed to 256GB?

If this works somehow that would challenge a Z170-Z370 maximum memory capacity.

Thanks in advance.

XPLives

Hallo gentlemen! Greeting from Prague, Czech Republic!

Well, I recently bought an ASUS Maximus IX Apex. Its Z270 chipset board with only 2 RAM slots and as usual, officially “limited” by 16GB module per slot. And since I’d like to have 64GB of RAM, but don’t want to risk that it would not work with 32GB modules, I would like to edit the bios to “enable” the 32GB modules. I already am familiar with UEFI tool and HxD Editor. According to well precisely written guides here on win-raid I successfully edited couple of antient P45, P43, P31 boards to run old 4-core Xeon processors. Man, I had so much fun those times!

But here, I am not sure and I don’t want to mess up the board. Though it has 2 bios chips and the recovery would probably not be a problem, I would rather do exact and precise job and evade any disaster recovery, you know?? And I also don’t want to buy a quite expensive set of RAM that couldn’t use then.
So, I have couple of questions!

1. Since the board will probably not have the latest bios flashed, shall I first flash the latest bios? Then dump it, edit it and flash again?
2. Or should I just download the latest bios .CAP file, edit it and ten flash it as a normal bios update?

3. I downloaded and opened the .CAP file in UEFI tool, searched for the GUID mentioned in the first post on the first page {A8499E65-A6F6-48B0-96DB-45C266030D83} and extracted with “Extract as is” the SiInitPreMem block as a BIN file from there - 380kB. Then I opened the SiInitPreMem.BIN in UEFI tool separately and searched for the “C786…000000…00” with these multiple results:
Hex pattern “C786…000000…00” found as “C7860C54000000000000” in /UEFI image at header-offset 1197h
Hex pattern “C786…000000…00” found as “C7868403000000000000” in /UEFI image at header-offset 7573h
Hex pattern “C786…000000…00” found as “C7866725000000200000” in /UEFI image at header-offset 1E2AEh
Hex pattern “C786…000000…00” found as “C7866725000000800000” in /UEFI image at header-offset 1E2BAh

Now I don’t know which one to edit and what to put in. Can you please, advise? Or does the last pattern mean that this bios file is ready to work with 32GB RAM modules, so 64GB kit will work?

Thank you, anybody, for any advise!

Chat ya boys, soon!

Regards

Couple hours later…

Hey, I think, you can forget about my questions now… I just discovered the CoffeTime tool v0.92 with a simple and easy GUI that does all the necessary modifications for me with just few clicks! This tool is freakin amazing!!! It modds the .CAP file directly which is cool. And along with the 128GB RAM tweak, I might be also able to use all the top 6th-9th Gen. Core i7 and i9 CPUs, since most of the microcodes fit (from size point of view) and that is AWSOME!!! So I immediately ordered Core i7-9700KF that only needs a little HW mod on the pins side of the substrate and thats it!! I let know during next week, how this whole HELL OF A HACK ended up… wish me luck!

Cheers!


[quote="dsanke, post:25, topic:33716"] @Lost_N_BIOS
I dont see anyone using R4E and 128G and found problem. I think there is no need to modify. I think all X79 should support 128GB initially. [/quote]

@dsanke @Lost_N_BIOS I am having issues with 128GB RAM on Rampage IV Extreme X79 (not black edition, normal one) using BIOS from t5492f16-REQUEST-Enable-Bifurcation-settings-on-Asus-Rampage-IV-Extreme-2.html#msg140904 (cannot link, new member). I read all of this thread and the thread for the bifurcation/NVMe BIOS.

I am using Xeon E5-1680 v2 processor, which from Intel spec support up to 256GB RAM and also registered ECC RAM. On another forum techpowerup x79-and-or-rampage-iv-ocing-thread-for-those-of-us-still-left.225209 page 36 I found this:



The modules I am trying to use are 16GB 2Rx4 PC3L 12800R (1600MHz) * 8 = 128GB. Based upon the quote above, I am suspecting Rampage IV Extreme bios is missing some code for 8GB per rank chips? I do not have a lot of expertise in this topic, so perhaps I am describing it wrong. I tried with a single DIMM placed in the correct slot for single DIMM operation per motherboard manual, but it refuses to POST with code 53, which means unsupported memory or similar.

I would really love to keep using this platform with a sweet memory upgrade, would really appreciate any help I can get.

Thanks in advance!

@dsanke I have an Asus ROG STRIX Z270-E Gaming motherboard and I am using your modded BIOS to convert it from Z270 to Z370. I unlocked the 128GB option in CoffeeTime, flashed and tested a couple of times. At maximum of 3 DIMMs and 96GB, it works flawlessly. However, with 4 DIMMs and 128GB, it boots normally with luck once per day, and the other tries it hangs on either a boot loop (CPU LED + DRAM LED) or stucks on DRAM LED. Do you know any BIOS settings that could help fixing it? I’m using BIOS version 2401 from 02/17/2020. If you have an updated version, please let me know. Thank you very much!

I have Z370-E Gaming MB. Bios Version 3004 original.
Original sequence of bytes is absent in this version.
But I see in SiInitPreMem that possible combinations are: (Original code BIOS)

0x1000
0x2000
0x8000
0x10000

can it be that 0x10000 is a 128GB value? or i have to change 0x8000 to 0x0001 ?
Can i recover my BIOS witouh reflashing with a programmer board if i will do mistake while patching?

Thanks!

Hello everyone, I appreciate all of the comments, I was able to get this working with the Z370P D3 (rev 1.0). gigabyte DOT COM /Motherboard/Z370P-D3-rev-10/

Here is the modified firmware (version F15) if you have my same motherboard and want to use it. drive
DOT google.com/file/d/1ZeM3F_q8DUd6LocT44VBjR1KwPzbzCWq/view?usp=sharing

I actually did not need to modify the firmware past removing the HAP bit and MeRecoveryDxe, as it already supported 128GB in the firmware.

A modified, more clarified guide.
1. Download UEFITool. You might need an older version to be able to do modifications.
2. Then, open the BIOS firmware file, either one extracted or available from the manufacture’s website.
3. Extract SiInitPreMem,GUID:A8499E65-A6F6-48B0-96DB-45C266030D83.
4. Search “C7 86 … … 00 00 00 … … 00”,"…" is any HEX value. You might have to bring this into Notepad++ and just search with REGEX like I had to. You can just search with

1
 
C7/h+86/h+../h+../h+00/h+00/h+00/h+../h+../h+00
 

5. From the second .. .. Replace "800000" with "000100", if it is already 80 00 00 then you are already setup for everything.
6. Make sure the Chipset->System Agent (SA) Configuration->Above 4GB MMIO BIOS assignment is set to Disabled. Some motherboard do not need this adjustment.
7. If you are on Gigabyte, you cannot set the HAP bit without a boot loop occurring. Therefor, you will need to first remove: MeRecoveryDxe GUID: F1FCD66F-8966-441E-909C-77F211AB9C3E, if it exists, in UEFITool. Right click it. Hit remove. Then go to File > Save to run the action and create a new BIOS firmware.
8. Then, you will need github dot COM /corna/me_cleaner here to open the firmware and remove the HAP bit. Download it, then run:
1
 
py me_cleaner.py yourfirmwarefile.xyz --s
 
and it will remove the HAP bit (soft disable) from firmware.
9. Then, flash it with your BIOS flasher. Make sure it is intact.
10. You are done!

I have 4 32GB Corsair modules, it even works with XMP.

It works! on an ASRock Z270 Extreme4 and with a KabyLake CPU!

I planned to replace the 2x8GB DIMMs with 2x32GB DIMMs, but was met with the MRC bug (cannot train > 16GB DIMMs. ASRock/Intel say the platform is “limited to 16GB per DIMM”)

So i used the trick reported here (2x8GB on the primary channel, 2x32GB on the secondary) and it works fine! (i would say the Intel code is bugged/outdated, not limited).
I actually discovered this independently by trying various RAM configurations, and then found this topic here.

This however meant that i couldn’t see more than 64GB of RAM, and i had to use 3333mhz (4 sticks) instead of 3600mhz (2 sticks) - because the board simply cannoy manage all 4 at 3600mhz.

I tried to patch this 64GB case as reported here but, in my case, UEFITool / me_cleaner were not producing a working image.
I assumed it was a hardware limitation, but i was wrong.
Later on, while porting coreboot to the board, i decided to try it again and it was working (on coreboot).

I also noticed strange behaviours with me_cleaner (suspend not working, reboot causes a hard shutdown, power button not responsive), which i fixed by using ifdtool instead.
Therefore, i decided to re-do it on AMI Aptio.

This time, I extracted SiInitPreMem, hex edited it, then replicated the edits on the full image (still with hex editor, no UEFITool).
I then i used coreboot’s ifdtool instead of me_cleaner to set the HAP flag:

ifdtool -p sklkbl -M 1 patched_image.bin

The results is that i now have 80GB of usable RAM :slight_smile:

Apparently Intel wants you to buy the newest chipsets to have these fixes, instead of backporting them to Z270 (which is lame).
Fixing the > 16GB DIMMs without the extra RAM trick would be nice, but it’s probably not as easy as the RAM limit patch.

Thanks for the useful information in this thread. I hope this can help other people :+1:

1 Like

Hi everyone. I’m trying to apply this mod to a Gigabyte B365M DS3H (rev. 1.0). My initial guess was that it should work out of the box as CoffeTime shows on green the 128gb patch with the original bios file: B365M DS3H (rev. 1.0) F7 Bios So recently I bought a kit of 2x32gb Kingston Fury 2666, and I tried to pair them with my existing 2x16gb 2400 to get a total of 96GB, but system wont boot, not even bios. If I use only the 64gb kit, it works perfectly, so the 32gb modules are compatible, also it boots with 1x32 and 1x16, but whenever I try to populate all of them it gets into a boot loop. The plan was to get all 4x32 populated to reach 128gb, but of course now I hesitate is gonna work without modding. My question is, could be possible that it will work if all modules are the same and the problem is that I have different size and speeds? I’m not expert on bios modding and I use my pc to work, so I really dont want to brick the MB, I tried to change the specified values on SiInitPreMem to patch it manually, but there is no “800000”or “000100” after C786. Maybe some of you could take a look at the bios file and give me a hint? Thank you!

@FLGraphics
Remove ME Recovery DXE and set ME disabled, then try again with more than 64GB RAM.

Hi all,

I’ve been following the guide here and @Kemerd graciously allowed me to grab a copy of their firmware for my Z370P D3 board however when attempting to flash using the Gigabyte flash tool, I was getting an error that the BIOS was invalid.

Reading his instructions, I then went and tried to create a firmware myself and whilst disabling the HAP bit doesn’t seem using ME Cleaner doesn’t seem to make much difference (ie if I only do this step, the image is valid and applies succesffuly but the machine won’t post with 128Gb of RAM in it), removing ME Recovery DXE from the image seems to be the dealbreaker as far as applying the image is concerned and it looks like this step is 100% required.

Now I might be missing something really obvious here, but how should I be applying the firmware image or modifying it to prevent the flash tool from generating an error? Do I need to be using an older flash tool version or should I be using UEFIReplace or something?

Sorry for the numpty questions.

Thanks

image

@dsanke

Btw you can fix the issue with 4G decoding, just patch this (AddMemorySpace) to use 192GB as base instead (or better use value of TOUUD).

Also can increase the size if you want more BAR space for PCI devices such as for running 2x 3090 (32GB each) with rebar. Or using server/workstation GPUs which comes with even more VRAM

1 Like

Hello, I am trying to modify this ASRock Z370/OEM bios L4.01 to enable 128GB of ram, but to start, I cannot even get 64gb with 2 x 32gb sticks!

If I install one stick of 32gb then it will POST, however, any configuration of more than one stick of 32gb and it never POST.

I can mix lower capacity ram with a single 32gb stick, for a total of 48gb of ram, for example.

At the moment I have a total of 64gb in all four slots with 4 x 16gb.

Can anyone help me with this?

https://content.ibuypower.com/Download/Drivers/ASRock-iBUYPOWER-Motherboard-BIOS/Z370%20Pro%204-IBR/Z37PIBR_4.01.zip

I have tried to follow the guide for the 128gb limit, but could not find a match…

I extracted the SiInitPreMem,GUID:A8499E65-A6F6-48B0-96DB-45C266030D83 and searched for matching hex values, this is what I find:

Pattern found at offset: 4139, bytes: c7860c54000000000000
Pattern found at offset: 44011, bytes: c7868403000000000000
Pattern found at offset: 55625, bytes: c786440c000010025476
Pattern found at offset: 77590, bytes: c786c00d0000002b0132
Pattern found at offset: 77600, bytes: c786c40d00000c003b00
Pattern found at offset: 77610, bytes: c786c80d0000b402f800
Pattern found at offset: 77620, bytes: c786cc0d0000880d2834
Pattern found at offset: 77630, bytes: c786d00d000000923609
Pattern found at offset: 77640, bytes: c786d40d00006cc2c800
Pattern found at offset: 77650, bytes: c786dc0d0000006a0100
Pattern found at offset: 88139, bytes: c786bc0100000000d0fe
Pattern found at offset: 88752, bytes: c78660010000b6030000
Pattern found at offset: 88802, bytes: c7866001000052030000
Pattern found at offset: 95392, bytes: c7867c25000000200000
Pattern found at offset: 95404, bytes: c7867c25000000000100
Pattern found at offset: 96676, bytes: c786f324000001000000
Pattern found at offset: 120653, bytes: c786f324000001000000
Pattern found at offset: 162366, bytes: c786f324000001000000
Pattern found at offset: 163574, bytes: c786f324000001000000
Pattern found at offset: 177069, bytes: c7867425000003000000
Pattern found at offset: 284808, bytes: c786f94a000001000000

Would really appreciate any help of advice here. Cheers!

I guess the MB is the same as Z370 Pro4, so I suggest you flash to Z370 Pro4 latest beta BIOS.
Your problem seems like the BIOS do not have correct timing configuration for single 32GB module.

The standard asrock pro4 bios is not recognised but I did find another bios on this page: ASRock > Support

I was able to upgrade from L4.01 to L4.02

I have made some progress. Installing a single stick, enabling XMP in bios, shutting down and installing another stick resulted in 64gb detected. I am able to add a third stick for 96gb, but not a fourth.

With one stick, xmp sets the speed to 3200mhz but with two and three it sets it to 2133mhz

Does that give any clue?

I have also confirmed the C786XXXX000000000100 string in both the L4.01 and L4.02 bios files.

Hello mate, Hope you are having an amazing day like you. I have an alienware x299 motherboard with intel i9 7980xe. It only allow 64gb. and has 4 slots. so max 16 per slot

but I have 2x32gb 3600mhz

This is my bios

It would be insanly amazing if you can help me achieve it

biosreg.rar (4.8 MB)

@superuchiha2001
this thread is for the maximum ram size for all slot, not for single slot.
every skylake motherboard should allow 32 gb single dimm run without bios mod.
try lower freq for dimm.

I used the two sticks now but its not working. Not even letting them run at lower speeds

Its beeping