Skip to content

Spi monitor rename#356

Open
chrysh wants to merge 2 commits into
OpenPRoT:mainfrom
9elements:spi-monitor-rename
Open

Spi monitor rename#356
chrysh wants to merge 2 commits into
OpenPRoT:mainfrom
9elements:spi-monitor-rename

Conversation

@chrysh

@chrysh chrysh commented Jul 17, 2026

Copy link
Copy Markdown

Compiles and passes the following tests:

bazelisk test --config=virt_ast10x0 //target/ast10x0/tests/spimonitor/...

chrysh added 2 commits July 17, 2026 16:04
The board-level monitor module orchestrates the SPI monitor (SPIPF) and
SCU mux control for SPI flash protection. Rename the file monitor.rs ->
spi_monitor.rs and the struct Ast1060Monitor -> Ast1060SpiMonitor, and
update the module path/re-export in lib.rs and the srcs list in
BUILD.bazel, to reflect that it is specifically an SPI monitor.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Christina Quast <christina.quast@9elements.com>
Disambiguate the SPI monitor API from an upcoming BootMonitor subsystem
so the two never collide. Rename in the spimonitor crate:

  Monitor (trait) -> SpiMonitorControl
  MonitorInstance -> SpiMonitorId   (avoids clash with scu::SpiMonitorInstance)
  MonitorStatus   -> SpiMonitorStatus
  MonitorState    -> SpiMonitorState
  MonitorPolicy   -> SpiMonitorPolicy

The SpimWiringError::Monitor and SpiMonitorError::MonitorNotFound enum
variants are left as-is; they are namespaced by their enum and cannot
collide. Update the board impl accordingly.

Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Christina Quast <christina.quast@9elements.com>
@chrysh

chrysh commented Jul 17, 2026

Copy link
Copy Markdown
Author

@rusty1968 @yvettewu1 Can you have a look? The renaming is necessary to disambiguate from the BootMonitor.

@chrysh
chrysh marked this pull request as ready for review July 18, 2026 11:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants