Skip to content

Commit

Permalink
virtio-net: pass Device-TLB enable/disable events to vhost
Browse files Browse the repository at this point in the history
If vhost is enabled for virtio-net, Device-TLB enable/disable events
must be passed to vhost for proper IOMMU unmap flag selection.

Signed-off-by: Viktor Prutyanov <viktor@daynix.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Message-Id: <20230626091258.24453-3-viktor@daynix.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
(cherry picked from commit cd9b834)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
  • Loading branch information
viktor-prutyanov authored and Michael Tokarev committed Jul 26, 2023
1 parent f8fc8e6 commit b7a54f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions hw/net/virtio-net.c
Original file line number Diff line number Diff line change
Expand Up @@ -3888,6 +3888,7 @@ static void virtio_net_class_init(ObjectClass *klass, void *data)
vdc->vmsd = &vmstate_virtio_net_device;
vdc->primary_unplug_pending = primary_unplug_pending;
vdc->get_vhost = virtio_net_get_vhost;
vdc->toggle_device_iotlb = vhost_toggle_device_iotlb;
}

static const TypeInfo virtio_net_info = {
Expand Down

0 comments on commit b7a54f7

Please sign in to comment.