From 852e0dbd3fe3038e8bc5a1aba0a9c875c245b5ca Mon Sep 17 00:00:00 2001 From: Christina Quast Date: Fri, 27 Nov 2026 20:04:32 +0100 Subject: [PATCH 1/2] target/ast10x0: Name the design questions in the GAPS.md heading GAPS.md also holds design questions, such as the failed spare-slot re-sync, and code comments point to GAPS.md for open decisions. The old heading named the QEMU tests only, so a reader took the file for a list of test coverage. Signed-off-by: Christina Quast Assisted-by: Claude Fable 5.2 --- target/ast10x0/tests/integration/GAPS.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/target/ast10x0/tests/integration/GAPS.md b/target/ast10x0/tests/integration/GAPS.md index 1b5500076..d71a5286f 100644 --- a/target/ast10x0/tests/integration/GAPS.md +++ b/target/ast10x0/tests/integration/GAPS.md @@ -1,7 +1,8 @@ -# What the QEMU integration tests do not cover +# Gaps in the integration tests and in the design -Written 2026-10-05. The scenarios and how to run them are in README.md; -this is the list of what a green run still does not say. +Written 2026-10-05. The scenarios and how to run them are in README.md. +GAPS.md lists what a green run still does not say, and the design +questions the code leaves open. ## The two halves have met, in one scenario From c8ea4daeda347534bf8d8f6fdbe28241d7f28947 Mon Sep 17 00:00:00 2001 From: Christina Quast Date: Fri, 27 Nov 2026 20:04:32 +0100 Subject: [PATCH 2/2] target/ast10x0: List the reset questions of a device update in GAPS.md GAPS.md now lists as undecided how the driver verifies a downstream device that takes its image over PLDM and has no interposed flash. The driver verifies while the reset that the state machine asserted still holds the downstream device, and an ImageSource over PLDM or MCTP has no image to serve while the reset holds, because a downstream device in reset answers no request. The section also lists whether a direct-flash adapter can write the inactive slot while the downstream device runs from the same flash. Signed-off-by: Christina Quast Assisted-by: Claude Fable 5.2 --- target/ast10x0/tests/integration/GAPS.md | 41 ++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/target/ast10x0/tests/integration/GAPS.md b/target/ast10x0/tests/integration/GAPS.md index d71a5286f..a067f1eba 100644 --- a/target/ast10x0/tests/integration/GAPS.md +++ b/target/ast10x0/tests/integration/GAPS.md @@ -266,6 +266,47 @@ close this: re-attempt the pass or mark the slot stale somewhere durable, and answer the Update Agent once the SVN floor advances rather than when the effect arrives. +## The reset around an update of a downstream device + +The `Updatable` doc comment in `capabilities/src/updatable.rs` names a +direct-flash adapter, which writes the payload into the inactive slot of +the downstream device, and a PLDM adapter for a downstream device that +is a Firmware Device. In `full_update`, the downstream device is the +Firmware Device and pulls its chunks from the Update Agent, and +`FdUpdatable::poll_stage` returns `Ready` without a transfer. The +downstream device has to run to pull its chunks, and the state machine +asserts no reset in `State::Updating`. + +After `Effect::ActivateUpdate`, the state machine enters +`PreSupervision`, and `quiesce_all` asserts the reset of every released +component. The driver then runs `VerifyFirmware`, and the state machine +emits `ReleaseReset` only on `VerificationPassed`. The `AssertReset` +contract in `sm/src/platform.rs` requires the platform driver to keep +the reset asserted until the release, so the downstream device cannot +run or rewrite its flash between the check and the release. The +power-on walk verifies with the reset held as well. + +The driver reads the image through the `ImageSource` the board wires. +The `ImageSource` doc comment in `driver/src/board.rs` names interposed +flash and a PLDM/MCTP transfer as sources. With interposed flash, the +eRoT reads the flash while the reset holds the downstream device. A +downstream device held in reset answers no PLDM or MCTP request, so an +`ImageSource` over PLDM or MCTP has no image to serve. The tree has no +`ImageSource` for flash or for PLDM: `MemImage` reads RAM, and +`StubImage` serves no bytes. + +Undecided: + +- How the driver verifies a downstream device that takes its image over + PLDM and has no interposed flash. Candidates are a check with the + downstream device running, a measurement the downstream device + reports, and the authentication of the candidate before + `Effect::ActivateUpdate`. +- Whether a direct-flash adapter can write the inactive slot while the + downstream device runs from the active slot of the same flash. The + `Updatable` contract makes staging inert for the active image and does + not say whether the write needs the reset held. + ## Assertions that are looser than they look `pldm_update/svn_commit` asserts the effect, not the outcome. The state