summaryrefslogtreecommitdiffstats
path: root/drivers/s390/kvm/kvm_virtio.c
diff options
context:
space:
mode:
authorMichael S. Tsirkin <mst@redhat.com>2014-12-04 20:20:27 +0200
committerMichael S. Tsirkin <mst@redhat.com>2014-12-09 16:32:32 +0200
commit5c609a5ef05d98e26778824ba84581fe5e400db6 (patch)
tree487da89e8ad7ef9d3bcb485ae877518f1669e18b /drivers/s390/kvm/kvm_virtio.c
parentce15408f350c4b97635618692a45aedabfdd2696 (diff)
downloadlinux-5c609a5ef05d98e26778824ba84581fe5e400db6.tar.bz2
virtio: allow finalize_features to fail
This will make it easy for transports to validate features and return failure. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/s390/kvm/kvm_virtio.c')
-rw-r--r--drivers/s390/kvm/kvm_virtio.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/s390/kvm/kvm_virtio.c b/drivers/s390/kvm/kvm_virtio.c
index f5575ccdbb65..dd65c8b4c7fe 100644
--- a/drivers/s390/kvm/kvm_virtio.c
+++ b/drivers/s390/kvm/kvm_virtio.c
@@ -93,7 +93,7 @@ static u64 kvm_get_features(struct virtio_device *vdev)
return features;
}
-static void kvm_finalize_features(struct virtio_device *vdev)
+static int kvm_finalize_features(struct virtio_device *vdev)
{
unsigned int i, bits;
struct kvm_device_desc *desc = to_kvmdev(vdev)->desc;
@@ -112,6 +112,8 @@ static void kvm_finalize_features(struct virtio_device *vdev)
if (__virtio_test_bit(vdev, i))
out_features[i / 8] |= (1 << (i % 8));
}
+
+ return 0;
}
/*