[PERF] Host Debug Overlay Isolation
This commit is contained in:
@@ -486,8 +486,17 @@ impl NativeInterface for VirtualMachineRuntime {
|
||||
1 => BankType::SOUNDS,
|
||||
_ => return Err(VmFault::Trap(TRAP_TYPE, "Invalid asset type".to_string())),
|
||||
};
|
||||
let json =
|
||||
serde_json::to_string(&hw.assets().bank_info(asset_type)).unwrap_or_default();
|
||||
let telemetry = hw
|
||||
.assets()
|
||||
.bank_telemetry()
|
||||
.into_iter()
|
||||
.find(|entry| entry.bank_type == asset_type)
|
||||
.unwrap_or(prometeu_hal::asset::BankTelemetry {
|
||||
bank_type: asset_type,
|
||||
used_slots: 0,
|
||||
total_slots: 0,
|
||||
});
|
||||
let json = serde_json::to_string(&telemetry).unwrap_or_default();
|
||||
ret.push_string(json);
|
||||
Ok(())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user