mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
vmm: Add iommu=on|off option for --rng
Having the virtual IOMMU created with --iommu is one thing, but we also need a way to decide if a virtio-rng device should be attached to this virtual IOMMU or not. That's why we introduce an extra option "iommu" with the value "on" or "off". By default, the device is not attached, which means "iommu=off". Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
committed by
Samuel Ortiz
parent
20c4ed829a
commit
fb4769388b
10
src/main.rs
10
src/main.rs
@@ -80,7 +80,8 @@ fn main() {
|
||||
}
|
||||
|
||||
let default_vcpus = format! {"{}", config::DEFAULT_VCPUS};
|
||||
let default_memory = &format! {"size={}M", config::DEFAULT_MEMORY_MB};
|
||||
let default_memory = format! {"size={}M", config::DEFAULT_MEMORY_MB};
|
||||
let default_rng = format! {"src={}", config::DEFAULT_RNG_SOURCE};
|
||||
|
||||
let cmd_arguments = App::new("cloud-hypervisor")
|
||||
.version(crate_version!())
|
||||
@@ -145,8 +146,11 @@ fn main() {
|
||||
.arg(
|
||||
Arg::with_name("rng")
|
||||
.long("rng")
|
||||
.help("Path to entropy source")
|
||||
.default_value(config::DEFAULT_RNG_SOURCE)
|
||||
.help(
|
||||
"Random number generator parameters \
|
||||
\"src=<entropy_source_path>,iommu=on|off\"",
|
||||
)
|
||||
.default_value(&default_rng)
|
||||
.group("vm-config"),
|
||||
)
|
||||
.arg(
|
||||
|
||||
Reference in New Issue
Block a user