real-hw-test: init - #71
Open
phip1611 wants to merge 14 commits into
Open
Conversation
Manual hardware checks can wait forever for an operator. Disable the UEFI image watchdog so a long session does not reset the machine. Report firmware failures on screen.
Build a feature-gated, non-interactive image and run it under TCG. Require automatic checks for legacy COM1 and a PCI UART. QEMU debug-exit provides the deterministic job result.
MMIO addresses do not describe a Rust allocation, so use the wrapping pointer primitive rather than an in-bounds pointer offset. The UART constructor already rejects a register range that would wrap.
phip1611
marked this pull request as draft
August 16, 2026 15:24
Mirror every test diagnostic to a dated file below /uart_16550_test_logs while retaining UEFI console output. Keep one flushed FAT file handle so a failed write is reported as critical and aborts the test instead of losing failure evidence.
A real UART can still be draining the byte accepted by try_send_byte when send_bytes is called. Retry the nonblocking API for one second instead of treating temporary backpressure as a driver failure. Preserve an earlier modem-signal warning if a later driver check fails.
Report the dated USB-drive log path before each normal test exit. This keeps the result on screen when the automated checks fail as well as when they complete successfully.
phip1611
commented
Aug 26, 2026
phip1611
left a comment
Member
Author
There was a problem hiding this comment.
Almost. Let's drop the ci feature. The crate should not know anything required for a CI run. IF this means a QEMU CI run is not feasible than drop that entirely. If it is possible, keep the QEMU CI run.
| @@ -0,0 +1,31 @@ | |||
| name: UEFI real-hardware test smoke test | |||
Member
Author
There was a problem hiding this comment.
I do not like that the driver needs to know anything about the CI test. Let's strip all functionality of the testing infrastructur that depends on this.
| // register ranges whose address arithmetic would wrap. | ||
| let address = self.0.as_ptr().wrapping_add(offset as usize); | ||
| let message = "validated MMIO address offset cannot be null"; | ||
| let address = NonNull::new(address).expect(message); |
Member
Author
There was a problem hiding this comment.
embed this message without binding
| @@ -0,0 +1 @@ | |||
| use flake | |||
Member
Author
There was a problem hiding this comment.
split the addition of flake.nix into a dedicated commit, and squash this change into that new commit
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Init a new crate member that builds a EFI file that can be easily booted on real hardware.