lowRISC / lowRISC/opentitan

[opentitanlib] Update e2e_bootstrap_rma test to use lc_transition test util.

Open
#18,209 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Earlgrey-PROD Candidate Priority:P3 Type:Cleanup
Dominant language
SystemVerilog
Stars
3.6k
Forks
1.1k
Avg merge
2d 22h
Merged PRs (30d)
141

Description

### Description

The [`e2e_bootstrap_rma`](https://github.com/lowRISC/opentitan/blob/master/sw/host/tests/rom/e2e_bootstrap_rma/src/main.rs) test performs a lifecycle transition from `PROD` to `RMA`.

Much of its logic is duplicated in the [`lc_transition`](https://github.com/lowRISC/opentitan/blob/master/sw/host/opentitanlib/src/test_utils/lc_transition.rs) opentitanlib test utility. `e2e_bootstrap_rma` can be moved over to using this utility.

There is a caveat that the `e2e_bootstrap_rma` test requires the `RMA_BOOTSTRAP` strapping to be set during the transition, and removed before reset. `lc_transition` includes its own reset, so you will need to remove this strapping yourself and reset again (or wait for the [spin loop](https://github.com/lowRISC/opentitan/blob/master/sw/device/silicon_creator/rom/e2e/BUILD#L458) to time out and reset automatically).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read sw/host/tests/rom/e2e_bootstrap_rma/src/main.rs alongside sw/host/opentitanlib/src/test_utils/lc_transition.rs, starting with the existing PROD-to-RMA flow and the utility's reset behavior. Done means e2e_bootstrap_rma uses lc_transition while preserving the RMA_BOOTSTRAP strapping requirement and reset sequence; run the relevant e2e_bootstrap_rma test.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
embedded-iot, testing-qa
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.