Add new wait_for_success argument to ballon Adjust initializer
A new feature was added to vm_control balloon to wait for a success when
adjusting.
`false` keeps the old behavior.
I'm adding this as part of the weekly crosvm merge. Virtual machine
manager may want to take advantage of the new feature in the future.
Test: m
Bug: 296912647
Change-Id: I4b1f0b99ea1737c2cd6f75272a1efff01f66d104
diff --git a/virtualizationmanager/src/crosvm.rs b/virtualizationmanager/src/crosvm.rs
index 68cc7f2..6372fa8 100644
--- a/virtualizationmanager/src/crosvm.rs
+++ b/virtualizationmanager/src/crosvm.rs
@@ -529,8 +529,10 @@
MemoryTrimLevel::TRIM_MEMORY_RUNNING_MODERATE => 10,
_ => bail!("Invalid memory trim level {:?}", level),
};
- let command =
- BalloonControlCommand::Adjust { num_bytes: total_memory * pct / 100 };
+ let command = BalloonControlCommand::Adjust {
+ num_bytes: total_memory * pct / 100,
+ wait_for_success: false,
+ };
if let Err(e) = vm_control::client::handle_request(
&VmRequest::BalloonCommand(command),
&self.crosvm_control_socket_path,