virtio: Fix return value for dummy function vhost_net_virtqueue_pending
authorStefan Weil <sw@weilnetz.de>
Sun, 22 Dec 2013 14:51:22 +0000 (15:51 +0100)
committerMichael S. Tsirkin <mst@redhat.com>
Sun, 26 Jan 2014 11:06:48 +0000 (13:06 +0200)
cgcc complains that -ENOSYS is not a good value for 'bool'.

A dummy virtio will never have pending queue entries, so let us return
false.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/net/vhost_net.c

index 006576db31e0af674ca14203f2874b1fe4bb27c3..854997d9ba271eb9fc313493e09a4d1afba1fb49 100644 (file)
@@ -321,7 +321,7 @@ void vhost_net_ack_features(struct vhost_net *net, unsigned features)
 
 bool vhost_net_virtqueue_pending(VHostNetState *net, int idx)
 {
-    return -ENOSYS;
+    return false;
 }
 
 void vhost_net_virtqueue_mask(VHostNetState *net, VirtIODevice *dev,