vmm: Move VM boot events to Vmm::vm_boot

Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
Bo Chen
2024-03-21 09:54:23 -07:00
parent 55678b23ba
commit 5997cfacbf
2 changed files with 5 additions and 3 deletions
+5
View File
@@ -1216,6 +1216,8 @@ impl RequestHandler for Vmm {
fn vm_boot(&mut self) -> result::Result<(), VmError> {
tracer::start();
info!("Booting VM");
event!("vm", "booting");
let r = {
trace_scoped!("vm_boot");
// If we don't have a config, we can not boot a VM.
@@ -1269,6 +1271,9 @@ impl RequestHandler for Vmm {
}
};
tracer::end();
if r.is_ok() {
event!("vm", "booted");
}
r
}