From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <stable-bounces@dpdk.org>
Received: from dpdk.org (dpdk.org [92.243.14.124])
	by dpdk.space (Postfix) with ESMTP id 8CB59A0096
	for <public@inbox.dpdk.org>; Wed, 10 Apr 2019 18:46:03 +0200 (CEST)
Received: from [92.243.14.124] (localhost [127.0.0.1])
	by dpdk.org (Postfix) with ESMTP id 7D13D1B105;
	Wed, 10 Apr 2019 18:46:03 +0200 (CEST)
Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28])
 by dpdk.org (Postfix) with ESMTP id E66C91B128
 for <stable@dpdk.org>; Wed, 10 Apr 2019 18:46:00 +0200 (CEST)
Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com
 [10.5.11.14])
 (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))
 (No client certificate requested)
 by mx1.redhat.com (Postfix) with ESMTPS id 5E449308624C;
 Wed, 10 Apr 2019 16:46:00 +0000 (UTC)
Received: from rh.redhat.com (ovpn-117-94.ams2.redhat.com [10.36.117.94])
 by smtp.corp.redhat.com (Postfix) with ESMTP id 7C6495D962;
 Wed, 10 Apr 2019 16:45:59 +0000 (UTC)
From: Kevin Traynor <ktraynor@redhat.com>
To: Hyong Youb Kim <hyonkim@cisco.com>
Cc: dpdk stable <stable@dpdk.org>
Date: Wed, 10 Apr 2019 17:44:05 +0100
Message-Id: <20190410164411.10546-57-ktraynor@redhat.com>
In-Reply-To: <20190410164411.10546-1-ktraynor@redhat.com>
References: <20190410164411.10546-1-ktraynor@redhat.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14
X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16
 (mx1.redhat.com [10.5.110.49]); Wed, 10 Apr 2019 16:46:00 +0000 (UTC)
Subject: [dpdk-stable] patch 'net/enic: reset VXLAN port regardless of
	overlay offload' has been queued to LTS release 18.11.2
X-BeenThere: stable@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: patches for DPDK stable branches <stable.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/stable>,
 <mailto:stable-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/stable/>
List-Post: <mailto:stable@dpdk.org>
List-Help: <mailto:stable-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/stable>,
 <mailto:stable-request@dpdk.org?subject=subscribe>
Errors-To: stable-bounces@dpdk.org
Sender: "stable" <stable-bounces@dpdk.org>

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/16/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 023e75645afa6e7d356cb7c006786c04ccfad267 Mon Sep 17 00:00:00 2001
From: Hyong Youb Kim <hyonkim@cisco.com>
Date: Sat, 2 Mar 2019 02:42:48 -0800
Subject: [PATCH] net/enic: reset VXLAN port regardless of overlay offload

[ upstream commit af3a16282aaae67224f0220a29f663b8b1b0fb0a ]

Currently, the driver resets the vxlan port register only if overlay
offload is enabled. But, the register is actually tied to hardware
vxlan parsing, which is an independent feature and is always enabled
even if overlay offload is disabled. If left uninitialized, it can
affect flow rules that match vxlan. So always reset the port number
when HW vxlan parsing is available.

Fixes: 8a4efd17410c ("net/enic: add handlers to add/delete vxlan port number")

Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
---
 drivers/net/enic/enic_main.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c
index 406f92a80..098a18d63 100644
--- a/drivers/net/enic/enic_main.c
+++ b/drivers/net/enic/enic_main.c
@@ -1716,6 +1716,13 @@ static int enic_dev_init(struct enic *enic)
 			PKT_TX_TUNNEL_MASK;
 		enic->overlay_offload = true;
-		enic->vxlan_port = ENIC_DEFAULT_VXLAN_PORT;
 		dev_info(enic, "Overlay offload is enabled\n");
+	}
+	/*
+	 * Reset the vxlan port if HW vxlan parsing is available. It
+	 * is always enabled regardless of overlay offload
+	 * enable/disable.
+	 */
+	if (enic->vxlan) {
+		enic->vxlan_port = ENIC_DEFAULT_VXLAN_PORT;
 		/*
 		 * Reset the vxlan port to the default, as the NIC firmware
-- 
2.20.1

---
  Diff of the applied patch vs upstream commit (please double-check if non-empty:
---
--- -	2019-04-10 14:06:12.235563028 +0100
+++ 0057-net-enic-reset-VXLAN-port-regardless-of-overlay-offl.patch	2019-04-10 14:06:08.013290832 +0100
@@ -1,8 +1,10 @@
-From af3a16282aaae67224f0220a29f663b8b1b0fb0a Mon Sep 17 00:00:00 2001
+From 023e75645afa6e7d356cb7c006786c04ccfad267 Mon Sep 17 00:00:00 2001
 From: Hyong Youb Kim <hyonkim@cisco.com>
 Date: Sat, 2 Mar 2019 02:42:48 -0800
 Subject: [PATCH] net/enic: reset VXLAN port regardless of overlay offload
 
+[ upstream commit af3a16282aaae67224f0220a29f663b8b1b0fb0a ]
+
 Currently, the driver resets the vxlan port register only if overlay
 offload is enabled. But, the register is actually tied to hardware
 vxlan parsing, which is an independent feature and is always enabled
@@ -11,7 +13,6 @@
 when HW vxlan parsing is available.
 
 Fixes: 8a4efd17410c ("net/enic: add handlers to add/delete vxlan port number")
-Cc: stable@dpdk.org
 
 Signed-off-by: Hyong Youb Kim <hyonkim@cisco.com>
 ---
@@ -19,10 +20,10 @@
  1 file changed, 8 insertions(+), 1 deletion(-)
 
 diff --git a/drivers/net/enic/enic_main.c b/drivers/net/enic/enic_main.c
-index 2652949a2..ea9eb2edf 100644
+index 406f92a80..098a18d63 100644
 --- a/drivers/net/enic/enic_main.c
 +++ b/drivers/net/enic/enic_main.c
-@@ -1715,6 +1715,13 @@ static int enic_dev_init(struct enic *enic)
+@@ -1716,6 +1716,13 @@ static int enic_dev_init(struct enic *enic)
  			PKT_TX_TUNNEL_MASK;
  		enic->overlay_offload = true;
 -		enic->vxlan_port = ENIC_DEFAULT_VXLAN_PORT;