Skip to content

Bring in Metro Sequencer and Host Flash - #2696

Merged
labbott merged 1 commit into
masterfrom
labbott/metro_sequencer_hf
Sep 18, 2026
Merged

labbott merged 1 commit into
masterfrom
labbott/metro_sequencer_hf

Conversation

@labbott

@labbott labbott commented Sep 17, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

Comment thread app/cosmo/base.toml
notifications = ["timer"]

[tasks.cosmo_seq]
name = "drv-cosmo-seq-server"

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Experimenting here with the name change. Opinions welcome!

Comment thread app/metro/base.toml Outdated
notifications = ["hash-irq"]

[tasks.hf]
name = "drv-cosmo-hf"

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This did not get a name change because honestly I was feeling a bit meh. But it's also useful for review against the sequencer so we can decide which approach si better

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I decided to do a rename

Base automatically changed from james/metro-spi-and-friends to master September 17, 2026 13:50

@nathanaelhuffman nathanaelhuffman left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only real comment is I'm not sure we have reason to diverge the front fpgas on these two boards, so doing this means we'll have 2 copies of the same thing in the repo which we'll have to remember, but isn't a show stopper either way. I'm happy to rename my front fpga to cosmo-metro-hp if that is helpful.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If it's easier, I don't currently see a reason why the cosmo and metro front FPGAs would need to diverge so will likely remain common. We could rename them to cosmo-metro-hp or something if helpful. We can also support a new name probably but for the foreseeable future these will be the same.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you think they are likely to be the same I'll keep it in common for now and if it diverges we can fix it (it was a useful exercise to see that it's pretty easy to make that happen)

@labbott
labbott force-pushed the labbott/metro_sequencer_hf branch from 3161647 to d5b4dea Compare September 17, 2026 18:12

@jamesmunns jamesmunns left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM, a couple of nits, and made a comment for @nathanaelhuffman about my largest anxiety (NIC sequencing).

OK to merge from me, we can iterate on this in follow-up PRs.

Comment thread drv/cosmo-metro-seq-server/build.rs Outdated
// Check that a valid bitstream is available for this board.
let board = build_util::env_var("HUBRIS_BOARD")?;
if board != "cosmo-a" && board != "cosmo-b" {
if board != "cosmo-a" && board != "cosmo-b" && board != "metro-a" {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could do something like this, in case we end up having more revs of either board in the future:

Suggested change
if board != "cosmo-a" && board != "cosmo-b" && board != "metro-a" {
let supported_boards = &[
"cosmo-a",
"cosmo-b",
"metro-a",
];
if !supported_boards.contains(&board) {

Comment thread drv/spartan7-loader/build.rs Outdated
let board = build_util::target_board().expect("could not get target board");
match board.as_str() {
"grapefruit-a" | "grapefruit-b" | "cosmo-a" | "cosmo-b" => (),
"grapefruit-a" | "grapefruit-b" | "cosmo-a" | "cosmo-b" | "metro-a" => {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same note as https://github.com/oxidecomputer/hubris/pull/2696/changes#r4046175729 about using [&str]::contains() to make this a little easier to read/maintain.

@@ -0,0 +1 @@
THIS IS NOT A REAL METRO IMAGE JUST A COPY OF COSMO AS A PLACEHOLDER

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤣

Comment thread app/metro/base.toml
name = "drv-cosmo-metro-seq-server"
features = ["h753"]
priority = 7
max-sizes = {flash = 131072, ram = 32768 }

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just noting that these sizes are a little overlarge (probably the same for cosmo), but it's not a big deal.

metro_seq        axi_sram   17880  32768  32768
                 flash      43652  49152  131072

metro_seq (stack): 2428 bytes (limit is 3200)

Comment thread app/metro/base.toml
name = "drv-spartan7-loader"
features = ["h753"]
priority = 4
max-sizes = {flash = 131072, ram = 16384 }

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same note about sizes, fine to ignore

spartan7_loader  axi_sram   7072   7168   16384
                 flash      11248  11264  131072

spartan7_loader (stack): 2412 bytes (limit is 2600)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess one question for @nathanaelhuffman:

Are the NicSm and related NIC status parts (nic_raw_status::HwSm) of the FMC interface going to be the same/similar here?

I guess our management of the NIC sequencing is pretty high level (and the FPGA takes care of it?), and I'm not sure what we're going to need to do to sequence (or monitor) the Versal.

We can probably cfg-gate that, but at least for bringup if we need to stub anything out or perform any basic states, we might want to get a head start on that today.

@labbott
labbott force-pushed the labbott/metro_sequencer_hf branch from 27a79b5 to aefdf6a Compare September 18, 2026 13:49
Cosmo and Metro will use different sequencer binaries but
similar interfaces they can share.
@labbott
labbott force-pushed the labbott/metro_sequencer_hf branch from aefdf6a to cc5ec3a Compare September 18, 2026 16:23
@labbott
labbott enabled auto-merge (rebase) September 18, 2026 16:23
@labbott
labbott merged commit f6e5849 into master Sep 18, 2026
196 checks passed
@labbott
labbott deleted the labbott/metro_sequencer_hf branch September 18, 2026 16: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.

3 participants