DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/virtio: remove useless check on mempool
@ 2019-05-09  8:03 David Marchand
  2019-05-09  8:03 ` David Marchand
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: David Marchand @ 2019-05-09  8:03 UTC (permalink / raw)
  To: dev; +Cc: stable, Maxime Coquelin, Tiwei Bie, Zhihong Wang

This .rx_queue_setup devop is called after ethdev already dereferenced
the mempool pointer.
No need to check and we can remove this rte_exit.

Fixes: 48cec290a3d2 ("net/virtio: move queue configure code to proper place")
Cc: stable@dpdk.org

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 drivers/net/virtio/virtio_rxtx.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
index 8c56f23..4f44360 100644
--- a/drivers/net/virtio/virtio_rxtx.c
+++ b/drivers/net/virtio/virtio_rxtx.c
@@ -889,11 +889,6 @@
 	rxvq = &vq->rxq;
 	rxvq->queue_id = queue_idx;
 	rxvq->mpool = mp;
-	if (rxvq->mpool == NULL) {
-		rte_exit(EXIT_FAILURE,
-			"Cannot allocate mbufs for rx virtqueue");
-	}
-
 	dev->data->rx_queues[queue_idx] = rxvq;
 
 	return 0;
-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2019-06-05 12:30 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-09  8:03 [dpdk-dev] [PATCH] net/virtio: remove useless check on mempool David Marchand
2019-05-09  8:03 ` David Marchand
2019-05-09 13:29 ` Jens Freimann
2019-05-09 13:29   ` Jens Freimann
2019-05-17  8:16   ` David Marchand
2019-05-17 15:08 ` Maxime Coquelin
2019-06-05 12:29 ` Maxime Coquelin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).