MCPcopy Create free account
hub / github.com/cloud-hypervisor/cloud-hypervisor / fw_path

Function fw_path

cloud-hypervisor/tests/common/utils.rs:471–487  ·  view source on GitHub ↗
(_fw_type: FwType)

Source from the content-addressed store, hash-verified

469}
470
471pub(crate) fn fw_path(_fw_type: FwType) -> String {
472 let mut workload_path = dirs::home_dir().unwrap();
473 workload_path.push("workloads");
474
475 let mut fw_path = workload_path;
476 #[cfg(target_arch = "aarch64")]
477 fw_path.push("CLOUDHV_EFI.fd");
478 #[cfg(target_arch = "x86_64")]
479 {
480 match _fw_type {
481 FwType::Ovmf => fw_path.push(OVMF_NAME),
482 FwType::RustHypervisorFirmware => fw_path.push("hypervisor-fw"),
483 }
484 }
485
486 fw_path.to_str().unwrap().to_string()
487}
488
489/// Parse the event_monitor file based on the format that each event
490/// is followed by a double newline

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected