Skip to content

Commit 552fa9c

Browse files
authored
update hypervisor/mod.rs to use trace crate for logging (#1352)
Signed-off-by: Shailesh Vashishth <shavashishth@gmail.com>
1 parent 25408ba commit 552fa9c

File tree

1 file changed

+5
-5
lines changed
  • src/hyperlight_host/src/hypervisor

1 file changed

+5
-5
lines changed

src/hyperlight_host/src/hypervisor/mod.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ impl LinuxInterruptHandle {
170170
break;
171171
}
172172

173-
log::info!("Sending signal to kill vcpu thread...");
173+
tracing::info!("Sending signal to kill vcpu thread...");
174174
sent_signal = true;
175175
// Acquire ordering to synchronize with the Release store in set_tid()
176176
// This ensures we see the correct tid value for the currently running vcpu
@@ -376,7 +376,7 @@ impl InterruptHandleImpl for WindowsInterruptHandle {
376376
guard.dropped = true;
377377
}
378378
Err(e) => {
379-
log::error!("Failed to acquire partition_state write lock: {}", e);
379+
tracing::error!("Failed to acquire partition_state write lock: {}", e);
380380
}
381381
}
382382
}
@@ -404,7 +404,7 @@ impl InterruptHandle for WindowsInterruptHandle {
404404
let guard = match self.partition_state.read() {
405405
Ok(guard) => guard,
406406
Err(e) => {
407-
log::error!("Failed to acquire partition_state read lock: {}", e);
407+
tracing::error!("Failed to acquire partition_state read lock: {}", e);
408408
return false;
409409
}
410410
};
@@ -432,7 +432,7 @@ impl InterruptHandle for WindowsInterruptHandle {
432432
let guard = match self.partition_state.read() {
433433
Ok(guard) => guard,
434434
Err(e) => {
435-
log::error!("Failed to acquire partition_state read lock: {}", e);
435+
tracing::error!("Failed to acquire partition_state read lock: {}", e);
436436
return false;
437437
}
438438
};
@@ -449,7 +449,7 @@ impl InterruptHandle for WindowsInterruptHandle {
449449
match self.partition_state.read() {
450450
Ok(guard) => guard.dropped,
451451
Err(e) => {
452-
log::error!("Failed to acquire partition_state read lock: {}", e);
452+
tracing::error!("Failed to acquire partition_state read lock: {}", e);
453453
true // Assume dropped if we can't acquire lock
454454
}
455455
}

0 commit comments

Comments
 (0)