Instead of just returning 0/-1 and letting the caller make up a
meaningless error message, switch to 0/-errno so that different kinds of
errors can be distinguished in the caller.
This involves changing a few more callbacks in VhostOps to return
0/-errno: .vhost_set_owner(), .vhost_get_features() and
.vhost_virtqueue_set_busyloop_timeout(). The implementations of these
functions are trivial as they generally just send a message to the
backend.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
hw/virtio/vhost-backend.c | 4 +++-
hw/virtio/vhost-user.c | 10 +++++++---
hw/virtio/vhost-vdpa.c | 4 +++-
hw/virtio/vhost.c | 8 ++++----
4 files changed, 17 insertions(+), 9 deletions(-)