qemu-e2k/hw/virtio/vhost-stub.c
Viktor Prutyanov ee071f67f7 vhost: register and change IOMMU flag depending on Device-TLB state
The guest can disable or never enable Device-TLB. In these cases,
it can't be used even if enabled in QEMU. So, check Device-TLB state
before registering IOMMU notifier and select unmap flag depending on
that. Also, implement a way to change IOMMU notifier flag if Device-TLB
state is changed.

Buglink: https://bugzilla.redhat.com/show_bug.cgi?id=2001312
Signed-off-by: Viktor Prutyanov <viktor@daynix.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Message-Id: <20230626091258.24453-2-viktor@daynix.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2023-07-10 15:07:50 -04:00

22 lines
345 B
C

#include "qemu/osdep.h"
#include "hw/virtio/vhost.h"
#include "hw/virtio/vhost-user.h"
bool vhost_has_free_slot(void)
{
return true;
}
bool vhost_user_init(VhostUserState *user, CharBackend *chr, Error **errp)
{
return false;
}
void vhost_user_cleanup(VhostUserState *user)
{
}
void vhost_toggle_device_iotlb(VirtIODevice *vdev)
{
}