[PR #8] [MERGED] Make host tests profile-driven; fix stock-selection include path #114

Closed
opened 2026-10-31 07:01:51 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/windows-GPU-UNLOCK/Windows-GPU-UNLOCK/pull/8
Author: @pavel-shpilev
Created: 10/25/2026
Status: ✅ Merged
Merged: 10/25/2026
Merged by: @impacifist

Base: main ← Head: fix/profile-driven-host-tests


📝 Commits (1)

  • 7cae6aa Make host tests profile-driven; fix stock-selection include path

📊 Changes

6 files changed (+49 additions, -20 deletions)

View changed files

📝 internal-boot/boot/make-console-fixture.py (+17 -5)
📝 internal-boot/boot/test_console.c (+5 -4)
📝 internal-boot/unlock/tests/test_3090_experimental.c (+11 -4)
📝 internal-boot/unlock/tests/test_3090_preflight.c (+1 -1)
📝 internal-boot/unlock/tests/test_efi_transaction.c (+14 -5)
📝 internal-boot/unlock/tests/test_stock_selection.py (+1 -1)

📄 Description

Several host-test mocks hard-code values of the original B650M / RTX 3090 FE machine, so a build with any other compile-time profile fails inside the mocks before the code under test is reached. I hit this while adding a third profile (GA102 RTX 3090 Ti on a Gigabyte X870; follow-up PR). This PR only makes the tests profile-driven; it does not change any EFI source.

Changes

File Was Now
boot/test_console.c text/GOP image size 0x7820/0x48a0, stops 0x1494/0xf04, version 0x10 GU_CONSOLE_TEXT_* / GU_CONSOLE_GFX_*
unlock/tests/test_3090_preflight.c BAR mock end 0xf5ffffff GU_BAR0_END
unlock/tests/test_3090_experimental.c PROM hash literal, memory=0x6000, FE cold-state line GU_PROM_SHA256, GU_DEVICE_MEMORY_SIZE; cold line per profile, #error for a profile without one
unlock/tests/test_efi_transaction.c FRTS 0x5ffe00000, WPR2 0x5ffe000/0x5ffeff0, layout delta 0x380000000, FWSEC pin 0x4239c/0xde00, expected[0xde00] FB-top-relative from GU_DEVICE_MEMORY_SIZE; FWSEC pin per profile (#error otherwise); buffer sized from the parsed image
boot/make-console-fixture.py FE device id / framebuffer / second EDID child optional --rtx-id --amd-id --rtx-fb --no-edid-child; defaults unchanged
unlock/tests/test_stock_selection.py -I../deps/... -I../../deps/... (copied from unlock/, one level shallower)

Verification

  • B650M behaviour unchanged: under the default profile every derived expression equals the literal it replaces. Checked with _Static_assert: image sizes/stops/versions, BAR end, memory, FRTS 0x5ffe00000, WPR2 0x5ffe000/0x5ffeff0, delta 0x380000000.
  • test_stock_selection.py: fails on main ('Uefi.h' file not found before any case runs), passes on this branch (19 compile-time cases + 14 parameter rejections).
  • The changed experimental/transaction/entry-latched tests compile for the default profile.
  • With a non-FE profile and that machine's own PROM/capture fixtures, the full transaction, manual entry-latched, automatic and headless app tests pass (112 core transaction scenarios; follow-up PR).

Not verified here

I don't have the original B650M private fixtures (RUN00 capture, PROM.BIN, cold capture), so I couldn't run test-all.ps1 -WithLocalFixtures or test-full.ps1 for the default profile. Running those on your side would confirm the FE results are unchanged.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/windows-GPU-UNLOCK/Windows-GPU-UNLOCK/pull/8 **Author:** [@pavel-shpilev](https://github.com/pavel-shpilev) **Created:** 10/25/2026 **Status:** ✅ Merged **Merged:** 10/25/2026 **Merged by:** [@impacifist](https://github.com/impacifist) **Base:** `main` ← **Head:** `fix/profile-driven-host-tests` --- ### 📝 Commits (1) - [`7cae6aa`](https://github.com/windows-GPU-UNLOCK/Windows-GPU-UNLOCK/commit/7cae6aa9b405e1d58fde098898f4b8c6504441ac) Make host tests profile-driven; fix stock-selection include path ### 📊 Changes **6 files changed** (+49 additions, -20 deletions) <details> <summary>View changed files</summary> 📝 `internal-boot/boot/make-console-fixture.py` (+17 -5) 📝 `internal-boot/boot/test_console.c` (+5 -4) 📝 `internal-boot/unlock/tests/test_3090_experimental.c` (+11 -4) 📝 `internal-boot/unlock/tests/test_3090_preflight.c` (+1 -1) 📝 `internal-boot/unlock/tests/test_efi_transaction.c` (+14 -5) 📝 `internal-boot/unlock/tests/test_stock_selection.py` (+1 -1) </details> ### 📄 Description Several host-test mocks hard-code values of the original B650M / RTX 3090 FE machine, so a build with any other compile-time profile fails inside the mocks before the code under test is reached. I hit this while adding a third profile (GA102 RTX 3090 Ti on a Gigabyte X870; follow-up PR). This PR only makes the tests profile-driven; it does not change any EFI source. ### Changes | File | Was | Now | |---|---|---| | `boot/test_console.c` | text/GOP image size `0x7820`/`0x48a0`, stops `0x1494`/`0xf04`, version `0x10` | `GU_CONSOLE_TEXT_*` / `GU_CONSOLE_GFX_*` | | `unlock/tests/test_3090_preflight.c` | BAR mock end `0xf5ffffff` | `GU_BAR0_END` | | `unlock/tests/test_3090_experimental.c` | PROM hash literal, `memory=0x6000`, FE cold-state line | `GU_PROM_SHA256`, `GU_DEVICE_MEMORY_SIZE`; cold line per profile, `#error` for a profile without one | | `unlock/tests/test_efi_transaction.c` | FRTS `0x5ffe00000`, WPR2 `0x5ffe000/0x5ffeff0`, layout delta `0x380000000`, FWSEC pin `0x4239c/0xde00`, `expected[0xde00]` | FB-top-relative from `GU_DEVICE_MEMORY_SIZE`; FWSEC pin per profile (`#error` otherwise); buffer sized from the parsed image | | `boot/make-console-fixture.py` | FE device id / framebuffer / second EDID child | optional `--rtx-id --amd-id --rtx-fb --no-edid-child`; defaults unchanged | | `unlock/tests/test_stock_selection.py` | `-I../deps/...` | `-I../../deps/...` (copied from `unlock/`, one level shallower) | ### Verification - **B650M behaviour unchanged:** under the default profile every derived expression equals the literal it replaces. Checked with `_Static_assert`: image sizes/stops/versions, BAR end, memory, FRTS `0x5ffe00000`, WPR2 `0x5ffe000`/`0x5ffeff0`, delta `0x380000000`. - `test_stock_selection.py`: **fails on `main`** (`'Uefi.h' file not found` before any case runs), **passes on this branch** (19 compile-time cases + 14 parameter rejections). - The changed experimental/transaction/entry-latched tests compile for the default profile. - With a non-FE profile and that machine's own PROM/capture fixtures, the full transaction, manual entry-latched, automatic and headless app tests pass (112 core transaction scenarios; follow-up PR). ### Not verified here I don't have the original B650M private fixtures (`RUN00` capture, `PROM.BIN`, cold capture), so I couldn't run `test-all.ps1 -WithLocalFixtures` or `test-full.ps1` for the default profile. Running those on your side would confirm the FE results are unchanged. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 07:01:51 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
windows-GPU-UNLOCK/Windows-GPU-UNLOCK#114
No description provided.