Skip to content

Universal GPU Unlock v2.2.1 (USB Safety, DXE Naming & [R]/[I] Asset Cleanup)

Latest

Choose a tag to compare

@BrightRaider BrightRaider released this 03 Dec 13:48

Universal GPU Unlock v2.2.1

Safer USB Install & Uninstall · Cleaner Stickless Reinstalls ([R] ➔ [I]) · DXE Slot Filename Fix


v2.2.1 is a focused reliability patch on top of v2.2.0 that protects plugged-in USB drives during Windows uninstallation, validates USB targets before formatting, and makes Stickless [R] cleanup and [I] upgrades reliable on real UEFI firmware.

(0 permanent VBIOS writes · 0% gaming difference · Official signed NVIDIA drivers & Secure Boot compatible)


What's New in v2.2.1

1. Safer Windows USB Install, Rollback & Uninstall

  • Protects plugged-in USB drives: Uninstalling in Windows now checks drive type, storage bus, and launcher files, touching only internal unlock/EFI partitions and leaving connected GPU_UNLOCK USB sticks alone.
  • Pre-format safety checks: Before quick-formatting a USB stick to FAT32, the installer verifies Administrator privileges, sufficient partition capacity, and that the tool, source folder, and active working directory are not sitting on the target drive.
  • Preserved backups on interrupted updates: If a USB update or file removal fails midway (for example if a USB drive is unplugged during rollback), temporary backups remain preserved on disk instead of being discarded.

2. Cleaner Stickless Removals & Upgrades ([R] ➔ [I])

  • Full folder cleanup on [R] (REMOVE): Removing the Stickless driver in the UEFI boot menu now empties and deletes leftover AD102-ASSETS, GA102-ASSETS, and TU102-ASSETS directories on internal ESP and GPU_UNLOCK partitions—including when NVRAM boot entries were already cleared earlier.
  • Smooth orphaned-asset replacement on [I] (INSTALL): If old leftover asset files exist without an active AdaUnlock NVRAM entry, [I] now replaces them automatically. If an active installation has differing assets, the prompt guides clearly to press [R] (REMOVE), reboot, and then [I] (INSTALL).

3. Fixed Stickless Update Driver Naming (AdaUnlockDxe1..9.efi)

  • In-place Stickless upgrades now write properly spelled AdaUnlockDxe1.efi–AdaUnlockDxe9.efi filenames instead of truncated AdaUnlockDx1..9.efi names, while diagnostics and uninstallers continue recognizing and cleaning up earlier v2.1.4–v2.2.0 AdaUnlockDx1..9.efi entries.

Quick Upgrade / Setup

  1. Create or update your USB drive (Setup.bat): Download Universal_GPU_Unlock_v2.2.1.zip, extract cleanly, plug in your FAT32 USB flash drive, and run Setup.bat ([2] Update Existing USB or [1] Create New USB).
  2. If you use Stickless [I]: Boot once from the updated USB (F8 / F11 / F12) and press [I] to update, or run [R] ➔ reboot ➔ [I] when clearing leftover asset folders or migrating Turing (RTX 20) from <= v2.1.4.
  3. Verify in Windows: Run Launch-Dashboard.bat or Check-GPU-Unlock.bat.

Technical Notes, Verification & SHA-256 Checksums (Click to expand)

Technical Changelog

  • Windows CLI USB Safety, Rollback & Pre-Format Validation (src/win/src/win32.rs, src/win/src/install.rs):
    • Added drive_type (GetDriveTypeW) and bus_type (IOCTL_STORAGE_QUERY_PROPERTY) to VolumeRoot in enumerate_log_roots() and filtered uninstall() targets with should_include_uninstall_volume() (DRIVE_FIXED_TYPE, confirmed non-USB bus, no Setup.bat).
    • Replaced silent TxJournal::rollback() error suppression with structured RollbackOutcome / DeployFailure diagnostics, target-root reachability checks, post-rename created_files tracking, and Drop backup preservation on failed rollback.
    • Added partition_bytes (IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS) RAW capacity fallback and extracted validate_usb_install_preflight() (checking --yes, FAT32 state, current_exe, repo_root, cwd, elevation, and capacity with 4 MiB overhead strictly before Format-Volume).
  • UEFI Stickless DXE Slot Naming & Asset Cleanup (src/driver_nvram.c, src/uefi_lang.h, src/win/src/install.rs):
    • Updated DriverUpdatePath() to 31-CHAR16 template \EFI\Drivers\AdaUnlockDxe0.efi (AdaUnlockDxe1..9.efi) using StrSize16(), while retaining backward-compatible detection/removal of legacy AdaUnlockDx1..9.efi in IsOwnOption(), HasAnyOwnDriverOnVolume(), DeleteDriverFilesAndAssetsIfPresent(), is_own_efi_load_option(), and collect_internal_uninstall_paths().
    • Fixed DeleteAssetDirTree() with GU_MIN_EFI_FILE_INFO_BYTES (offsetof(EFI_FILE_INFO, FileName) + sizeof(CHAR16)) so real EDK2 FatDxe . (84 B) and .. (86 B) entries do not terminate enumeration before child files (sizeof(EFI_FILE_INFO) == 88 B on x64), cleared EFI_FILE_READ_ONLY attributes, ensured spec-compliant DeleteOpenedFile() handle closing, extended [R] (GuRemoveDriverOption() -> CleanupAllInternalDriverArtifacts()) to delete driver binaries and *-ASSETS trees even with empty NVRAM, enabled StageArchAssetsToVolume(..., allow_replace = !reinstall), and updated GU_STR_INST_DRIVER_CONFLICT across EN/ZH-CN/DE.
  • Version & Doc Synchronization (src/version.h, bin/version.h, src/win/Cargo.toml, CHANGELOG.md, DOCUMENTATION.md, README*.md, bin/):
    • Bumped all version headers, Cargo metadata, signed bin/BOOTX64.EFI / bin/AdaUnlockDxe.efi, bin/gpu-unlock.exe, and co-located bin/ docs to v2.2.1.

Verification Scope (56adc6e)

  • Rust CLI Unit Tests (cargo test --manifest-path src/win/Cargo.toml --locked --offline): 22 passed; 0 failed (covering uninstall_volume_filter_excludes_usb_sticks_with_gpu_unlock_label, tx_rollback_failure_preserves_backups_and_reports_incomplete, usb_format_preflight_checks_self_run_repo_and_capacity_before_format, and recognizes_adaunlock_efi_load_option_and_filters_driver_order)
  • MSVC Host C Tests (tests/Run-MsvcHostTests.ps1): MSVC_HOST_TESTS=PASS (15 suites, including expanded test_driver_nvram modeling EDK2 FatDxe ./.. sizes + legacy AdaUnlockDx1..9.efi cleanup, test_s3_resume: 9809 checks, test_s3_non_identity: 77 checks, test_turing_dmactl_scrub: 43 checks, test_turing_unlock_path: 33 checks, test_bar0_guard: 26 checks)
  • Windows Host Tests (tests/Run-WindowsHostTests.ps1): WINDOWS_HOST_TESTS=PASS
  • Python Unit Tests (python -m unittest tests.test_clock_cap -v): 13/13 passed (OK)
  • Live Hardware Verification: Confirmed [R] (REMOVE) -> [I] (INSTALL) -> stickless cold boot on real UEFI FatDxe hardware (RTX 4090, S3 ARMED, v2.2.1 signed binaries) cleanly removed legacy internal ESP and GPU_UNLOCK asset directories before reinstalling, while live uninstall --dry-run --include-esp excluded the connected FAT32 USB deployment stick.
  • Release Archive (src/Build-Release-Zip.ps1): 308 entries (87.08 MB); co-located bin/ documentation (README.md, DOCUMENTATION.md, CHANGELOG.md, version.h) byte-identical to repository root.

SHA-256 Checksums

Universal_GPU_Unlock_v2.2.1.zip : A74C5FCC04DDF53DF5EEE3D9E4543150344D3FAD222D6353390DA6B5CF8DF67D
bin/BOOTX64.EFI                 : D811A66FBB879A63B0E062D5E8AD9A35A7B64FFE93582667C1F51FA442BF59E8
bin/AdaUnlockDxe.efi            : 350D715E147E97D8A02944FB4E6DC34CE5365ACB78B12080097C7DEC51B8B496
bin/gpu-unlock.exe              : 9DDB5F1247A9CD31216F5D773040BEB8865DDCB471E13D2796BD7AEDD88E87FB