diff --git a/virtio-devices/src/rng.rs b/virtio-devices/src/rng.rs index 227b2a213..eae688ef0 100644 --- a/virtio-devices/src/rng.rs +++ b/virtio-devices/src/rng.rs @@ -230,6 +230,10 @@ impl Rng { } impl VirtioDevice for Rng { + fn config_size(&self) -> Option { + Some(0) + } + fn device_type(&self) -> u32 { self.common.device_type } diff --git a/virtio-devices/src/rtc.rs b/virtio-devices/src/rtc.rs index 57cb73cf3..540508e5e 100644 --- a/virtio-devices/src/rtc.rs +++ b/virtio-devices/src/rtc.rs @@ -601,6 +601,10 @@ impl Rtc { } impl VirtioDevice for Rtc { + fn config_size(&self) -> Option { + Some(0) + } + fn device_type(&self) -> u32 { self.common.device_type } diff --git a/virtio-devices/src/watchdog.rs b/virtio-devices/src/watchdog.rs index 220a5359a..01619f79d 100644 --- a/virtio-devices/src/watchdog.rs +++ b/virtio-devices/src/watchdog.rs @@ -310,6 +310,10 @@ fn timerfd_setup(timer: &File, secs: i64) -> Result<(), io::Error> { } impl VirtioDevice for Watchdog { + fn config_size(&self) -> Option { + Some(0) + } + fn device_type(&self) -> u32 { self.common.device_type }