forked from M-Labs/artiq
1
0
Fork 0

satman coremgmt: impl config erase

This commit is contained in:
occheung 2024-09-05 11:56:43 +08:00
parent e2382c2cd5
commit 3be22571ab
1 changed files with 9 additions and 0 deletions

View File

@ -574,6 +574,15 @@ fn process_aux_packet(dmamgr: &mut DmaManager, analyzer: &mut Analyzer, kernelmg
drtioaux::send(0, &drtioaux::Packet::CoreMgmtReply { succeeded }) drtioaux::send(0, &drtioaux::Packet::CoreMgmtReply { succeeded })
} }
drtioaux::Packet::CoreMgmtConfigEraseRequest { destination: _destination } => {
forward!(router, _routing_table, _destination, *rank, *self_destination, _repeaters, &packet);
let succeeded = config::erase()
.map_err(|err| warn!("error on erasing config: {:?}", err))
.is_ok();
drtioaux::send(0, &drtioaux::Packet::CoreMgmtReply { succeeded })
}
drtioaux::Packet::CoreMgmtRebootRequest { destination: _destination } => { drtioaux::Packet::CoreMgmtRebootRequest { destination: _destination } => {
forward!(router, _routing_table, _destination, *rank, *self_destination, _repeaters, &packet); forward!(router, _routing_table, _destination, *rank, *self_destination, _repeaters, &packet);