virtmgr: migrate from vm_control to crosvm_control
`vm_control` is a crosvm internal API that is subject to arbitrary
refactoring. `crosvm_control` is the stable public API equivalent.
It is no longer possible to detect the `ENOTSUP` case when requesting
balloon stats. Contrary to what the comment said, that case only occurs
when the VM was configured without a virtio-balloon device (at least at
HEAD). For simplicity and consistency with `set_memory_balloon`,
`get_memory_balloon` has been changed to consider this case to be an
error. There are no users of that function yet, so it should be safe to
change.
(If the balloon device is present, but hasn't been initialized by the
guest yet, the call will simply block until it has been initialized,
which is possibly undesirable and needs rethinking. That is true both
before and after this change)
Test: m
Bug: 366271643
Change-Id: Ic58c3c9cf44cb06d517f8739d73f845d22832609
diff --git a/android/virtmgr/Android.bp b/android/virtmgr/Android.bp
index d0d7915..ad63995 100644
--- a/android/virtmgr/Android.bp
+++ b/android/virtmgr/Android.bp
@@ -37,6 +37,7 @@
"libbinder_rs",
"libcfg_if",
"libclap",
+ "libcrosvm_control_static",
"libcstr",
"libcommand_fds",
"libdisk",
@@ -62,7 +63,6 @@
"libstatslog_virtualization_rust",
"libtombstoned_client_rust",
"libvbmeta_rust",
- "libvm_control",
"libvmconfig",
"libzip",
"libvsock",