patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Rasesh Mody <rasesh.mody@cavium.com>
To: dev@dpdk.org
Cc: Harish Patil <harish.patil@cavium.com>,
	ferruh.yigit@intel.com, Dept-EngDPDKDev@cavium.com,
	stable@dpdk.org
Subject: [dpdk-stable] [PATCH 02/11] net/qede: initialize VF tunnel as enabled on start
Date: Sat, 27 Jan 2018 13:15:26 -0800	[thread overview]
Message-ID: <1517087735-16191-3-git-send-email-rasesh.mody@cavium.com> (raw)
In-Reply-To: <1517087735-16191-1-git-send-email-rasesh.mody@cavium.com>

From: Harish Patil <harish.patil@cavium.com>

By default, the PF driver enables tunnel offload for its child VF.
So mark tunnel offloads as enabled in the VF driver to reflect the
actual state.

Fixes: 52d94b57e1c7 ("net/qede: add slowpath support for VXLAN tunneling")
Fixes: d378cefab84e ("net/qede: add support for GENEVE tunneling offload")

Cc: stable@dpdk.org

Signed-off-by: Harish Patil <harish.patil@cavium.com>
---
 drivers/net/qede/qede_ethdev.c |   15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/drivers/net/qede/qede_ethdev.c b/drivers/net/qede/qede_ethdev.c
index 8d82661..8a69d20 100644
--- a/drivers/net/qede/qede_ethdev.c
+++ b/drivers/net/qede/qede_ethdev.c
@@ -3040,9 +3040,22 @@ static int qede_common_dev_init(struct rte_eth_dev *eth_dev, bool is_vf)
 	SLIST_INIT(&adapter->uc_list_head);
 	adapter->mtu = ETHER_MTU;
 	adapter->new_mtu = ETHER_MTU;
-	if (!is_vf)
+	if (!is_vf) {
 		if (qede_start_vport(adapter, adapter->mtu))
 			return -1;
+	} else {
+		/* VF tunnel offloads is enabled by default in PF driver */
+		adapter->vxlan.enable = true;
+		adapter->vxlan.num_filters = 0;
+		adapter->vxlan.filter_type = ETH_TUNNEL_FILTER_IMAC |
+					     ETH_TUNNEL_FILTER_IVLAN;
+		adapter->vxlan.udp_port = QEDE_VXLAN_DEF_PORT;
+		adapter->geneve.enable = true;
+		adapter->vxlan.num_filters = 0;
+		adapter->vxlan.filter_type = ETH_TUNNEL_FILTER_IMAC |
+					     ETH_TUNNEL_FILTER_IVLAN;
+		adapter->vxlan.udp_port = QEDE_GENEVE_DEF_PORT;
+	}
 
 	DP_INFO(edev, "MAC address : %02x:%02x:%02x:%02x:%02x:%02x\n",
 		adapter->primary_mac.addr_bytes[0],
-- 
1.7.10.3

  parent reply	other threads:[~2018-01-27 21:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1517087735-16191-1-git-send-email-rasesh.mody@cavium.com>
2018-01-27 21:15 ` [dpdk-stable] [PATCH 01/11] net/qede/base: fix VF LRO tunnel params configuration Rasesh Mody
2018-01-27 21:15 ` Rasesh Mody [this message]
2018-01-27 21:15 ` [dpdk-stable] [PATCH 03/11] net/qede: fix to check if tunnel L3 header is valid Rasesh Mody
2018-01-27 21:15 ` [dpdk-stable] [PATCH 04/11] net/qede: fix tunnel header size in Tx BD configuration Rasesh Mody
2018-01-27 21:15 ` [dpdk-stable] [PATCH 06/11] net/qede: fix MTU set and max Rx pkt len usage Rasesh Mody
2018-01-27 21:15 ` [dpdk-stable] [PATCH 07/11] net/qede: fix clearing of queue stats Rasesh Mody

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1517087735-16191-3-git-send-email-rasesh.mody@cavium.com \
    --to=rasesh.mody@cavium.com \
    --cc=Dept-EngDPDKDev@cavium.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=harish.patil@cavium.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).