File tree Expand file tree Collapse file tree 5 files changed +27
-3
lines changed Expand file tree Collapse file tree 5 files changed +27
-3
lines changed Original file line number Diff line number Diff line change @@ -87,9 +87,10 @@ hif = { git = "https://github.com/oxidecomputer/hif" }
87
87
humpty = { git = " https://github.com/oxidecomputer/humpty" , version = " 0.1.3" }
88
88
idol = {git = " https://github.com/oxidecomputer/idolatry.git" }
89
89
idt8a3xxxx = { git = " https://github.com/oxidecomputer/idt8a3xxxx" }
90
+ measurement-token = { git = " https://github.com/oxidecomputer/lpc55_support" , default-features = false }
90
91
pmbus = { git = " https://github.com/oxidecomputer/pmbus" }
91
- spd = { git = " https://github.com/oxidecomputer/spd" }
92
92
serialport = { git = " https://github.com/jgallagher/serialport-rs" , branch = " illumos-support" }
93
+ spd = { git = " https://github.com/oxidecomputer/spd" }
93
94
tlvc = { git = " https://github.com/oxidecomputer/tlvc" }
94
95
tlvc-text = {git = " https://github.com/oxidecomputer/tlvc" }
95
96
vsc7448-info = { git = " https://github.com/oxidecomputer/vsc7448.git" }
Original file line number Diff line number Diff line change @@ -13,6 +13,7 @@ humility-probes-core = { workspace = true }
13
13
cmd-auxflash = { workspace = true }
14
14
clap = { workspace = true }
15
15
anyhow = { workspace = true }
16
+ measurement-token = { workspace = true }
16
17
parse_int = { workspace = true }
17
18
num-traits = { workspace = true }
18
19
tempfile = { workspace = true }
Original file line number Diff line number Diff line change @@ -403,7 +403,23 @@ fn flashcmd(context: &mut ExecutionContext) -> Result<()> {
403
403
std:: thread:: sleep ( std:: time:: Duration :: from_millis ( delay) ) ;
404
404
}
405
405
406
- core. reset ( ) ?;
406
+ // If this image uses handoff to send a measurement token between the RoT
407
+ // and SP, this won't work with a debugger physically attached. To prevent
408
+ // the SP from resetting itself, we write a different token which skips this
409
+ // reboot loop. The memory address and token values are pulled from the
410
+ // `measurement-token` crate in `lpc55_support`, which is also used in the
411
+ // SP firmware.
412
+ if hubris. manifest . features . iter ( ) . any ( |s| s == "measurement-handoff" ) {
413
+ core. reset_and_halt ( std:: time:: Duration :: from_millis ( 25 ) ) ?;
414
+ humility:: msg!( "skipping measurement token handoff" ) ;
415
+ core. write_word_32 (
416
+ measurement_token:: SP_ADDR as u32 ,
417
+ measurement_token:: SKIP ,
418
+ ) ?;
419
+ core. run ( ) ?;
420
+ } else {
421
+ core. reset ( ) ?;
422
+ }
407
423
408
424
// At this point, we can attempt to program the auxiliary flash. This has
409
425
// to happen *after* the image is flashed and the core is reset, because it
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ const OXIDE_NT_HUBRIS_ARCHIVE: u32 = OXIDE_NT_BASE + 1;
40
40
const OXIDE_NT_HUBRIS_REGISTERS : u32 = OXIDE_NT_BASE + 2 ;
41
41
const OXIDE_NT_HUBRIS_TASK : u32 = OXIDE_NT_BASE + 3 ;
42
42
43
- const MAX_HUBRIS_VERSION : u32 = 9 ;
43
+ const MAX_HUBRIS_VERSION : u32 = 10 ;
44
44
45
45
#[ derive( Default , Debug , Serialize ) ]
46
46
pub struct HubrisManifest {
You can’t perform that action at this time.
0 commit comments