From 0989161b2636a9c9fc526baebaa7fb473e36a3cb Mon Sep 17 00:00:00 2001 From: Tiwei Bie Date: Wed, 25 Jul 2018 22:18:11 +0800 Subject: [PATCH] vhost: release locks on RARP packet failure Fixes: eefac9536a90 ("vhost: postpone device creation until rings are mapped") Cc: stable@dpdk.org Signed-off-by: Tiwei Bie Reviewed-by: Jens Freimann --- lib/librte_vhost/virtio_net.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/librte_vhost/virtio_net.c b/lib/librte_vhost/virtio_net.c index 5779bcf53a..07c8237b9b 100644 --- a/lib/librte_vhost/virtio_net.c +++ b/lib/librte_vhost/virtio_net.c @@ -1628,7 +1628,8 @@ rte_vhost_dequeue_burst(int vid, uint16_t queue_id, if (rarp_mbuf == NULL) { RTE_LOG(ERR, VHOST_DATA, "Failed to make RARP packet.\n"); - return 0; + count = 0; + goto out; } count -= 1; } -- 2.20.1