orchestrator: Add the Updatable update capability trait - #431
Merged
Conversation
Member
|
@chrysh I can't inspect your claude session links, please fix the permissions |
Contributor
Author
Sorry, there wasn't meant to be a session link. The commit is still in draft state, because I didn't have the time to clean it up yet. |
rusty1968
reviewed
Aug 19, 2026
rusty1968
reviewed
Aug 20, 2026
chrysh
marked this pull request as draft
August 20, 2026 11:11
chrysh
force-pushed
the
add-updatable
branch
5 times, most recently
from
August 25, 2026 10:32
68847ae to
9cadbff
Compare
chrysh
marked this pull request as ready for review
August 25, 2026 10:35
chrysh
force-pushed
the
add-updatable
branch
2 times, most recently
from
August 25, 2026 11:20
535202d to
28d42e8
Compare
leongross
reviewed
Aug 25, 2026
leongross
approved these changes
Aug 26, 2026
This was
linked to
issues
Aug 26, 2026
rusty1968
reviewed
Aug 27, 2026
rusty1968
reviewed
Aug 27, 2026
rusty1968
reviewed
Aug 27, 2026
chrysh
force-pushed
the
add-updatable
branch
3 times, most recently
from
August 27, 2026 10:47
1eac03d to
4458062
Compare
poll_stage advances the transfer one bounded step per call, keeping a single-threaded runtime live and cancellation immediate. activate marks the staged image as boot candidate, tentatively; committing is TrialBoot's job. PayloadSource is the chunked read seam, serving both direct-flash adapters and PLDM devices that pull their own chunks. Assisted-by: Claude:claude-fable-5 Signed-off-by: Christina Quast <christina.quast@9elements.com>
Boards usually mix archetypes (flash and PLDM devices side by side), and the associated Error plus the generic payload parameter forced one concrete Updatable type per board. Follows BootWatch: poll_stage takes &dyn PayloadSource and errors are the erased UpdateError; adapters log concrete causes while they are in scope. A board preferring static dispatch can still wrap its devices in an enum. Assisted-by: Claude (Fable 5)
With len() == 0 the written == total termination check held on the first poll, so an image-less staging reached Ready and could be activated. An empty payload is a caller bug: poll_stage now returns the new UpdateError::EmptyPayload before touching the device. Assisted-by: Claude (Fable 5)
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.
Adds the
Updatablecapability trait to the orchestrator's capability crate, covering the staging and activation half of the update flow.poll_stageadvances the transfer one bounded step per call, so a single-threaded runtime stays live and cancellation takes effect between steps.activatemarks the staged image as the boot candidate only tentatively; committing the image is TrialBoot's job.PayloadSourceis the chunked read seam, serving both direct-flash adapters and PLDM devices that pull their own chunks.Trait-level tests included in
updatable.rs.Part of 9elements#8. Related: #377 — the trial-boot/commit/rollback capabilities;
activatehere stays tentative because committing is that seam's job.