-
Notifications
You must be signed in to change notification settings - Fork 2
[asic-details] Add lotnum (4-character lot number) to SwitchIdentifiers #203
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
052eccd to
af321a1
Compare
This PR adds lotnum (4-character lot number) to SwitchIdentifiers and exposes ASIC details via swadm (and the dpd-client API). The full lot identifier combines fab, lot, and lotnum (e.g., FTCAK7 instead of just T). We do keep the current fields separated however, but update the view for the combination. Adds v1::SwitchIdentifiers for API versions 1-4 (without lotnum), with the latest version (v5+) including the new field. Fixes #200: Want swadm command to print Tofino ASIC details Fixes #202: Not reporting full lot numbers in oximeter statistics
af321a1 to
4650dc0
Compare
|
@bnaecker Took on this from the issues. |
|
Can we also include Or maybe just all the fuse data? The two above are combined to determine the chip rev, e.g. fn identifiers() -> anyhow::Result<()> {
let pci =
tofino::pci::Pci::new("/dev/tofino/1", tofino::REGISTER_SIZE).unwrap();
let fuse = tofino::fuse::Fuse::read(&pci).unwrap();
let chip_id: tofino::fuse::ChipId = fuse.chip_id.into();
println!(
"device id: {}",
match fuse.device_id {
0x0100 => "A0".to_owned(),
0x0110 => match fuse.rev_num {
0 => "B0".to_owned(),
2 => "B1".to_owned(),
_ => format!("{:016x}", fuse.device_id),
},
_ => format!("{:016x}", fuse.device_id),
}
);
println!("device rev: {}", fuse.rev_num);
println!("chip id: {:016x}", fuse.chip_id);
println!("{}", chip_id);
Ok(())
} |
|
@rcgoodfellow I added the fuse info. I'll work on getting that piped through to oximeter when I update the schema in omicron next. |
|
I don't think we'll realistically be able to update the schema for switch stats right now. The update mechanism we built predates the online update system we have now. That means there's never a period when at least one switch isn't producing data, and so no window in which the old data and schema can be updated reliably to make way for the new. What I would do here is put this more complete value into the existing |
|
@bnaecker done. |
This PR adds lotnum (4-character lot number) to SwitchIdentifiers and exposes ASIC details via swadm (and the dpd-client API). The full lot identifier combines fab, lot, and lotnum (e.g., FTCAK7 instead of just T).
We do keep the current fields separated however, but update the view for the combination.
Adds v1::SwitchIdentifiers for API versions 1-4 (without lotnum), with the latest version (v5+) including the new field.
Fixes #200: Want swadm command to print Tofino ASIC details
Fixes #202: Not reporting full lot numbers in oximeter statistics