Repository navigation
Releases: Cyridd/cmpunlocker
Release list
CMP 40HX Windows Unlock v2.0.2
v2.0.2: Gen2 PL0 parity with PZH1gdmu's v3.2.0
This release brings the Windows Gen2 register sequence in line with v3.2.0 release by PZH1gdmu.
It fixes a BSOD during Gen2 bring-up that some users hit with earlier builds (#9).
Background
PZH1gdmu and their repository became unavailable a few days before this release.
The reason is unknown. The v3.2.0 release was obtained from a copy downloaded earlier,
and it is no longer possible to fetch it from the original location.
The PL0 register table used here was recovered by disassembling
main.gen2Main / main.gen2WritePL0 from that v3.2.0 binary, not taken from
published source. The recovered table, the read-modify-write masks, and the
reconstructed PnP fallback sequence are documented in
windows/tools/inst40hx/gen2_pl0_v2.go. If you still have the original v3.2.0
build, please compare its hash against the one above.
Fixed
- BSOD during Gen2 bring-up (#9).
Changed
- PL0 sequence matches 3.2.0.
- New
PL_LINK_RATE(0x8C1C0) write. LINK_CONFIG_0andPL_LINK_RATEare now read-modify-write with a masked
readback check. PreviouslyLINK_CONFIG_0was written as the constant
0x80085800.
- New
- BAR0 / BOOT_0 validation on every PL0 write, including after Link Disable
and PnP recovery, not only once at startup. If the check fails, nothing is
written and Gen2 aborts safely. Gen2AutoHardnow defaults to0(off), as in 3.2.0. The GUI policy
checkbox follows the new default. A manual-hardrun is unaffected.- New PnP fallback between Stage 1 and Stage 2. If retrain fails, the 40HX
is disabled/enabled via PnP, the driver is reloaded, and PL0, TLS and retrain
are redone before Stage 2 is considered. Turn it off withGen2PnpFallback=0.
This sequence is reconstructed from the order of calls in 3.2.0, not a
byte-for-byte copy.
Added
-gen2dry: read-only mode. Prints the current PL0 and link registers and
which bits the fork scheme, the 3.2.0 scheme and the EFI-RMW scheme would
flip. Writes nothing. Useful for diagnosing before a real run.- Log fsync every 100 ms, so the last lines before a BSOD reach the disk.
- New optional registry switches under
HKLM\SOFTWARE\40HXUnlock:
Gen2WriteLtssmOvr,Gen2WritePlLinkRate,Gen2Pl0EfiRmw
(the last one is for A/B testing only).
Upgrade notes
- If you relied on the automatic Link Disable fallback, set
Gen2AutoHard=1. If the value was already set explicitly, it is kept.
The key is deleted on uninstall, so a reinstall returns to the new default. - With the PnP fallback on, a logon where Stage 1 fails will briefly
disable/enable the display adapter. - Replace your existing
40HXInstaller.exewith the new build. The previous
binary does not contain these changes.
Credits
- @PZH1gdmu
- @Phil-Libra - for reporting the issue (#9) and testing
CMP 40HX Windows Unlock v2.0.1
v2.0.1
Secure Boot coexistence, a runtime boot-manager handoff, ReBAR visibility/control, machine-readable diagnostics, and a new CI pipeline that keeps the shipped EFI provably reproducible.
Highlights
- Secure Boot can now stay on. Sign the unlock EFI with your own key and the firmware will run it — see the new Secure Boot section.
- No more separate "Limine" build. The single shipped
40HXUNLK.EFInow honors a runtime--return-to-bootloaderload option instead of requiring a specialNO_AUTO_CHAINLOADbuild. - ReBAR is now visible and controllable, not just applied silently —
40HXCheck.exereports it GPU-Z style, and the installer lets you opt out. 40HXCheck.exe -jsonfor scripting and ticket systems.- New CI rebuilds the EFI from source on every push and fails if it doesn't hash-match the committed binary.
Added
- Secure Boot signing (
windows/tools/unlock40x/sign_efi.sh): signs the built EFI with your owndbkey viasbctl(orsbsignas a fallback), verifies the result actually carries a certificate, and prints the signer so you can confirm it's yours. 40HXInstaller.exe -efi <path>to deploy a signed EFI explicitly; a40HXUNLK.signed.efiplaced next to the installer is also picked up automatically. Deployment now prints the payload's source, SHA-256, and signature state, with an explicit warning if Secure Boot is on and the image is unsigned.- PE/Authenticode signature reader (
40hxcore/pesign.go, read-only, no WinVerifyTrust dependency) so40HXCheck.execan tell you whether the deployed EFI is signed and by whom — including a dedicatedsecure_boot_blocks_unsigned_efiverdict instead of a generic "not unlocked". --return-to-bootloaderEFI load option (aliases--return-to-grub,--return-to-limine) for grub/Limine/rEFInd users: the application applies the unlock and hands control back to your boot manager instead of chainloading Windows.- ReBAR reporting and control:
40HXCheck.exereads the XVE Resizable BAR Control register directly and shows whether the 8 GB resize is in effect (NVIDIA APP/Control Panel never show this for this card). Newnorebarload option, a "ReBar Unlock" checkbox in the installer GUI, and-rebar/-norebaron the CLI. 40HXCheck.exe -json: a stable, versioned (40hxcheck/v1) machine-readable report with a fixed verdict enum and matching process exit codes (0 = unlocked, 1 = not unlocked, 2 = inconclusive).- CI (
.github/workflows/ci.yml): builds and vets every Go module on native Windows and via Linux cross-compile, runs unit tests, rebuilds the shipped executables, diffs the generated Windows resource object, and rebuilds the EFI from source inside a pinned toolchain container to confirm40HXUNLK.EFIstill reproduces byte-for-byte.
Changed
- Replaced the old
NO_AUTO_CHAINLOAD=1build-time experiment (separate binary, never fully reliable) with the runtime load-option handoff above. - Installer/checker/uninstaller version bumped to 2.0.1.0.
Upgrade notes
- Default behavior is unchanged if you don't pass any new options: EFI stays unsigned, Secure Boot must stay off, ReBAR still applies automatically.
- If you signed your own EFI previously via a custom process, switch to
sign_efi.sh+-efi <path>(or the40HXUNLK.signed.efisidecar) — the installer now prints the hash/signature state so you can confirm what actually got deployed.
CMP 40HX Windows Unlock v2.0.0
Changes
- Added English, Russian, and Chinese UI/log translations.
- Language selection is shared and persisted across the installer, checker, and uninstaller.
- Fixed duplicate language-change notifications.
- Added persistent language settings via:
HKLM\SOFTWARE\40HXUnlock
CMP 40HX Windows Unlock v1.0.0
Changes
- GSP fallback: now hardware-bound to PCI\VEN_10DE&DEV_1F0B, preventing wrong-GPU configuration on multi-GPU systems.
- UAC elevation: fixed argument quoting/escaping for paths with spaces, quotes, and trailing backslashes.
- EFI cleanup: standardized CMP40 / CMP40HX naming and clearly marked legacy GA102 data.
- Installer localization: the Windows installer now supports English, Russian, and Chinese. English is the default language.
- ReBAR: added CMP 40HX support with 8 GiB BAR1, BAR3 relocation, ACPI-based MMIO placement, mandatory BAR/VRAM verification, and rollback on failure.