diff mbox series

virtio: Fix typo in virtio_serial_init()

Message ID 158334524103.1005902.3388578652021543813.stgit@bahia.lan
State Accepted
Headers show
Series virtio: Fix typo in virtio_serial_init() | expand

Commit Message

Greg Kurz March 4, 2020, 6:07 p.m. UTC
From: Cédric Le Goater <clg@kaod.org>

Fixes: 300384f3dc68 ("virtio: Store queue descriptors in virtio_device")
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: Greg Kurz <groug@kaod.org>
---
 lib/libvirtio/virtio-serial.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Alexey Kardashevskiy March 6, 2020, 1:14 a.m. UTC | #1
On 05/03/2020 05:07, Greg Kurz wrote:
> From: Cédric Le Goater <clg@kaod.org>


Thanks, applied. One copy of the patch was enough - if a poster not
subscribed, a maillist owner (me) still gets a mail and can add people
to white list without even subscribing them.


> 
> Fixes: 300384f3dc68 ("virtio: Store queue descriptors in virtio_device")
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> Signed-off-by: Greg Kurz <groug@kaod.org>
> ---
>  lib/libvirtio/virtio-serial.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/libvirtio/virtio-serial.c b/lib/libvirtio/virtio-serial.c
> index 8826be96c24e..d1503a44f433 100644
> --- a/lib/libvirtio/virtio-serial.c
> +++ b/lib/libvirtio/virtio-serial.c
> @@ -81,7 +81,7 @@ int virtio_serial_init(struct virtio_device *dev)
>  	last_rx_idx = virtio_modern16_to_cpu(dev, vq_rx->used->idx);
>  
>  	vq_tx = virtio_queue_init_vq(dev, TX_Q);
> -	if (vq_tx)
> +	if (!vq_tx)
>  		goto dev_error;
>  
>  
>
diff mbox series

Patch

diff --git a/lib/libvirtio/virtio-serial.c b/lib/libvirtio/virtio-serial.c
index 8826be96c24e..d1503a44f433 100644
--- a/lib/libvirtio/virtio-serial.c
+++ b/lib/libvirtio/virtio-serial.c
@@ -81,7 +81,7 @@  int virtio_serial_init(struct virtio_device *dev)
 	last_rx_idx = virtio_modern16_to_cpu(dev, vq_rx->used->idx);
 
 	vq_tx = virtio_queue_init_vq(dev, TX_Q);
-	if (vq_tx)
+	if (!vq_tx)
 		goto dev_error;