mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
virtio-devices: vhost_user: Set features once acknowledged by guest
Make sure the virtio features are set upon device activation. At the time the device is activated, we know the guest acknowledged the features, which mean it's safe to set them back to the backend. Signed-off-by: Sebastien Boeuf <sebastien.boeuf@intel.com>
This commit is contained in:
@@ -74,7 +74,11 @@ pub fn setup_vhost_user(
|
||||
queues: Vec<Queue>,
|
||||
queue_evts: Vec<EventFd>,
|
||||
virtio_interrupt: &Arc<dyn VirtioInterrupt>,
|
||||
acked_features: u64,
|
||||
) -> Result<()> {
|
||||
vu.set_features(acked_features)
|
||||
.map_err(Error::VhostUserSetFeatures)?;
|
||||
|
||||
// Let's first provide the memory table to the backend.
|
||||
update_mem_table(vu, mem)?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user