misc: Automatically fix cargo clippy issues added in 1.65 (stable)

The code of the stable branch diverges from the main branch, so we
can't directly backport the corresponding commit to fix the clippy
issues.

See: commit 5e52729453

Signed-off-by: Bo Chen <chen.bo@intel.com>
This commit is contained in:
Bo Chen
2023-01-18 12:43:36 -08:00
committed by Bo Chen
parent 1adfb7e9f8
commit c91a8e1324
60 changed files with 457 additions and 583 deletions

View File

@@ -44,7 +44,7 @@ impl InterruptRoute {
vm.register_irqfd(&self.irq_fd, self.gsi).map_err(|e| {
io::Error::new(
io::ErrorKind::Other,
format!("Failed registering irq_fd: {}", e),
format!("Failed registering irq_fd: {e}"),
)
})?;
@@ -60,7 +60,7 @@ impl InterruptRoute {
vm.unregister_irqfd(&self.irq_fd, self.gsi).map_err(|e| {
io::Error::new(
io::ErrorKind::Other,
format!("Failed unregistering irq_fd: {}", e),
format!("Failed unregistering irq_fd: {e}"),
)
})?;
@@ -109,7 +109,7 @@ impl MsiInterruptGroup {
self.vm.set_gsi_routing(&entry_vec).map_err(|e| {
io::Error::new(
io::ErrorKind::Other,
format!("Failed setting GSI routing: {}", e),
format!("Failed setting GSI routing: {e}"),
)
})
}
@@ -153,7 +153,7 @@ impl InterruptSourceGroup for MsiInterruptGroup {
Err(io::Error::new(
io::ErrorKind::Other,
format!("trigger: Invalid interrupt index {}", index),
format!("trigger: Invalid interrupt index {index}"),
))
}
@@ -188,7 +188,7 @@ impl InterruptSourceGroup for MsiInterruptGroup {
Err(io::Error::new(
io::ErrorKind::Other,
format!("update: Invalid interrupt index {}", index),
format!("update: Invalid interrupt index {index}"),
))
}
}