summaryrefslogtreecommitdiffstats
path: root/drivers/virtio
diff options
context:
space:
mode:
authorMichael S. Tsirkin <mst@redhat.com>2020-06-08 07:43:22 +0200
committerMichael S. Tsirkin <mst@redhat.com>2020-06-08 11:12:52 +0200
commitb3fb6de7c6019c5d8495c3a115d42a0f118f631c (patch)
tree4ddbdc2bb2b945f01f298577deb36149b4f5f5ea /drivers/virtio
parentifcvf: implement config interrupt in IFCVF (diff)
downloadlinux-b3fb6de7c6019c5d8495c3a115d42a0f118f631c.tar.xz
linux-b3fb6de7c6019c5d8495c3a115d42a0f118f631c.zip
virtio-mem: drop unnecessary initialization
rc is initialized to -ENIVAL but that's never used. Drop it. Fixes: 5f1f79bbc9e2 ("virtio-mem: Paravirtualized memory hotplug") Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Acked-by: David Hildenbrand <david@redhat.com>
Diffstat (limited to 'drivers/virtio')
-rw-r--r--drivers/virtio/virtio_mem.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/virtio/virtio_mem.c b/drivers/virtio/virtio_mem.c
index f658fe9149be..2f357142ea5e 100644
--- a/drivers/virtio/virtio_mem.c
+++ b/drivers/virtio/virtio_mem.c
@@ -1768,7 +1768,7 @@ static void virtio_mem_delete_resource(struct virtio_mem *vm)
static int virtio_mem_probe(struct virtio_device *vdev)
{
struct virtio_mem *vm;
- int rc = -EINVAL;
+ int rc;
BUILD_BUG_ON(sizeof(struct virtio_mem_req) != 24);
BUILD_BUG_ON(sizeof(struct virtio_mem_resp) != 10);