mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-08-08 03:24:15 +00:00
Merge pull request #8803 from jodh-intel/issues-8784-runtime-rs-ch-rm-todo-to-unbreak
runtime-rs: ch: Unbreak CH driver
This commit is contained in:
commit
a606401722
@ -73,6 +73,9 @@ pub struct CloudHypervisorInner {
|
|||||||
// If the version of CH does not provide these details, the value will be
|
// If the version of CH does not provide these details, the value will be
|
||||||
// None.
|
// None.
|
||||||
pub(crate) ch_features: Option<Vec<String>>,
|
pub(crate) ch_features: Option<Vec<String>>,
|
||||||
|
|
||||||
|
/// Size of memory block of guest OS in MB (currently unused)
|
||||||
|
pub(crate) _guest_memory_block_size_mb: u32,
|
||||||
}
|
}
|
||||||
|
|
||||||
const CH_DEFAULT_TIMEOUT_SECS: u32 = 10;
|
const CH_DEFAULT_TIMEOUT_SECS: u32 = 10;
|
||||||
@ -112,6 +115,7 @@ impl CloudHypervisorInner {
|
|||||||
tasks: None,
|
tasks: None,
|
||||||
guest_protection_to_use: GuestProtection::NoProtection,
|
guest_protection_to_use: GuestProtection::NoProtection,
|
||||||
ch_features: None,
|
ch_features: None,
|
||||||
|
_guest_memory_block_size_mb: 0,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -741,23 +741,27 @@ impl CloudHypervisorInner {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) async fn get_hypervisor_metrics(&self) -> Result<String> {
|
pub(crate) async fn get_hypervisor_metrics(&self) -> Result<String> {
|
||||||
todo!()
|
Err(anyhow!("CH hypervisor metrics not implemented - see https://github.com/kata-containers/kata-containers/issues/8800"))
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) fn set_capabilities(&mut self, _flag: CapabilityBits) {
|
pub(crate) fn set_capabilities(&mut self, flag: CapabilityBits) {
|
||||||
todo!()
|
let mut caps = Capabilities::default();
|
||||||
|
|
||||||
|
caps.set(flag)
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) fn set_guest_memory_block_size(&mut self, _size: u32) {
|
pub(crate) fn set_guest_memory_block_size(&mut self, size: u32) {
|
||||||
todo!()
|
self._guest_memory_block_size_mb = size;
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) fn guest_memory_block_size_mb(&self) -> u32 {
|
pub(crate) fn guest_memory_block_size_mb(&self) -> u32 {
|
||||||
todo!()
|
self._guest_memory_block_size_mb
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) fn resize_memory(&self, _new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
pub(crate) fn resize_memory(&self, _new_mem_mb: u32) -> Result<(u32, MemoryConfig)> {
|
||||||
todo!()
|
warn!(sl!(), "CH memory resize not implemented - see https://github.com/kata-containers/kata-containers/issues/8801");
|
||||||
|
|
||||||
|
Ok((0, MemoryConfig::default()))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user