[dpdk-stable] patch 'net/virtio: add barrier in interrupt enable' has been queued to LTS release 18.11.2

Kevin Traynor ktraynor at redhat.com
Tue Apr 16 16:36:50 CEST 2019


Hi,

FYI, your patch has been queued to LTS release 18.11.2

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 04/24/19. So please
shout if anyone has objections.

Also note that after the patch there's a diff of the upstream commit vs the
patch applied to the branch. This will indicate if there was any rebasing
needed to apply to the stable branch. If there were code changes for rebasing
(ie: not only metadata diffs), please double check that the rebase was
correctly done.

Thanks.

Kevin Traynor

---
>From 4d06e68e88a603eb8ca13e815498eedefd12c748 Mon Sep 17 00:00:00 2001
From: Tiwei Bie <tiwei.bie at intel.com>
Date: Tue, 19 Mar 2019 14:43:05 +0800
Subject: [PATCH] net/virtio: add barrier in interrupt enable

[ upstream commit 8f66bc4ac3c0d4a11252d860f495abd806aa871f ]

Typically, after enabling Rx interrupt, a check should be done
to make sure that there is no new incoming packets before going
to sleep. So a barrier is needed to make sure that any following
check won't happen before the interrupt is actually enabled.

Fixes: c056be239db5 ("net/virtio: add Rx interrupt enable/disable functions")

Signed-off-by: Tiwei Bie <tiwei.bie at intel.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
---
 drivers/net/virtio/virtio_ethdev.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
index a1096287e..1767140b7 100644
--- a/drivers/net/virtio/virtio_ethdev.c
+++ b/drivers/net/virtio/virtio_ethdev.c
@@ -729,4 +729,5 @@ virtio_dev_rx_queue_intr_enable(struct rte_eth_dev *dev, uint16_t queue_id)
 
 	virtqueue_enable_intr(vq);
+	virtio_mb();
 	return 0;
 }
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-04-16 15:34:26.617302709 +0100
+++ 0032-net-virtio-add-barrier-in-interrupt-enable.patch	2019-04-16 15:34:25.179179972 +0100
@@ -1,35 +1,31 @@
-From 8f66bc4ac3c0d4a11252d860f495abd806aa871f Mon Sep 17 00:00:00 2001
+From 4d06e68e88a603eb8ca13e815498eedefd12c748 Mon Sep 17 00:00:00 2001
 From: Tiwei Bie <tiwei.bie at intel.com>
 Date: Tue, 19 Mar 2019 14:43:05 +0800
 Subject: [PATCH] net/virtio: add barrier in interrupt enable
 
+[ upstream commit 8f66bc4ac3c0d4a11252d860f495abd806aa871f ]
+
 Typically, after enabling Rx interrupt, a check should be done
 to make sure that there is no new incoming packets before going
 to sleep. So a barrier is needed to make sure that any following
 check won't happen before the interrupt is actually enabled.
 
 Fixes: c056be239db5 ("net/virtio: add Rx interrupt enable/disable functions")
-Cc: stable at dpdk.org
 
 Signed-off-by: Tiwei Bie <tiwei.bie at intel.com>
 Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
 ---
- drivers/net/virtio/virtio_ethdev.c | 2 ++
- 1 file changed, 2 insertions(+)
+ drivers/net/virtio/virtio_ethdev.c | 1 +
+ 1 file changed, 1 insertion(+)
 
 diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
-index 78ba7bd29..ff16fb63e 100644
+index a1096287e..1767140b7 100644
 --- a/drivers/net/virtio/virtio_ethdev.c
 +++ b/drivers/net/virtio/virtio_ethdev.c
-@@ -851,8 +851,10 @@ static int
- virtio_dev_rx_queue_intr_enable(struct rte_eth_dev *dev, uint16_t queue_id)
- {
-+	struct virtio_hw *hw = dev->data->dev_private;
- 	struct virtnet_rx *rxvq = dev->data->rx_queues[queue_id];
- 	struct virtqueue *vq = rxvq->vq;
+@@ -729,4 +729,5 @@ virtio_dev_rx_queue_intr_enable(struct rte_eth_dev *dev, uint16_t queue_id)
  
  	virtqueue_enable_intr(vq);
-+	virtio_mb(hw->weak_barriers);
++	virtio_mb();
  	return 0;
  }
 -- 


More information about the stable mailing list