Disclaimer & options for OCuLink eGPU adapters for reliable 64Gbps ePCIe 4.0 x4 connectivity, notably with Nvidia RTX 3000/4000 PCIe 4.0 GPUs is here
Page shortcut: https://egpu.io/DSDT | dsdt
[GUIDE] DSDT override eGPU error 12 fix (Windows only)
here ◄ Mac owners please work through this thread to solve error 12 before doing a DSDT override
here ◄ pre-compiled DSDT overrides - load or use as reference when making your own
| Introduction |
A Windows system's DSDT table root bridge definition (ACPI PNP0A08 or PNP0A03) is usually confined to a reserved 32-bit space (under 4GB) budgetted to be large enough to host the notebook's PCIe devices. A watermark TOLUD value is then set and locked in the system firmware. Windows OS honors the root bridge definition and will allocate PCIe devices within it. macOS ignores the root bridge constraints as too does Linux when booted with the parameter. Neither of those OS require a DSDT override and can allocate PCI BARs freely in the huge 64-bit address space.
When retrofitting a eGPU, an error 12 (This device cannot find enough free resources that it can use) can occur against an eGPU in Windows' device manager making it inoperable. This can indicate there is insufficient 32-bit addressing space available to host the eGPU. An eGPU requires a relatively large PCIe config space to allocate into. Decreasing TOLUD by reducing RAM to 2GB offers a somewhat impractical workaround. Rather, the definitive solution is below.
This three step solution removes Window's 32-bit PCIe allocation constraint in order to resolve the eGPU error 12:
Step 1. Create a dsdt-modified.aml DSDT file with a 36-bit root bridge
Step 2. Load your dsdt-modified.aml as registry override or in-memory substitution
Step 3. Confirm success with a 'Large Memory' area in Device Manager
macOS users: refer instead to Mikeal's post that covers these steps titled Windows 10 - Clover DSDT memory override [UEFI Windows on Macbooks only].
| Step 1. Create a dsdt-modified.aml DSDT file with a 36-bit root bridge |
OPTION 1: Use the Intel method
OPTION 2: Use the Microsoft method
| Step 2. Load your dsdt-modified.aml as a registry override or in-memory substitution |
OPTION 1: Load your dsdt-modified.aml as a registry override with Windows test signing mode enabled
OPTION 2: Avoid test signing mode - load your dsdt-modified.aml as an in memory DSDT substitution
| Step 3. Confirm success with a 'large memory' area in Device Manager |
| Success stories |
| FAQ |
1. I still have an error 12 with the 'large memory' area present. How can I fix it?
2. How do I disable the registry DSDT override?
| Appendix 1: Changing SSDT M64L value to increase 4G decoding 'large memory' |
Investigative work relevant to this topic for perusal by advanced users.
EliteBook 840 G5 default BIOS-enabled 'large memory' is 0x1C00000000-1FFFFFFFFF (112GB-128GB = 16GB)
As an exercise, I wanted to increase EliteBook 840 G5's 16GB 'large memory' to match my ZBook Studio G5's 256GB.
Problem: A DSDT override to increase 'large memory' as explained above will just reboot the system upon trying to load Windows.
Workaround: Based on study of DSDT's 'large memory' code, we modify the M64L memory variable to increase large memory to 256GB
Issue: The addresses below can change depending on BIOS settings or devices attached to ports on powerup so can change between reboots requiring vigilence to keep updated.
1. Extract Windows Binary Tool from https://acpica.org/downloads/binary-tools to c:\dsdt to dump and disassemble ACPI tables
cd \dsdt acpidump -b -z iasl -d *.dat
2. Inspect dsdt.dsl code where 'large memory' is created shows M64B and M64L set it's parameters:
If (M64L == Zero)
{
CreateQWordField (BUF0, \_SB.PCI0._Y0F._LEN, MSLN) // _LEN: Length
MSLN = Zero
}
Else
{
CreateQWordField (BUF0, \_SB.PCI0._Y0F._LEN, M2LN) // _LEN: Length
CreateQWordField (BUF0, \_SB.PCI0._Y0F._MIN, M2MN) // _MIN: Minimum Base Address
CreateQWordField (BUF0, \_SB.PCI0._Y0F._MAX, M2MX) // _MAX: Maximum Base Address
M2LN = M64L /* External reference */
M2MN = M64B /* External reference */
M2MX = ((M2MN + M2LN) - One)
}
We see M64B and M64L set base address and length.
3. Inspect ssdt5.dsl which contails M64B and M64L to identify which memory address those variables live at:
OperationRegion (SANV, SystemMemory, 0x87F17698, 0x01FE) ... M32B, 32, M32L, 32, ... M64B, 64 M64L, 64
Taking 0x87F17698 and counting the rightmost numbers of variables down to M64B and M64L and add them tells us:
- M64B is at (address) 0x87F17698 + (offset) 0xDF - 1 = 0x87F17777 (64-bit)
- M64L is at (address) 0x87F17698 + (offset) 0xE7 - 1 = 0x87F1777F (64-bit)
4. We can use RWEverything software to inspect these memory addresses, reading from right-to-left as is little-endian format, to confirm they are what we expect as shown.
M64B is 0x0000001C00000000 - best to keep this address as ensures audio device works and Win10 bootup time is not delayed
M64L is 0x0000000400000000 - 16GB. It needs to be 36GB or larger or 16GB reBAR will incur error code 12 and won't work
We'll set M64L to 0x4000000000 (256GB) by doing a single 0x40 byte write to 0x87F1777B.
5. Create a USB stick with UEFI shell startup.nsh to adjust M64B & M64L memory locations:
### leave M64B as default 0x1C to ensure audio works and no slowdown loading Windows, so can skip this # EFI shell memory write required: # mm 87F17773 1C -w 1 -MEM ### set M64L to be 0x4000000000 (256GB) # EFI shell memory write required: mm 87F1777B 40 -w 1 -MEM
64Gbps PCIe 4.0 x4 over 80Gbps Intel Thunderbolt 5 / USB4v2 ETA starting 2024 • eGPU Bandwidth Reference • eGPU Setup 1.35
2018 15" HP ZBook Studio G5 (Q P1000) [8th,6C,E] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 2.06kg triple-M.2 NVMe slot budget Workstation [info]
2018 14" HP EliteBook 840 G5 [8th,4C,U] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 1.48kg dual-M.2 slot budget UltraBook [info]
2015 15" Dell Precision 7510 (Q M1000M) [6th,4C,H] + GTX 1080 Ti @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 1803 // compares M.2 NVMe vs TB3 eGPU performance inc unoptimized H-CPU BIOS [build link]
GUIDE: an in-memory DSDT override using nando's DIY eGPU Setup 1.35 [MBR partitions only]
Windows 10 or 8 enumerates the DSDT table from the in-memory copy on every boot. The only way to change that is to either:
- perform a registry DSDT override with test signing enabled as described in the above post. Do not that some apps are either problematic or refuse to run with test signing enabled.
- perform an in-memory DSDT table substitution using nando's DIY eGPU Setup 1.35 pre-boot environment which eliminates the need to alter your registry or enable test signing as explained in this post.
| How to do a in-memory DSDT override using nando's DIY eGPU Setup 1.35? |
Pre-requisite requirements
|
How to load your dsdt-modified.aml via DIY eGPU Setup 1.35
1. Copy your dsdt-modified.aml file as dsdt.aml into Setup 1.35's v:\config directory
:: Mount the Setup 1.35 disk image as V: drive
c:\eGPU\eGPU-setup-mount
copy c:\dsdt\dsdt-modified.aml v:\config\dsdt.aml
2. Boot into nando's DIY eGPU Setup 1.35 -> automated startup via startup.bat (default).
It will automatically load this dsdt.aml file and present the Windows bootloader where you then select Windows. Check for the 'Large Memory' area to indicate a successful in-memory DSDT override like shown below in View->Devices By Connection. Then check for error 12 against your eGPU..
3. If there is an error 12. then force allocate the eGPU into the DSDT override's 36-bit PCI space:
- At Windows boot menu, select Setup 1.35
- Boot Setup 1.35 -> menu-based
- Select PCI compaction->Endpoint=56.25GB (36-bit)
- Select PCI compaction->Run compact. When prompted for the scope select eGPU, force 32-bit=none.
- Select startup.bat->Test Run.
- Select Chainloader->Test Run
- At Windows boot menu, select Windows.
64Gbps PCIe 4.0 x4 over 80Gbps Intel Thunderbolt 5 / USB4v2 ETA starting 2024 • eGPU Bandwidth Reference • eGPU Setup 1.35
2018 15" HP ZBook Studio G5 (Q P1000) [8th,6C,E] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 2.06kg triple-M.2 NVMe slot budget Workstation [info]
2018 14" HP EliteBook 840 G5 [8th,4C,U] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 1.48kg dual-M.2 slot budget UltraBook [info]
2015 15" Dell Precision 7510 (Q M1000M) [6th,4C,H] + GTX 1080 Ti @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 1803 // compares M.2 NVMe vs TB3 eGPU performance inc unoptimized H-CPU BIOS [build link]
Hello there!
no problem.
@nando4 I still have the same problem.. the eGpu insists to connect to other Pci root port, instead the one created under the large memory... What should I do?
I already unistall all the ports, the eGPU and the nvidia drivers, but it still not connect to the large memory..
Posted by: Yukikaze
Samuel, I think that Setup 1.35 should be able to fix that, because I believe you can force it to allocate the eGPU to the large/high memory area. I am not sure if there is a way to do it without Setup 1.35, but nando might know how to.
If the eGPU won't auto-allocate to the 'Large Memory' area, then revert to using eGPU Setup 1.35 software to hard allocate it in a pre-boot environment.
@everyone, the opening post is presented with an up-to-date DSDT override example using a 4th gen i-core Dell E6540. Unfortunately previous discussion was deleted along with the thread due to an offsite issue. Sincerest apologies there.
64Gbps PCIe 4.0 x4 over 80Gbps Intel Thunderbolt 5 / USB4v2 ETA starting 2024 • eGPU Bandwidth Reference • eGPU Setup 1.35
2018 15" HP ZBook Studio G5 (Q P1000) [8th,6C,E] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 2.06kg triple-M.2 NVMe slot budget Workstation [info]
2018 14" HP EliteBook 840 G5 [8th,4C,U] + RX 6700 XT @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 22H2 // compares M.2 NVMe vs TB3 & RX 6700 XT vs RTX 3070 eGPU, 1.48kg dual-M.2 slot budget UltraBook [info]
2015 15" Dell Precision 7510 (Q M1000M) [6th,4C,H] + GTX 1080 Ti @ 32Gbps-M.2x4 (ADT-Link R43SG) + Win10 1803 // compares M.2 NVMe vs TB3 eGPU performance inc unoptimized H-CPU BIOS [build link]
Thank you Nando4! I was able to solve Error 12 on the 2016 15" MacBook Pro following your DSDT Override instructions. No BSOD and Large Memory shows up in Device Manager.
LinkedIn | Youtube | Instagram
• external graphics card builds
• best laptops for external GPU
• eGPU enclosure buyer's guide
2017 21" iMac 4K (RP555) [7th,4C] + RX 6800 @ 32Gbps-TB3 (Netstor HL23T-Plus) + macOS 13 & Win11 22H2 [build link]
Thanks @nando4, that did the trick It wouldn't run without setup 1.35 and compacting. After 2 days of tinkering with DSDT. I needed to cut "If (COND) FPED" statement and paste to where OS's are listed. Also added QWORD. Now that I know what I'm doing it's 2 min.
For reference my config is HP 2570p (i5 3360m) - Win 10 x64 + Asus GTX 1060 6GB Turbo + EXP GDC 8 ExpressCard PCIe x2 + 8GB 1600Mhz. Witcher 3 on Ultra Avg 40-50FPS 1080p.
Many thanks
Sobi
To do: Create my signature with system and expected eGPU configuration information to give context to my posts. I have no builds.
.In my experience with my X230 and an Expresscard eGPU, the latest Lenovo X230 BIOS has no TOLUD problems. My HD7950 worked with it without any DSDT overrides or any Setup1.3x remapping of the eGPU. As far as I know, though, the X220 never got such a BIOS update.
Want to output 4K@60Hz out of an old system on the cheap? Read here.
Give your Node Pro a second Thunderbolt3 controller for reliable peripherals by re-using a TB3 dock (~50$).
"Always listen to experts. They'll tell you what can't be done, and why. Then do it."- Robert A. Heinlein, "Time Enough for Love."
2012 Mac Mini [3rd,4C,Q] + RX 480 @ 10Gbps-TB1 (Atto Thunderlink) + macOS 10.15.7 [build link]
GUIDE: an in-memory DSDT override using MaciASL+ Clover [UEFI Windows on Macbooks only]
here ◄ is Mikeal's updated second revision of this article
Update Feb-2019 >>Mac users are advised to use @goalque's automate-eGPU EFI instead of Clover to load your resultant DSDT override to avoid issue noted below in the BIG WARNING.
BIG WARNING by nando4 >> @Goalque has correctly identified that Clover loads a DSDT table in firmware volume and as such can brick a Macbook as this user found. If you proceed with using Clover to do a DSDT override the you do so at your own risk!! For risk-adverse users it is suggested to simply do a DSDT registry override and persevere with Windows' test signing mode until other solutions are found and presented.
Update: I still have an error 12 with the 'large memory' area present. How can I fix it?
Update: my internal soundcard doesn't work after applying this fix. What can I do?
2016 15" MacBook Pro (RP460) [6th,4C,H] + GTX 980 Ti @ 32Gbps-TB3 (Razer Core) + macOS 10.12 & Win10 [build link]
Just wanted to let you know how it went for me. I also have the late 2016 MacBook Pro 460. I tried Mikeal's method and it worked perfectly.
However, one issue/side effect. If I boot up with both the Razer Core and the USB-C to USB adapter, it would give me the Code 12 Error. Only when I disconnected it and boot up with the RC, does it work. (to be clear, adapter with an usb device attached such as mouse or keyboard)
After booting up, you can connect the adapter normally.
It's kinda weird or maybe something wrong with my system allocation but the adapter somehow screws up the reallocation.
Hope this helps.
To do: Create my signature with system and expected eGPU configuration information to give context to my posts. I have no builds.
.Hi Devaspark,
Are you using the USB adapter on the same side the core is connected? I stopped using that one because I was having issues and thought it was because they shared the thunderbolt controller. I switched to a cheap ankar USB-C to 4 port USB 3.1 adapter on the other side. Even if the core side 2nd adapter was working for me, it got bad performance(Oculus complained about tracking). I have no problem running all 3 sensors and the Rift off the other side though.
2016 15" MacBook Pro (RP460) [6th,4C,H] + GTX 980 Ti @ 32Gbps-TB3 (Razer Core) + macOS 10.12 & Win10 [build link]
Hi,Devaspark @ Devaspark
I have the Macbook pro 450 and I also use Mikeal's way to deal with the problem of the Code 12 Error. However, I have the issue of the DSDT compilation. Do you have this error: code 4096, unexpected PARSEOP_IF, expecting“,"or")"
If you have fixed the same errors, would you like to tell me how to do? Thank you.
To do: Create my signature with system and expected eGPU configuration information to give context to my posts. I have no builds.
.
