From 54b65107b193f5c92807a0524e609259a493f87d Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Fri, 18 Mar 2022 16:29:25 +0000 Subject: [PATCH] vmm: config: Validate vDPA devices in configuration Signed-off-by: Rob Bradford --- vmm/src/config.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/vmm/src/config.rs b/vmm/src/config.rs index 8d27410d2..d205bb299 100644 --- a/vmm/src/config.rs +++ b/vmm/src/config.rs @@ -2306,6 +2306,12 @@ impl VmConfig { } } + if let Some(vdpa_devices) = &self.vdpa { + for vdpa_device in vdpa_devices { + vdpa_device.validate(self)?; + } + } + if let Some(balloon) = &self.balloon { let mut ram_size = self.memory.size;