Signed-off-by: Sasha Levin <levinsasha...@gmail.com>
---
 tools/kvm/virtio/blk.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/tools/kvm/virtio/blk.c b/tools/kvm/virtio/blk.c
index ed4e099..9495f28 100644
--- a/tools/kvm/virtio/blk.c
+++ b/tools/kvm/virtio/blk.c
@@ -93,7 +93,8 @@ void virtio_blk_complete(void *param, long len)
        virt_queue__set_used_elem(req->vq, req->head, len);
        mutex_unlock(&bdev->mutex);
 
-       bdev->vtrans.trans_ops->signal_vq(req->kvm, &bdev->vtrans, queueid);
+       if (virtio_queue__should_signal(&bdev->vqs[queueid]))
+               bdev->vtrans.trans_ops->signal_vq(req->kvm, &bdev->vtrans, 
queueid);
 
        virtio_blk_req_push(req->bdev, req);
 }
@@ -170,7 +171,9 @@ static u8 get_config(struct kvm *kvm, void *dev, u32 offset)
 
 static u32 get_host_features(struct kvm *kvm, void *dev)
 {
-       return 1UL << VIRTIO_BLK_F_SEG_MAX | 1UL << VIRTIO_BLK_F_FLUSH;
+       return  1UL << VIRTIO_BLK_F_SEG_MAX
+               | 1UL << VIRTIO_BLK_F_FLUSH
+               | 1UL << VIRTIO_RING_F_EVENT_IDX;
 }
 
 static void set_guest_features(struct kvm *kvm, void *dev, u32 features)
-- 
1.7.8.rc1

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to