mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-10-22 04:18:53 +00:00
runtime-rs: check the update memory size
check the update memory size greater than default max memory size Fixes:#6875 Signed-off-by: Zhongtao Hu <zhongtaohu.tim@linux.alibaba.com>
This commit is contained in:
107
src/runtime-rs/Cargo.lock
generated
107
src/runtime-rs/Cargo.lock
generated
@@ -372,12 +372,6 @@ version = "3.13.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a3e2c3daef883ecc1b5d58c15adae93470a91d425f3532ba1695849656af3fc1"
|
||||
|
||||
[[package]]
|
||||
name = "byte-unit"
|
||||
version = "3.1.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "415301c9de11005d4b92193c0eb7ac7adc37e5a49e0ac9bed0a42343512744b8"
|
||||
|
||||
[[package]]
|
||||
name = "byte-unit"
|
||||
version = "4.0.19"
|
||||
@@ -388,6 +382,17 @@ dependencies = [
|
||||
"utf8-width",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "byte-unit"
|
||||
version = "5.0.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bc40af92e0f7f964b7ab1ebc81315cce78fc484802d534143321c956f58d7be3"
|
||||
dependencies = [
|
||||
"rust_decimal",
|
||||
"serde",
|
||||
"utf8-width",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "byteorder"
|
||||
version = "1.4.3"
|
||||
@@ -601,6 +606,30 @@ dependencies = [
|
||||
"crossbeam-utils",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "crossbeam-deque"
|
||||
version = "0.8.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ce6fd6f855243022dcecf8702fef0c297d4338e226845fe067f6341ad9fa0cef"
|
||||
dependencies = [
|
||||
"cfg-if 1.0.0",
|
||||
"crossbeam-epoch",
|
||||
"crossbeam-utils",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "crossbeam-epoch"
|
||||
version = "0.9.15"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ae211234986c545741a7dc064309f67ee1e5ad243d0e48335adc0484d960bcc7"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
"cfg-if 1.0.0",
|
||||
"crossbeam-utils",
|
||||
"memoffset 0.9.0",
|
||||
"scopeguard",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "crossbeam-utils"
|
||||
version = "0.8.16"
|
||||
@@ -1657,7 +1686,7 @@ dependencies = [
|
||||
"anyhow",
|
||||
"base64 0.13.1",
|
||||
"bitmask-enum",
|
||||
"byte-unit 3.1.4",
|
||||
"byte-unit 5.0.3",
|
||||
"glob",
|
||||
"lazy_static",
|
||||
"num_cpus",
|
||||
@@ -1669,6 +1698,7 @@ dependencies = [
|
||||
"serde_json",
|
||||
"slog",
|
||||
"slog-scope",
|
||||
"sysinfo",
|
||||
"thiserror",
|
||||
"toml 0.5.11",
|
||||
]
|
||||
@@ -1843,6 +1873,15 @@ dependencies = [
|
||||
"autocfg",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "memoffset"
|
||||
version = "0.9.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5a634b1c61a95585bd15607c6ab0c4e5b226e695ff2800ba0cdccddf208c406c"
|
||||
dependencies = [
|
||||
"autocfg",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "mime"
|
||||
version = "0.3.17"
|
||||
@@ -2023,6 +2062,15 @@ dependencies = [
|
||||
"static_assertions",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "ntapi"
|
||||
version = "0.4.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e8a3895c6391c39d7fe7ebc444a87eb2991b2a0bc718fdabd071eec617fc68e4"
|
||||
dependencies = [
|
||||
"winapi",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nu-ansi-term"
|
||||
version = "0.46.0"
|
||||
@@ -2809,6 +2857,26 @@ dependencies = [
|
||||
"rand_core 0.5.1",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rayon"
|
||||
version = "1.8.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9c27db03db7734835b3f53954b534c91069375ce6ccaa2e065441e07d9b6cdb1"
|
||||
dependencies = [
|
||||
"either",
|
||||
"rayon-core",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rayon-core"
|
||||
version = "1.12.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5ce3fb6ad83f861aac485e76e1985cd109d9a3713802152be56c3b1f0e0658ed"
|
||||
dependencies = [
|
||||
"crossbeam-deque",
|
||||
"crossbeam-utils",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rdrand"
|
||||
version = "0.4.0"
|
||||
@@ -3024,6 +3092,16 @@ dependencies = [
|
||||
"ordered-multimap",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rust_decimal"
|
||||
version = "1.33.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "06676aec5ccb8fc1da723cc8c0f9a46549f21ebb8753d3915c6c41db1e7f1dc4"
|
||||
dependencies = [
|
||||
"arrayvec",
|
||||
"num-traits",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rustc-demangle"
|
||||
version = "0.1.23"
|
||||
@@ -3559,6 +3637,21 @@ dependencies = [
|
||||
"unicode-ident",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "sysinfo"
|
||||
version = "0.29.11"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "cd727fc423c2060f6c92d9534cef765c65a6ed3f428a03d7def74a8c4348e666"
|
||||
dependencies = [
|
||||
"cfg-if 1.0.0",
|
||||
"core-foundation-sys",
|
||||
"libc",
|
||||
"ntapi",
|
||||
"once_cell",
|
||||
"rayon",
|
||||
"winapi",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "take_mut"
|
||||
version = "0.2.2"
|
||||
|
@@ -756,7 +756,7 @@ impl CloudHypervisorInner {
|
||||
todo!()
|
||||
}
|
||||
|
||||
pub(crate) fn resize_memory(&self, _req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
pub(crate) fn resize_memory(&self, _new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
@@ -178,9 +178,9 @@ impl Hypervisor for CloudHypervisor {
|
||||
inner.guest_memory_block_size_mb()
|
||||
}
|
||||
|
||||
async fn resize_memory(&self, req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
async fn resize_memory(&self, new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
let inner = self.inner.read().await;
|
||||
inner.resize_memory(req_mem_mb)
|
||||
inner.resize_memory(new_mem_mb)
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -32,7 +32,8 @@ use std::{collections::HashSet, fs::create_dir_all};
|
||||
|
||||
const DRAGONBALL_KERNEL: &str = "vmlinux";
|
||||
const DRAGONBALL_ROOT_FS: &str = "rootfs";
|
||||
|
||||
const BALLOON_DEVICE_ID: &str = "balloon0";
|
||||
const MEM_DEVICE_ID: &str = "memmr0";
|
||||
#[derive(Debug)]
|
||||
pub struct DragonballInner {
|
||||
/// sandbox id
|
||||
@@ -76,6 +77,9 @@ pub struct DragonballInner {
|
||||
|
||||
/// the hotplug memory size
|
||||
pub(crate) mem_hotplug_size_mb: u32,
|
||||
|
||||
/// the balloon size
|
||||
pub(crate) balloon_size: u32,
|
||||
}
|
||||
|
||||
impl DragonballInner {
|
||||
@@ -85,7 +89,8 @@ impl DragonballInner {
|
||||
CapabilityBits::BlockDeviceSupport
|
||||
| CapabilityBits::BlockDeviceHotplugSupport
|
||||
| CapabilityBits::FsSharingSupport
|
||||
| CapabilityBits::HybridVsockSupport,
|
||||
| CapabilityBits::HybridVsockSupport
|
||||
| CapabilityBits::GuestMemoryProbe,
|
||||
);
|
||||
DragonballInner {
|
||||
id: "".to_string(),
|
||||
@@ -102,6 +107,7 @@ impl DragonballInner {
|
||||
capabilities,
|
||||
guest_memory_block_size_mb: 0,
|
||||
mem_hotplug_size_mb: 0,
|
||||
balloon_size: 0,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -349,33 +355,51 @@ impl DragonballInner {
|
||||
Ok((old_vcpus, new_vcpus))
|
||||
}
|
||||
|
||||
pub(crate) fn resize_memory(&mut self, req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
pub(crate) fn resize_memory(&mut self, new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
// check the invalid request memory
|
||||
if new_mem_mb > self.hypervisor_config().memory_info.default_maxmemory {
|
||||
warn!(
|
||||
sl!(),
|
||||
"memory size unchanged, the request memory size {} is greater than the max memory size {}",
|
||||
new_mem_mb, self.hypervisor_config().memory_info.default_maxmemory
|
||||
);
|
||||
|
||||
return Ok((
|
||||
0,
|
||||
MemoryConfig {
|
||||
..Default::default()
|
||||
},
|
||||
));
|
||||
}
|
||||
|
||||
let had_mem_mb = self.config.memory_info.default_memory + self.mem_hotplug_size_mb;
|
||||
match req_mem_mb.cmp(&had_mem_mb) {
|
||||
match new_mem_mb.cmp(&had_mem_mb) {
|
||||
Ordering::Greater => {
|
||||
// clean virtio-ballon device before hotplug memory, resize to 0
|
||||
let balloon_config = BalloonDeviceConfigInfo {
|
||||
balloon_id: "balloon0".to_owned(),
|
||||
size_mib: 0,
|
||||
use_shared_irq: None,
|
||||
use_generic_irq: None,
|
||||
f_deflate_on_oom: false,
|
||||
f_reporting: false,
|
||||
};
|
||||
self.vmm_instance
|
||||
.insert_balloon_device(balloon_config)
|
||||
.context("failed to insert balloon device")?;
|
||||
if self.balloon_size > 0 {
|
||||
let balloon_config = BalloonDeviceConfigInfo {
|
||||
balloon_id: BALLOON_DEVICE_ID.to_owned(),
|
||||
size_mib: 0,
|
||||
use_shared_irq: None,
|
||||
use_generic_irq: None,
|
||||
f_deflate_on_oom: false,
|
||||
f_reporting: false,
|
||||
};
|
||||
self.vmm_instance
|
||||
.insert_balloon_device(balloon_config)
|
||||
.context("failed to insert balloon device")?;
|
||||
}
|
||||
|
||||
// update the hotplug size
|
||||
self.mem_hotplug_size_mb = req_mem_mb - self.config.memory_info.default_memory;
|
||||
self.mem_hotplug_size_mb = new_mem_mb - self.config.memory_info.default_memory;
|
||||
self.balloon_size = 0;
|
||||
|
||||
// insert a new memory device
|
||||
let add_mem_mb = req_mem_mb - had_mem_mb;
|
||||
let add_mem_mb = new_mem_mb - had_mem_mb;
|
||||
self.vmm_instance.insert_mem_device(MemDeviceConfigInfo {
|
||||
mem_id: format!("mem{}", self.mem_hotplug_size_mb),
|
||||
mem_id: MEM_DEVICE_ID.to_owned(),
|
||||
size_mib: add_mem_mb as u64,
|
||||
capacity_mib: add_mem_mb as u64,
|
||||
multi_region: false,
|
||||
capacity_mib: self.hypervisor_config().memory_info.default_maxmemory as u64,
|
||||
multi_region: true,
|
||||
host_numa_node_id: None,
|
||||
guest_numa_node_id: None,
|
||||
use_shared_irq: None,
|
||||
@@ -384,15 +408,16 @@ impl DragonballInner {
|
||||
}
|
||||
Ordering::Less => {
|
||||
// we only use one balloon device here, and resize it to release memory
|
||||
// the operation we do here is inserting a new balloon0 device or resizing it
|
||||
// the operation we do here is inserting a new BALLOON_DEVICE_ID device or resizing it
|
||||
let balloon_config = BalloonDeviceConfigInfo {
|
||||
balloon_id: "balloon0".to_owned(),
|
||||
size_mib: (had_mem_mb - req_mem_mb) as u64,
|
||||
balloon_id: BALLOON_DEVICE_ID.to_owned(),
|
||||
size_mib: (had_mem_mb - new_mem_mb) as u64,
|
||||
use_shared_irq: None,
|
||||
use_generic_irq: None,
|
||||
f_deflate_on_oom: false,
|
||||
f_reporting: false,
|
||||
};
|
||||
self.balloon_size = had_mem_mb - new_mem_mb;
|
||||
self.vmm_instance
|
||||
.insert_balloon_device(balloon_config)
|
||||
.context("failed to insert balloon device")?;
|
||||
@@ -407,7 +432,7 @@ impl DragonballInner {
|
||||
};
|
||||
|
||||
Ok((
|
||||
req_mem_mb,
|
||||
new_mem_mb,
|
||||
MemoryConfig {
|
||||
..Default::default()
|
||||
},
|
||||
@@ -476,6 +501,7 @@ impl Persist for DragonballInner {
|
||||
capabilities: Capabilities::new(),
|
||||
guest_memory_block_size_mb: 0,
|
||||
mem_hotplug_size_mb: 0,
|
||||
balloon_size: 0,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
@@ -194,9 +194,9 @@ impl Hypervisor for Dragonball {
|
||||
inner.guest_memory_block_size_mb()
|
||||
}
|
||||
|
||||
async fn resize_memory(&self, req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
async fn resize_memory(&self, new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
let mut inner = self.inner.write().await;
|
||||
inner.resize_memory(req_mem_mb)
|
||||
inner.resize_memory(new_mem_mb)
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -91,7 +91,7 @@ pub trait Hypervisor: std::fmt::Debug + Send + Sync {
|
||||
async fn save_vm(&self) -> Result<()>;
|
||||
async fn resume_vm(&self) -> Result<()>;
|
||||
async fn resize_vcpu(&self, old_vcpus: u32, new_vcpus: u32) -> Result<(u32, u32)>; // returns (old_vcpus, new_vcpus)
|
||||
async fn resize_memory(&self, req_mem_mb: u32) -> Result<(u32, MemoryConfig)>;
|
||||
async fn resize_memory(&self, new_mem_mb: u32) -> Result<(u32, MemoryConfig)>;
|
||||
|
||||
// device manager
|
||||
async fn add_device(&self, device: DeviceType) -> Result<DeviceType>;
|
||||
|
@@ -153,7 +153,7 @@ impl QemuInner {
|
||||
todo!()
|
||||
}
|
||||
|
||||
pub(crate) fn resize_memory(&self, _req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
pub(crate) fn resize_memory(&self, _new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
@@ -173,8 +173,8 @@ impl Hypervisor for Qemu {
|
||||
inner.guest_memory_block_size_mb()
|
||||
}
|
||||
|
||||
async fn resize_memory(&self, req_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
async fn resize_memory(&self, new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||
let inner = self.inner.read().await;
|
||||
inner.resize_memory(req_mem_mb)
|
||||
inner.resize_memory(new_mem_mb)
|
||||
}
|
||||
}
|
||||
|
@@ -9,7 +9,6 @@ use std::sync::Arc;
|
||||
|
||||
use anyhow::{Context, Ok, Result};
|
||||
use hypervisor::Hypervisor;
|
||||
use kata_types::config::TomlConfig;
|
||||
use oci::LinuxResources;
|
||||
use tokio::sync::RwLock;
|
||||
|
||||
@@ -21,31 +20,17 @@ pub const MIB_TO_BYTES_SHIFT: i32 = 20;
|
||||
|
||||
#[derive(Default, Debug, Clone)]
|
||||
pub struct MemResource {
|
||||
/// Current memory
|
||||
pub(crate) current_mem: Arc<RwLock<u32>>,
|
||||
|
||||
/// Default memory
|
||||
pub(crate) orig_toml_default_mem: u32,
|
||||
|
||||
/// MemResource of each container
|
||||
pub(crate) container_mem_resources: Arc<RwLock<HashMap<String, LinuxResources>>>,
|
||||
|
||||
/// Use guest swap
|
||||
pub(crate) use_guest_swap: bool,
|
||||
}
|
||||
|
||||
impl MemResource {
|
||||
pub fn new(config: Arc<TomlConfig>, init_size_manager: InitialSizeManager) -> Result<Self> {
|
||||
let hypervisor_name = config.runtime.hypervisor_name.clone();
|
||||
let hypervisor_config = config
|
||||
.hypervisor
|
||||
.get(&hypervisor_name)
|
||||
.context("failed to get hypervisor")?;
|
||||
|
||||
pub fn new(init_size_manager: InitialSizeManager) -> Result<Self> {
|
||||
Ok(Self {
|
||||
current_mem: Arc::new(RwLock::new(hypervisor_config.memory_info.default_memory)),
|
||||
container_mem_resources: Arc::new(RwLock::new(HashMap::new())),
|
||||
use_guest_swap: hypervisor_config.memory_info.enable_guest_swap,
|
||||
orig_toml_default_mem: init_size_manager.get_orig_toml_default_mem(),
|
||||
})
|
||||
}
|
||||
@@ -61,36 +46,23 @@ impl MemResource {
|
||||
.await
|
||||
.context("update container memory resources")?;
|
||||
// the unit here is MB
|
||||
let (mut mem_sb_mb, need_pod_swap, swap_sb_mb) = self
|
||||
.total_mems(self.use_guest_swap)
|
||||
let mut mem_sb_mb = self
|
||||
.total_mems()
|
||||
.await
|
||||
.context("failed to calculate total memory requirement for containers")?;
|
||||
mem_sb_mb += self.orig_toml_default_mem;
|
||||
if need_pod_swap {
|
||||
mem_sb_mb += swap_sb_mb;
|
||||
}
|
||||
info!(sl!(), "calculate mem_sb_mb {}", mem_sb_mb);
|
||||
|
||||
let curr_mem = self
|
||||
.do_update_mem_resource(mem_sb_mb, swap_sb_mb, hypervisor)
|
||||
let _curr_mem = self
|
||||
.do_update_mem_resource(mem_sb_mb, hypervisor)
|
||||
.await
|
||||
.context("failed to update_mem_resource")?;
|
||||
|
||||
self.update_current_mem(curr_mem).await;
|
||||
Ok(())
|
||||
}
|
||||
|
||||
async fn update_current_mem(&self, new_mem: u32) {
|
||||
let mut current_mem = self.current_mem.write().await;
|
||||
*current_mem = new_mem;
|
||||
}
|
||||
|
||||
async fn total_mems(&self, use_guest_swap: bool) -> Result<(u32, bool, u32)> {
|
||||
// sb stands for sandbox
|
||||
async fn total_mems(&self) -> Result<u32> {
|
||||
let mut mem_sandbox = 0;
|
||||
let mut need_pod_swap = false;
|
||||
let mut swap_sandbox = 0;
|
||||
|
||||
let resources = self.container_mem_resources.read().await;
|
||||
|
||||
for (_, r) in resources.iter() {
|
||||
@@ -100,36 +72,17 @@ impl MemResource {
|
||||
|
||||
if let Some(memory) = &r.memory {
|
||||
// set current_limit to 0 if memory limit is not set to container
|
||||
let current_limit = memory.limit.map_or(0, |limit| {
|
||||
let _current_limit = memory.limit.map_or(0, |limit| {
|
||||
mem_sandbox += limit as u64;
|
||||
info!(sl!(), "memory sb: {}, memory limit: {}", mem_sandbox, limit);
|
||||
limit
|
||||
});
|
||||
|
||||
if let Some(swappiness) = memory.swappiness {
|
||||
if swappiness > 0 && use_guest_swap {
|
||||
if let Some(swap) = memory.swap {
|
||||
if swap > current_limit {
|
||||
swap_sandbox = swap.saturating_sub(current_limit);
|
||||
}
|
||||
}
|
||||
// if current_limit is 0, the container will have access to the entire memory available on the host system
|
||||
// so we add swap for this
|
||||
else if current_limit == 0 {
|
||||
need_pod_swap = true;
|
||||
} else {
|
||||
swap_sandbox += current_limit;
|
||||
}
|
||||
}
|
||||
}
|
||||
// TODO support memory guest swap
|
||||
// https://github.com/kata-containers/kata-containers/issues/7293
|
||||
}
|
||||
}
|
||||
|
||||
Ok((
|
||||
(mem_sandbox >> MIB_TO_BYTES_SHIFT) as u32,
|
||||
need_pod_swap,
|
||||
(swap_sandbox >> MIB_TO_BYTES_SHIFT) as u32,
|
||||
))
|
||||
Ok((mem_sandbox >> MIB_TO_BYTES_SHIFT) as u32)
|
||||
}
|
||||
|
||||
// update container_cpu_resources field
|
||||
@@ -156,10 +109,10 @@ impl MemResource {
|
||||
async fn do_update_mem_resource(
|
||||
&self,
|
||||
new_mem: u32,
|
||||
_swap_sz_mb: u32,
|
||||
hypervisor: &dyn Hypervisor,
|
||||
) -> Result<u32> {
|
||||
info!(sl!(), "requesting vmm to update memory to {:?}", new_mem);
|
||||
|
||||
let (new_memory, _mem_config) = hypervisor
|
||||
.resize_memory(new_mem)
|
||||
.await
|
||||
|
@@ -66,7 +66,7 @@ impl ResourceManagerInner {
|
||||
|
||||
let cgroups_resource = CgroupsResource::new(sid, &toml_config)?;
|
||||
let cpu_resource = CpuResource::new(toml_config.clone())?;
|
||||
let mem_resource = MemResource::new(toml_config.clone(), init_size_manager)?;
|
||||
let mem_resource = MemResource::new(init_size_manager)?;
|
||||
Ok(Self {
|
||||
sid: sid.to_string(),
|
||||
toml_config,
|
||||
|
@@ -222,7 +222,7 @@ impl VirtSandbox {
|
||||
// set memory hotplug probe
|
||||
if guest_details.support_mem_hotplug_probe {
|
||||
self.hypervisor
|
||||
.set_capabilities(CapabilityBits::GuestMemoryHotplugProbe)
|
||||
.set_capabilities(CapabilityBits::GuestMemoryProbe)
|
||||
.await;
|
||||
}
|
||||
info!(
|
||||
|
Reference in New Issue
Block a user