XPS 7590 1.6.0 UEFI: unlock undervolting and remove CFG lock
EDIT: Much simpler solution - Go into the BIOS settings and click 'Restore settings' and then 'Factory Restore'. Reboot and undervolting is re-enabled.
Disclaimer 1: u/likestomoveblocks has been instrumental to finding this fix and credit should belong to them.
Disclaimer 2: I am not responsible for any damage that might ensue from trying this yourself. I have tried this on my laptop and it has worked perfectly, however results might not be the same for you. If you are NOT comfortable with modding your UEFI/BIOS, I would stop reading here.
Disclaimer 3: this is my first post - apologies for any shortcomings
Background to solution: As of BIOS update 1.6.0, Dell locked out users from undervolting their 7590. As this laptop has a tight thermal profile as it is, removing this feature leads to significant throttling. See more here. The CFG bit has always been locked, leading hackintosh users (such as myself) to use power management workarounds.
Since these problems all stem from the BIOS/BIOS upgrade, the 1.6.0 update was extracted using this Python script, and UEFITool was used to search for "CFG Lock" and "Overclocking Lock". The corresponding PE32 file was extracted, See below:
0x4E1A0 Form: View/Configure CPU Lock Options, FormId: 0x273D {01 86 3D 27 B7 01}
0x4E1A6 One Of: CFG Lock, VarStoreInfo (VarOffset/VarName): 0x6ED, VarStore: 0x1, QuestionId: 0x381, Size: 1, Min: 0x0, Max 0x1, Step: 0x0 {05 91 B0 03 B1 03 81 03 01 00 ED 06 10 10 00 01 00}
0x4E1B7 One Of Option: Disabled, Value (8 bit): 0x0 {09 07 04 00 00 00 00}
0x4E1BE One Of Option: Enabled, Value (8 bit): 0x1 (default) {09 07 03 00 30 00 01}
0x4E1C5 End One Of {29 02}
0x4E1C7 One Of: Overclocking Lock, VarStoreInfo (VarOffset/VarName): 0x789, VarStore: 0x1, QuestionId: 0x382, Size: 1, Min: 0x0, Max 0x1, Step: 0x0 {05 91 AC 03 AD 03 82 03 01 00 89 07 10 10 00 01 00}
0x4E1D8 One Of Option: Disabled, Value (8 bit): 0x0 {09 07 04 00 00 00 00}
0x4E1DF One Of Option: Enabled, Value (8 bit): 0x1 (default) {09 07 03 00 30 00 01}
0x4E1E6 End One Of {29 02}
As we can see, the UEFI variables encoding for Overclocking Lock and CFG Lock are 0x789 and 0x6ED respectively. These are both set to 0x1 (locked) by default in 1.6.0. The other option, 0x0, encodes for unlocked.
The solution:
- Format a USB drive to FAT32 on a GUID partition map.
- Make a folder called EFI in the root of the USB
- Inside this, make a folder called BOOT
- Download this file and place it inside BOOT
- Rename this file to bootx64.efi
- Boot into the USB drive (spam F12 at the BIOS prompt and select your USB drive)
- Once this has loaded, enter
setup_var_3 0x789 0x00to disable overclocking lock - Repeat this with
setup_var_3 0x6ED 0x00to disable CFG lock - Enter
rebootto exit and restart your computer - You will now find overclocking to re-enabled and CFG lock removed!
Posted Apr 12, 2020, 11:29 AM UTC · edited
What is "cfg lock"? You also dont need all this, you can just load bios factory settings, and undervolt works again. Does this give options to more things too, like overclocking the cpu?
https://www.reddit.com/r/Dell/comments/fxfcos/how_to_get_undervolting_back_after_g3/
Dell mostly messed up and forgot to set the lock for the bios factory load config.
Ah I had no idea, sounds like a much safer and simpler fix. I'll update the post to reflect that - thanks for the info!
Although that is by far a much better fix, in the future it would be very easy for Dell to patch this, maybe this guide may come in handy for the next UEFI update release.
CFG lock has no real utility unless you're a hackintosh user. Its a portion of the UEFI that is written to by the OS for CPU power management. Basically allows for greater OS dictated C-state control.
Its locked by default in all xps 7590 UEFI versions and the majority of other motherboards as Window's doesn't utilise it.
macOS utilises an unlocked CFG to control CPU power management, and when locked out it fails to boot without patching. By doing this, i'm able to get native CPU power management (like a real mac), which leads to greater responsiveness and power saving simultaneously, and I don't require any work around patches to boot.
Hey I'm also hackintoshing on the 7590, do you have any kind of estimate as to how unlocking your CFG improved your battery life?
Second half of your question - upon looking into the UEFI firmware image there's a whole hidden 'Advanced' menu containing 'Overclocking Performance Menu', 'CPU Configuration', and 'Thermal Configuration' to name a few. I'm looking into how to enable access to it currently
Is there maybe even a way to unhide everything in the bios and you can just have a more advanced bios GUI? Maybe there are "hide" flags for stuff?
Many people don't have the option to reset to factory settings
I wonder why. Seems like there are two versions of the same laptop out not just mainboard version or anything but also some have this option missing... not sure why.