[v2,2/4] net/virtio: reject deferred start Tx queue setup
diff mbox series

Message ID 1570624330-19119-2-git-send-email-arybchenko@solarflare.com
State Accepted
Delegated to: Maxime Coquelin
Headers show
Series
  • [v2,1/4] net/virtio: reject deferred start Rx queue setup
Related show

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Andrew Rybchenko Oct. 9, 2019, 12:32 p.m. UTC
From: Dilshod Urazov <Dilshod.Urazov@oktetlabs.ru>

Deferred start Tx queue is not supported by the driver.

Fixes: 0748be2cf9a2 ("ethdev: queue start and stop")
Cc: stable@dpdk.org

Signed-off-by: Dilshod Urazov <Dilshod.Urazov@oktetlabs.ru>
Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>
---
 drivers/net/virtio/virtio_rxtx.c | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Maxime Coquelin Oct. 24, 2019, 9:44 a.m. UTC | #1
On 10/9/19 2:32 PM, Andrew Rybchenko wrote:
> From: Dilshod Urazov <Dilshod.Urazov@oktetlabs.ru>
> 
> Deferred start Tx queue is not supported by the driver.
> 
> Fixes: 0748be2cf9a2 ("ethdev: queue start and stop")
> Cc: stable@dpdk.org
> 
> Signed-off-by: Dilshod Urazov <Dilshod.Urazov@oktetlabs.ru>
> Signed-off-by: Andrew Rybchenko <arybchenko@solarflare.com>
> Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>
> ---
>  drivers/net/virtio/virtio_rxtx.c | 5 +++++
>  1 file changed, 5 insertions(+)


Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>

Thanks,
Maxime

Patch
diff mbox series

diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
index a8cd80100..f29e2154b 100644
--- a/drivers/net/virtio/virtio_rxtx.c
+++ b/drivers/net/virtio/virtio_rxtx.c
@@ -1057,6 +1057,11 @@  virtio_dev_tx_queue_setup(struct rte_eth_dev *dev,
 
 	PMD_INIT_FUNC_TRACE();
 
+	if (tx_conf->tx_deferred_start) {
+		PMD_INIT_LOG(ERR, "Tx deferred start is not supported");
+		return -EINVAL;
+	}
+
 	if (nb_desc == 0 || nb_desc > vq->vq_nentries)
 		nb_desc = vq->vq_nentries;
 	vq->vq_free_cnt = RTE_MIN(vq->vq_free_cnt, nb_desc);