Merge tag 'v3.7-rc1' into staging/for_v3.8
[firefly-linux-kernel-4.4.55.git] / drivers / lguest / lguest_device.c
index ccb7dfb028fa4937dc87f6954d3ca17b379811fb..fc92ccbd71dc22472c9c6fcea4fb54e5079fa19e 100644 (file)
@@ -263,6 +263,9 @@ static struct virtqueue *lg_find_vq(struct virtio_device *vdev,
        struct virtqueue *vq;
        int err;
 
+       if (!name)
+               return NULL;
+
        /* We must have this many virtqueues. */
        if (index >= ldev->desc->num_vq)
                return ERR_PTR(-ENOENT);