Explorar o código

virtio: fix error handling for debug builds

On error, virtqueue_add calls START_USE but not
END_USE. Thankfully that's normally empty anyway,
but might not be when debugging. Fix it up.

Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin %!s(int64=9) %!d(string=hai) anos
pai
achega
3cc36f6e34
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      drivers/virtio/virtio_ring.c

+ 1 - 0
drivers/virtio/virtio_ring.c

@@ -428,6 +428,7 @@ unmap_release:
 	if (indirect)
 		kfree(desc);
 
+	END_USE(vq);
 	return -EIO;
 }