get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 41086,
    "url": "https://patches.dpdk.org/api/patches/41086/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/1528964248-73416-1-git-send-email-wei.zhao1@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": "<1528964248-73416-1-git-send-email-wei.zhao1@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1528964248-73416-1-git-send-email-wei.zhao1@intel.com",
    "date": "2018-06-14T08:17:28",
    "name": "[v3] net/ixgbe: fix tunnel type set error for FDIR",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "bdebf52d14de3f902c76319f525e2817f73198c2",
    "submitter": {
        "id": 495,
        "url": "https://patches.dpdk.org/api/people/495/?format=api",
        "name": "Zhao1, Wei",
        "email": "wei.zhao1@intel.com"
    },
    "delegate": {
        "id": 1540,
        "url": "https://patches.dpdk.org/api/users/1540/?format=api",
        "username": "qzhan15",
        "first_name": "Qi",
        "last_name": "Zhang",
        "email": "qi.z.zhang@intel.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/1528964248-73416-1-git-send-email-wei.zhao1@intel.com/mbox/",
    "series": [
        {
            "id": 119,
            "url": "https://patches.dpdk.org/api/series/119/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=119",
            "date": "2018-06-14T08:17:28",
            "name": "[v3] net/ixgbe: fix tunnel type set error for FDIR",
            "version": 3,
            "mbox": "https://patches.dpdk.org/series/119/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/41086/comments/",
    "check": "fail",
    "checks": "https://patches.dpdk.org/api/patches/41086/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 0ECC91E416;\n\tThu, 14 Jun 2018 10:38:20 +0200 (CEST)",
            "from mga09.intel.com (mga09.intel.com [134.134.136.24])\n\tby dpdk.org (Postfix) with ESMTP id 30C9B1E3A5;\n\tThu, 14 Jun 2018 10:38:17 +0200 (CEST)",
            "from orsmga004.jf.intel.com ([10.7.209.38])\n\tby orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t14 Jun 2018 01:38:16 -0700",
            "from dpdk6.bj.intel.com ([172.16.182.94])\n\tby orsmga004.jf.intel.com with ESMTP; 14 Jun 2018 01:38:10 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.51,222,1526367600\"; d=\"scan'208\";a=\"208009067\"",
        "From": "Wei Zhao <wei.zhao1@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "wenzhuo.lu@intel.com,\n\tstable@dpdk.org,\n\tWei Zhao <wei.zhao1@intel.com>",
        "Date": "Thu, 14 Jun 2018 16:17:28 +0800",
        "Message-Id": "<1528964248-73416-1-git-send-email-wei.zhao1@intel.com>",
        "X-Mailer": "git-send-email 2.7.5",
        "In-Reply-To": "<1528877502-5076-1-git-send-email-wei.zhao1@intel.com>",
        "References": "<1528877502-5076-1-git-send-email-wei.zhao1@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v3] net/ixgbe: fix tunnel type set error for FDIR",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<https://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": "<https://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": "Tunnel type format should be translated to ixgbe required format\nbefore register set in FDIR cloud mode, Ans also some register\nnot useful in cloud mode but only useful in IP mode should be set\nto zero as datasheet request.\n\nFixes: 82fb702077f6 (\"ixgbe: support new flow director modes for X550\")\nFixes: 11777435c727 (\"net/ixgbe: parse flow director filter\")\n\nSigned-off-by: Wei Zhao <wei.zhao1@intel.com>\n---\n\nv2:\n-change register write function for FDIRIPSA and FDIRIPDA.\n\nv3:\n-add macros for 0x8000 and 0.\n\n---\n drivers/net/ixgbe/ixgbe_ethdev.h |  5 +++++\n drivers/net/ixgbe/ixgbe_fdir.c   | 19 +++++++++++++++----\n drivers/net/ixgbe/ixgbe_flow.c   |  4 ++--\n 3 files changed, 22 insertions(+), 6 deletions(-)",
    "diff": "diff --git a/drivers/net/ixgbe/ixgbe_ethdev.h b/drivers/net/ixgbe/ixgbe_ethdev.h\nindex e42ec30..d0b9396 100644\n--- a/drivers/net/ixgbe/ixgbe_ethdev.h\n+++ b/drivers/net/ixgbe/ixgbe_ethdev.h\n@@ -100,6 +100,11 @@\n #define IXGBE_5TUPLE_MAX_PRI            7\n #define IXGBE_5TUPLE_MIN_PRI            1\n \n+/* bit of VXLAN tunnel type | 7 bits of zeros  | 8 bits of zeros*/\n+#define IXGBE_FDIR_VXLAN_TUNNEL_TYPE    0x8000\n+/* bit of NVGRE tunnel type | 7 bits of zeros  | 8 bits of zeros*/\n+#define IXGBE_FDIR_NVGRE_TUNNEL_TYPE    0x0\n+\n #define IXGBE_RSS_OFFLOAD_ALL ( \\\n \tETH_RSS_IPV4 | \\\n \tETH_RSS_NONFRAG_IPV4_TCP | \\\ndiff --git a/drivers/net/ixgbe/ixgbe_fdir.c b/drivers/net/ixgbe/ixgbe_fdir.c\nindex 67ab627..6baf825 100644\n--- a/drivers/net/ixgbe/ixgbe_fdir.c\n+++ b/drivers/net/ixgbe/ixgbe_fdir.c\n@@ -771,8 +771,17 @@ ixgbe_fdir_filter_to_atr_input(const struct rte_eth_fdir_filter *fdir_filter,\n \t\t\tinput->formatted.inner_mac,\n \t\t\tfdir_filter->input.flow.tunnel_flow.mac_addr.addr_bytes,\n \t\t\tsizeof(input->formatted.inner_mac));\n-\t\tinput->formatted.tunnel_type =\n-\t\t\tfdir_filter->input.flow.tunnel_flow.tunnel_type;\n+\t\tif (fdir_filter->input.flow.tunnel_flow.tunnel_type ==\n+\t\t\t\tRTE_FDIR_TUNNEL_TYPE_VXLAN)\n+\t\t\tinput->formatted.tunnel_type =\n+\t\t\t\t\tIXGBE_FDIR_VXLAN_TUNNEL_TYPE;\n+\t\telse if (fdir_filter->input.flow.tunnel_flow.tunnel_type ==\n+\t\t\t\tRTE_FDIR_TUNNEL_TYPE_NVGRE)\n+\t\t\tinput->formatted.tunnel_type =\n+\t\t\t\t\tIXGBE_FDIR_NVGRE_TUNNEL_TYPE;\n+\t\telse\n+\t\t\tPMD_DRV_LOG(ERR, \" invalid tunnel type arguments.\");\n+\n \t\tinput->formatted.tni_vni =\n \t\t\tfdir_filter->input.flow.tunnel_flow.tunnel_id >> 8;\n \t}\n@@ -1001,8 +1010,7 @@ fdir_write_perfect_filter_82599(struct ixgbe_hw *hw,\n \t\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(2), 0);\n \t\t} else {\n \t\t\t/* tunnel mode */\n-\t\t\tif (input->formatted.tunnel_type !=\n-\t\t\t\tRTE_FDIR_TUNNEL_TYPE_NVGRE)\n+\t\t\tif (input->formatted.tunnel_type)\n \t\t\t\ttunnel_type = 0x80000000;\n \t\t\ttunnel_type |= addr_high;\n \t\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(0), addr_low);\n@@ -1010,6 +1018,9 @@ fdir_write_perfect_filter_82599(struct ixgbe_hw *hw,\n \t\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRSIPv6(2),\n \t\t\t\t\tinput->formatted.tni_vni);\n \t\t}\n+\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRIPSA, 0);\n+\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRIPDA, 0);\n+\t\tIXGBE_WRITE_REG(hw, IXGBE_FDIRPORT, 0);\n \t}\n \n \t/* record vlan (little-endian) and flex_bytes(big-endian) */\ndiff --git a/drivers/net/ixgbe/ixgbe_flow.c b/drivers/net/ixgbe/ixgbe_flow.c\nindex f47f125..eff907c 100644\n--- a/drivers/net/ixgbe/ixgbe_flow.c\n+++ b/drivers/net/ixgbe/ixgbe_flow.c\n@@ -2437,7 +2437,7 @@ ixgbe_parse_fdir_filter_tunnel(const struct rte_flow_attr *attr,\n \t/* Get the VxLAN info */\n \tif (item->type == RTE_FLOW_ITEM_TYPE_VXLAN) {\n \t\trule->ixgbe_fdir.formatted.tunnel_type =\n-\t\t\tRTE_FDIR_TUNNEL_TYPE_VXLAN;\n+\t\t\t\tIXGBE_FDIR_VXLAN_TUNNEL_TYPE;\n \n \t\t/* Only care about VNI, others should be masked. */\n \t\tif (!item->mask) {\n@@ -2495,7 +2495,7 @@ ixgbe_parse_fdir_filter_tunnel(const struct rte_flow_attr *attr,\n \t/* Get the NVGRE info */\n \tif (item->type == RTE_FLOW_ITEM_TYPE_NVGRE) {\n \t\trule->ixgbe_fdir.formatted.tunnel_type =\n-\t\t\tRTE_FDIR_TUNNEL_TYPE_NVGRE;\n+\t\t\t\tIXGBE_FDIR_NVGRE_TUNNEL_TYPE;\n \n \t\t/**\n \t\t * Only care about flags0, flags1, protocol and TNI,\n",
    "prefixes": [
        "v3"
    ]
}