virtio-devices: Use Default::default() for transitioning to VirtioCommon

In order to simplify the transition to VirtioCommon and to avoid needing
to set empty fields derive Default for VirtioCommon.

Signed-off-by: Rob Bradford <robert.bradford@intel.com>
This commit is contained in:
Rob Bradford
2020-09-03 16:56:32 +01:00
parent 008cf4a5ae
commit a9a138460b
14 changed files with 14 additions and 10 deletions
+1 -1
View File
@@ -338,7 +338,7 @@ where
Ok(Vsock {
common: VirtioCommon {
avail_features,
acked_features: 0u64,
..Default::default()
},
id,
cid,