get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/10982/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 10982,
    "url": "https://patches.dpdk.org/api/patches/10982/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1456918207-31696-9-git-send-email-jingjing.wu@intel.com/",
    "project": {
        "id": 1,
        "url": "https://patches.dpdk.org/api/projects/1/?format=api",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk",
        "list_archive_url": "https://inbox.dpdk.org/dev",
        "list_archive_url_format": "https://inbox.dpdk.org/dev/{}",
        "commit_url_format": ""
    },
    "msgid": "<1456918207-31696-9-git-send-email-jingjing.wu@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1456918207-31696-9-git-send-email-jingjing.wu@intel.com",
    "date": "2016-03-02T11:30:03",
    "name": "[dpdk-dev,v2,08/12] i40e: extend flow director to filter by tunnel ID",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "a0b98f3bf6d02b90ba036f6362b14b7b46c8b50c",
    "submitter": {
        "id": 47,
        "url": "https://patches.dpdk.org/api/people/47/?format=api",
        "name": "Jingjing Wu",
        "email": "jingjing.wu@intel.com"
    },
    "delegate": {
        "id": 10,
        "url": "https://patches.dpdk.org/api/users/10/?format=api",
        "username": "bruce",
        "first_name": "Bruce",
        "last_name": "Richardson",
        "email": "bruce.richardson@intel.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1456918207-31696-9-git-send-email-jingjing.wu@intel.com/mbox/",
    "series": [],
    "comments": "https://patches.dpdk.org/api/patches/10982/comments/",
    "check": "pending",
    "checks": "https://patches.dpdk.org/api/patches/10982/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id EFB71AD96;\n\tWed,  2 Mar 2016 12:30:40 +0100 (CET)",
            "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n\tby dpdk.org (Postfix) with ESMTP id 01F559AE9\n\tfor <dev@dpdk.org>; Wed,  2 Mar 2016 12:30:38 +0100 (CET)",
            "from fmsmga003.fm.intel.com ([10.253.24.29])\n\tby orsmga101.jf.intel.com with ESMTP; 02 Mar 2016 03:30:35 -0800",
            "from shvmail01.sh.intel.com ([10.239.29.42])\n\tby FMSMGA003.fm.intel.com with ESMTP; 02 Mar 2016 03:30:33 -0800",
            "from shecgisg004.sh.intel.com (shecgisg004.sh.intel.com\n\t[10.239.29.89])\n\tby shvmail01.sh.intel.com with ESMTP id u22BUVv0029190;\n\tWed, 2 Mar 2016 19:30:31 +0800",
            "from shecgisg004.sh.intel.com (localhost [127.0.0.1])\n\tby shecgisg004.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP\n\tid u22BUSgD031788; Wed, 2 Mar 2016 19:30:30 +0800",
            "(from wujingji@localhost)\n\tby shecgisg004.sh.intel.com (8.13.6/8.13.6/Submit) id u22BUSOM031784; \n\tWed, 2 Mar 2016 19:30:28 +0800"
        ],
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.22,528,1449561600\"; d=\"scan'208\";a=\"662447986\"",
        "From": "Jingjing Wu <jingjing.wu@intel.com>",
        "To": "bruce.richardson@intel.com",
        "Date": "Wed,  2 Mar 2016 19:30:03 +0800",
        "Message-Id": "<1456918207-31696-9-git-send-email-jingjing.wu@intel.com>",
        "X-Mailer": "git-send-email 1.7.4.1",
        "In-Reply-To": "<1456918207-31696-1-git-send-email-jingjing.wu@intel.com>",
        "References": "<1453789575-6297-1-git-send-email-jingjing.wu@intel.com>\n\t<1456918207-31696-1-git-send-email-jingjing.wu@intel.com>",
        "Cc": "dev@dpdk.org",
        "Subject": "[dpdk-dev] [PATCH v2 08/12] i40e: extend flow director to filter by\n\ttunnel ID",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "patches and discussions about DPDK <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "This patch extended flow director to select Vxlan/GRE tunnel ID\nas filter's input set and program the filter rule with the defined\ntunnel type.\n\nSigned-off-by: Jingjing Wu <jingjing.wu@intel.com>\n---\n drivers/net/i40e/i40e_ethdev.c |  11 +++\n drivers/net/i40e/i40e_fdir.c   | 150 +++++++++++++++++++++++++++++++----------\n 2 files changed, 125 insertions(+), 36 deletions(-)",
    "diff": "diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethdev.c\nindex 80c703d..df20b6c 100644\n--- a/drivers/net/i40e/i40e_ethdev.c\n+++ b/drivers/net/i40e/i40e_ethdev.c\n@@ -6624,48 +6624,59 @@ i40e_get_valid_input_set(enum i40e_filter_pctype pctype,\n \t */\n \tstatic const uint64_t valid_fdir_inset_table[] = {\n \t\t[I40E_FILTER_PCTYPE_FRAG_IPV4] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV4_SRC | I40E_INSET_IPV4_DST |\n \t\tI40E_INSET_IPV4_TOS | I40E_INSET_IPV4_PROTO |\n \t\tI40E_INSET_IPV4_TTL,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV4_UDP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV4_SRC | I40E_INSET_IPV4_DST |\n \t\tI40E_INSET_IPV4_TOS | I40E_INSET_IPV4_TTL |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV4_TCP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV4_SRC | I40E_INSET_IPV4_DST |\n \t\tI40E_INSET_IPV4_TOS | I40E_INSET_IPV4_TTL |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV4_SCTP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV4_SRC | I40E_INSET_IPV4_DST |\n \t\tI40E_INSET_IPV4_TOS | I40E_INSET_IPV4_TTL |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT |\n \t\tI40E_INSET_SCTP_VT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV4_OTHER] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV4_SRC | I40E_INSET_IPV4_DST |\n \t\tI40E_INSET_IPV4_TOS | I40E_INSET_IPV4_PROTO |\n \t\tI40E_INSET_IPV4_TTL,\n \t\t[I40E_FILTER_PCTYPE_FRAG_IPV6] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV6_SRC | I40E_INSET_IPV6_DST |\n \t\tI40E_INSET_IPV6_TC | I40E_INSET_IPV6_NEXT_HDR |\n \t\tI40E_INSET_IPV6_HOP_LIMIT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV6_UDP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV6_SRC | I40E_INSET_IPV6_DST |\n \t\tI40E_INSET_IPV6_TC | I40E_INSET_IPV6_HOP_LIMIT |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV6_TCP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV6_SRC | I40E_INSET_IPV6_DST |\n \t\tI40E_INSET_IPV6_TC | I40E_INSET_IPV6_HOP_LIMIT |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV6_SCTP] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV6_SRC | I40E_INSET_IPV6_DST |\n \t\tI40E_INSET_IPV6_TC | I40E_INSET_IPV6_HOP_LIMIT |\n \t\tI40E_INSET_SRC_PORT | I40E_INSET_DST_PORT |\n \t\tI40E_INSET_SCTP_VT,\n \t\t[I40E_FILTER_PCTYPE_NONF_IPV6_OTHER] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_IPV6_SRC | I40E_INSET_IPV6_DST |\n \t\tI40E_INSET_IPV6_TC | I40E_INSET_IPV6_NEXT_HDR |\n \t\tI40E_INSET_IPV6_HOP_LIMIT,\n \t\t[I40E_FILTER_PCTYPE_L2_PAYLOAD] =\n+\t\tI40E_INSET_TUNNEL_ID |\n \t\tI40E_INSET_LAST_ETHER_TYPE,\n \t};\n \ndiff --git a/drivers/net/i40e/i40e_fdir.c b/drivers/net/i40e/i40e_fdir.c\nindex 5ea97e5..48ec63b 100644\n--- a/drivers/net/i40e/i40e_fdir.c\n+++ b/drivers/net/i40e/i40e_fdir.c\n@@ -687,12 +687,41 @@ i40e_fdir_configure(struct rte_eth_dev *dev)\n }\n \n static inline void\n-i40e_fdir_fill_eth_ip_head(const struct rte_eth_fdir_input *fdir_input,\n-\t\t\t       unsigned char *raw_pkt)\n+i40e_fdir_fill_ether_head(const struct rte_eth_fdir_input *fdir_input,\n+\t\t\t       unsigned char *pkt)\n {\n-\tstruct ether_hdr *ether = (struct ether_hdr *)raw_pkt;\n-\tstruct ipv4_hdr *ip;\n-\tstruct ipv6_hdr *ip6;\n+\tstruct ether_hdr *ether = (struct ether_hdr *)pkt;\n+\tswitch (fdir_input->flow_type) {\n+\tcase RTE_ETH_FLOW_L2_PAYLOAD:\n+\t\tether->ether_type = fdir_input->flow.l2_flow.ether_type;\n+\t\tbreak;\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV4_TCP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV4_UDP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV4_SCTP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV4_OTHER:\n+\tcase RTE_ETH_FLOW_FRAG_IPV4:\n+\t\tether->ether_type = rte_cpu_to_be_16(ETHER_TYPE_IPv4);\n+\t\tbreak;\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV6_TCP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV6_UDP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV6_SCTP:\n+\tcase RTE_ETH_FLOW_NONFRAG_IPV6_OTHER:\n+\tcase RTE_ETH_FLOW_FRAG_IPV6:\n+\t\tether->ether_type = rte_cpu_to_be_16(ETHER_TYPE_IPv6);\n+\t\tbreak;\n+\tdefault:\n+\t\tPMD_DRV_LOG(ERR, \"unknown flow type %u.\",\n+\t\t\t    fdir_input->flow_type);\n+\t\tbreak;\n+\t}\n+}\n+\n+static inline void\n+i40e_fdir_fill_ip_head(const struct rte_eth_fdir_input *fdir_input,\n+\t\t\t       unsigned char *pkt)\n+{\n+\tstruct ipv4_hdr *ip = (struct ipv4_hdr *)pkt;\n+\tstruct ipv6_hdr *ip6 = (struct ipv6_hdr *)pkt;\n \tstatic const uint8_t next_proto[] = {\n \t\t[RTE_ETH_FLOW_FRAG_IPV4] = IPPROTO_IP,\n \t\t[RTE_ETH_FLOW_NONFRAG_IPV4_TCP] = IPPROTO_TCP,\n@@ -707,17 +736,11 @@ i40e_fdir_fill_eth_ip_head(const struct rte_eth_fdir_input *fdir_input,\n \t};\n \n \tswitch (fdir_input->flow_type) {\n-\tcase RTE_ETH_FLOW_L2_PAYLOAD:\n-\t\tether->ether_type = fdir_input->flow.l2_flow.ether_type;\n-\t\tbreak;\n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_TCP:\n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_UDP:\n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_SCTP:\n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_OTHER:\n \tcase RTE_ETH_FLOW_FRAG_IPV4:\n-\t\tip = (struct ipv4_hdr *)(raw_pkt + sizeof(struct ether_hdr));\n-\n-\t\tether->ether_type = rte_cpu_to_be_16(ETHER_TYPE_IPv4);\n \t\tip->version_ihl = I40E_FDIR_IP_DEFAULT_VERSION_IHL;\n \t\t/* set len to by default */\n \t\tip->total_length = rte_cpu_to_be_16(I40E_FDIR_IP_DEFAULT_LEN);\n@@ -741,9 +764,6 @@ i40e_fdir_fill_eth_ip_head(const struct rte_eth_fdir_input *fdir_input,\n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_SCTP:\n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_OTHER:\n \tcase RTE_ETH_FLOW_FRAG_IPV6:\n-\t\tip6 = (struct ipv6_hdr *)(raw_pkt + sizeof(struct ether_hdr));\n-\n-\t\tether->ether_type = rte_cpu_to_be_16(ETHER_TYPE_IPv6);\n \t\tip6->vtc_flow =\n \t\t\trte_cpu_to_be_32(I40E_FDIR_IPv6_DEFAULT_VTC_FLOW |\n \t\t\t\t\t (fdir_input->flow.ipv6_flow.tc <<\n@@ -775,7 +795,7 @@ i40e_fdir_fill_eth_ip_head(const struct rte_eth_fdir_input *fdir_input,\n \t}\n }\n \n-\n+#define I40E_TUNNEL_KEY_LEN 4\n /*\n  * i40e_fdir_construct_pkt - construct packet based on fields in input\n  * @pf: board private structure\n@@ -787,21 +807,86 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \t\t\t     const struct rte_eth_fdir_input *fdir_input,\n \t\t\t     unsigned char *raw_pkt)\n {\n-\tunsigned char *payload, *ptr;\n+\tunsigned char *payload, *ptr, *inner_pkt = raw_pkt;\n \tstruct udp_hdr *udp;\n \tstruct tcp_hdr *tcp;\n \tstruct sctp_hdr *sctp;\n \tuint8_t size, dst = 0;\n \tuint8_t i, pit_idx, set_idx = I40E_FLXPLD_L4_IDX; /* use l4 by default*/\n+\tstatic uint8_t gre4_frame[] = {0x08, 0,\n+\t\t\t0x45, 0, 0, 0x3A, 0, 0, 0, 0, 0x40, 0x2F,\n+\t\t\t0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x20, 0, 0x08, 0,\n+\t\t\t0, 0, 0, 0}; /* Mac+ IP + GRE hdr + key */\n+\tstatic uint8_t gre6_frame[] = {0x08, 0,\n+\t\t\t0x45, 0, 0, 0x3A, 0, 0, 0, 0, 0x40, 0x2F,\n+\t\t\t0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x20, 0, 0x86, 0xDD,\n+\t\t\t0, 0, 0, 0}; /* Mac+ IP + GRE hdr + key */\n+\tstatic uint8_t vxlan_frame[] = {0x08, 0,\n+\t\t\t0x45, 0, 0, 0x3A, 0, 0, 0, 0, 0x40, 0x11,\n+\t\t\t0, 0, 0, 0, 0, 0, 0, 0, 0, 0,\n+\t\t\t0x12, 0xB5, 0x12, 0xB5, 0x08, 0, 0, 0,\n+\t\t\t0, 0, 0, 0, 0, 0, 0, 0}; /* Mac + IP + UDP + VXLAN hdr */\n+\tstatic uint8_t nvgre_frame[] = {0x08, 0,\n+\t\t\t0x45, 0, 0, 0x3A, 0, 0, 0, 0, 0x40, 0x2F,\n+\t\t\t0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0x20, 0, 0x65, 0x58,\n+\t\t\t0, 0, 0, 0}; /*Mac + IP + NVGRE hdr*/\n+\n+\tinner_pkt += 2 * sizeof(struct ether_addr);\n+\t/* fill the tunnel header if required */\n+\tswitch (fdir_input->flow.tunnel_flow.tunnel_type) {\n+\tcase RTE_FDIR_TUNNEL_TYPE_GRE:\n+\t\tif (fdir_input->flow_type == RTE_ETH_FLOW_L2_PAYLOAD) {\n+\t\t\tPMD_DRV_LOG(ERR, \"GRE's inner pkt shouldn't\"\n+\t\t\t\t    \" be L2 frame.\");\n+\t\t\treturn -EINVAL;\n+\t\t}\n+\t\tif ((fdir_input->flow_type) == RTE_ETH_FLOW_FRAG_IPV4 ||\n+\t\t    (fdir_input->flow_type) == RTE_ETH_FLOW_NONFRAG_IPV4_TCP ||\n+\t\t    (fdir_input->flow_type) == RTE_ETH_FLOW_NONFRAG_IPV4_UDP ||\n+\t\t    (fdir_input->flow_type) == RTE_ETH_FLOW_NONFRAG_IPV4_SCTP ||\n+\t\t    (fdir_input->flow_type) == RTE_ETH_FLOW_NONFRAG_IPV4_OTHER)\n+\t\t\trte_memcpy(inner_pkt, gre4_frame, sizeof(gre4_frame));\n+\t\telse\n+\t\t\trte_memcpy(inner_pkt, gre6_frame, sizeof(gre6_frame));\n+\t\t/* gre4_frame and gre6_frame have the same size */\n+\t\tinner_pkt += sizeof(gre4_frame);\n+\t\trte_memcpy(inner_pkt - I40E_TUNNEL_KEY_LEN,\n+\t\t\t   &fdir_input->flow.tunnel_flow.tunnel_id,\n+\t\t\t   I40E_TUNNEL_KEY_LEN);\n+\t\tbreak;\n+\tcase RTE_FDIR_TUNNEL_TYPE_VXLAN:\n+\t\trte_memcpy(inner_pkt, vxlan_frame, sizeof(vxlan_frame));\n+\t\tinner_pkt += sizeof(vxlan_frame);\n+\t\trte_memcpy(inner_pkt - I40E_TUNNEL_KEY_LEN,\n+\t\t\t   &fdir_input->flow.tunnel_flow.tunnel_id,\n+\t\t\t   I40E_TUNNEL_KEY_LEN);\n+\t\t/* fill the ethernet and IP head of inner frame */\n+\t\ti40e_fdir_fill_ether_head(fdir_input, inner_pkt);\n+\t\tinner_pkt += sizeof(struct ether_hdr);\n+\t\tbreak;\n+\tcase RTE_FDIR_TUNNEL_TYPE_NVGRE:\n+\t\trte_memcpy(inner_pkt, nvgre_frame, sizeof(nvgre_frame));\n+\t\tinner_pkt += sizeof(nvgre_frame);\n+\t\trte_memcpy(inner_pkt - I40E_TUNNEL_KEY_LEN,\n+\t\t\t   &fdir_input->flow.tunnel_flow.tunnel_id,\n+\t\t\t   I40E_TUNNEL_KEY_LEN);\n+\t\t/* fill the Ether header of inner frame */\n+\t\ti40e_fdir_fill_ether_head(fdir_input, inner_pkt);\n+\t\tinner_pkt += sizeof(struct ether_hdr);\n+\t\tbreak;\n+\tdefault:\n+\t\t/* fill the Ether header of single frame */\n+\t\ti40e_fdir_fill_ether_head(fdir_input, raw_pkt);\n+\t\tinner_pkt = raw_pkt + sizeof(struct ether_hdr);\n+\t\tbreak;\n+\t}\n \n-\t/* fill the ethernet and IP head */\n-\ti40e_fdir_fill_eth_ip_head(fdir_input, raw_pkt);\n-\n+\t/* fill the IP header of inner or single frame */\n+\ti40e_fdir_fill_ip_head(fdir_input, inner_pkt);\n \t/* fill the L4 head */\n \tswitch (fdir_input->flow_type) {\n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_UDP:\n-\t\tudp = (struct udp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\tsizeof(struct ipv4_hdr));\n+\t\tudp = (struct udp_hdr *)(inner_pkt + sizeof(struct ipv4_hdr));\n \t\tpayload = (unsigned char *)udp + sizeof(struct udp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -814,8 +899,7 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \t\tbreak;\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_TCP:\n-\t\ttcp = (struct tcp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\t\t sizeof(struct ipv4_hdr));\n+\t\ttcp = (struct tcp_hdr *)(inner_pkt + sizeof(struct ipv4_hdr));\n \t\tpayload = (unsigned char *)tcp + sizeof(struct tcp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -828,8 +912,7 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \t\tbreak;\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_SCTP:\n-\t\tsctp = (struct sctp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\t\t   sizeof(struct ipv4_hdr));\n+\t\tsctp = (struct sctp_hdr *)(inner_pkt + sizeof(struct ipv4_hdr));\n \t\tpayload = (unsigned char *)sctp + sizeof(struct sctp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -843,14 +926,12 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV4_OTHER:\n \tcase RTE_ETH_FLOW_FRAG_IPV4:\n-\t\tpayload = raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t  sizeof(struct ipv4_hdr);\n+\t\tpayload = inner_pkt + sizeof(struct ipv4_hdr);\n \t\tset_idx = I40E_FLXPLD_L3_IDX;\n \t\tbreak;\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_UDP:\n-\t\tudp = (struct udp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\t\t sizeof(struct ipv6_hdr));\n+\t\tudp = (struct udp_hdr *)(inner_pkt + sizeof(struct ipv6_hdr));\n \t\tpayload = (unsigned char *)udp + sizeof(struct udp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -863,8 +944,7 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \t\tbreak;\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_TCP:\n-\t\ttcp = (struct tcp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\t\t sizeof(struct ipv6_hdr));\n+\t\ttcp = (struct tcp_hdr *)(inner_pkt + sizeof(struct ipv6_hdr));\n \t\tpayload = (unsigned char *)tcp + sizeof(struct tcp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -877,8 +957,7 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \t\tbreak;\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_SCTP:\n-\t\tsctp = (struct sctp_hdr *)(raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t\t\t   sizeof(struct ipv6_hdr));\n+\t\tsctp = (struct sctp_hdr *)(inner_pkt + sizeof(struct ipv6_hdr));\n \t\tpayload = (unsigned char *)sctp + sizeof(struct sctp_hdr);\n \t\t/*\n \t\t * The source and destination fields in the transmitted packet\n@@ -892,12 +971,11 @@ i40e_fdir_construct_pkt(struct i40e_pf *pf,\n \n \tcase RTE_ETH_FLOW_NONFRAG_IPV6_OTHER:\n \tcase RTE_ETH_FLOW_FRAG_IPV6:\n-\t\tpayload = raw_pkt + sizeof(struct ether_hdr) +\n-\t\t\t  sizeof(struct ipv6_hdr);\n+\t\tpayload = inner_pkt + sizeof(struct ipv6_hdr);\n \t\tset_idx = I40E_FLXPLD_L3_IDX;\n \t\tbreak;\n \tcase RTE_ETH_FLOW_L2_PAYLOAD:\n-\t\tpayload = raw_pkt + sizeof(struct ether_hdr);\n+\t\tpayload = inner_pkt;\n \t\t/*\n \t\t * ARP packet is a special case on which the payload\n \t\t * starts after the whole ARP header\n",
    "prefixes": [
        "dpdk-dev",
        "v2",
        "08/12"
    ]
}