get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 57388,
    "url": "https://patches.dpdk.org/api/patches/57388/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/0f1b3637c93d6f923ebcd4c56cc333959a570881.1564737358.git.jackmin@mellanox.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": "<0f1b3637c93d6f923ebcd4c56cc333959a570881.1564737358.git.jackmin@mellanox.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/0f1b3637c93d6f923ebcd4c56cc333959a570881.1564737358.git.jackmin@mellanox.com",
    "date": "2019-08-02T09:18:23",
    "name": "net/mlx5: fix VLAN inner type matching on DR/DV",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "56d74d80ac688d6c500ab80b0063ebc83b009968",
    "submitter": {
        "id": 1065,
        "url": "https://patches.dpdk.org/api/people/1065/?format=api",
        "name": "Xiaoyu Min",
        "email": "jackmin@mellanox.com"
    },
    "delegate": {
        "id": 3268,
        "url": "https://patches.dpdk.org/api/users/3268/?format=api",
        "username": "rasland",
        "first_name": "Raslan",
        "last_name": "Darawsheh",
        "email": "rasland@nvidia.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/0f1b3637c93d6f923ebcd4c56cc333959a570881.1564737358.git.jackmin@mellanox.com/mbox/",
    "series": [
        {
            "id": 5890,
            "url": "https://patches.dpdk.org/api/series/5890/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=5890",
            "date": "2019-08-02T09:18:23",
            "name": "net/mlx5: fix VLAN inner type matching on DR/DV",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/5890/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/57388/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/57388/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 154841C234;\n\tFri,  2 Aug 2019 11:18:46 +0200 (CEST)",
            "from git-send-mailer.rdmz.labs.mlnx (unknown [37.142.13.130])\n\tby dpdk.org (Postfix) with ESMTP id CCEBC1C231\n\tfor <dev@dpdk.org>; Fri,  2 Aug 2019 11:18:44 +0200 (CEST)"
        ],
        "From": "Xiaoyu Min <jackmin@mellanox.com>",
        "To": "Shahaf Shuler <shahafs@mellanox.com>, Yongseok Koh <yskoh@mellanox.com>, \n\tViacheslav Ovsiienko <viacheslavo@mellanox.com>",
        "Cc": "dev@dpdk.org,\n\torika@mellanox.com",
        "Date": "Fri,  2 Aug 2019 17:18:23 +0800",
        "Message-Id": "<0f1b3637c93d6f923ebcd4c56cc333959a570881.1564737358.git.jackmin@mellanox.com>",
        "X-Mailer": "git-send-email 2.21.0",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Subject": "[dpdk-dev] [PATCH] net/mlx5: fix VLAN inner type matching on DR/DV",
        "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://mails.dpdk.org/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "The rte_flow_item_vlan has the inner_type, which is missing on\nDR/DV flow engine.\n\nBy adding this support, the example testpmd commands could be:\n\n - matching all vlan traffic with id 2:\n\n testpmd> flow create 0 ingress pattern eth / vlan vid is 2 / end\n          actions queue index 2 / end\n\n - matching all ipv4 traffic in vlan with id 2:\n\n testpmd> flow create 0 ingress pattern eth / vlan vid is 2\n          inner_type is 0x0800 / end actions queue index 2 / end\n\nFixes: fc2c498ccb94 (\"net/mlx5: add Direct Verbs translate items\")\nCc: orika@mellanox.com\n\nSigned-off-by: Xiaoyu Min <jackmin@mellanox.com>\n---\n drivers/net/mlx5/mlx5_flow_dv.c | 10 +++++-----\n 1 file changed, 5 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c\nindex 9c0a2613d5..f786c7a2c4 100644\n--- a/drivers/net/mlx5/mlx5_flow_dv.c\n+++ b/drivers/net/mlx5/mlx5_flow_dv.c\n@@ -3469,10 +3469,6 @@ flow_dv_translate_item_vlan(struct mlx5_flow *dev_flow,\n {\n \tconst struct rte_flow_item_vlan *vlan_m = item->mask;\n \tconst struct rte_flow_item_vlan *vlan_v = item->spec;\n-\tconst struct rte_flow_item_vlan nic_mask = {\n-\t\t.tci = RTE_BE16(0x0fff),\n-\t\t.inner_type = RTE_BE16(0xffff),\n-\t};\n \tvoid *headers_m;\n \tvoid *headers_v;\n \tuint16_t tci_m;\n@@ -3481,7 +3477,7 @@ flow_dv_translate_item_vlan(struct mlx5_flow *dev_flow,\n \tif (!vlan_v)\n \t\treturn;\n \tif (!vlan_m)\n-\t\tvlan_m = &nic_mask;\n+\t\tvlan_m = &rte_flow_item_vlan_mask;\n \tif (inner) {\n \t\theaders_m = MLX5_ADDR_OF(fte_match_param, matcher,\n \t\t\t\t\t inner_headers);\n@@ -3507,6 +3503,10 @@ flow_dv_translate_item_vlan(struct mlx5_flow *dev_flow,\n \tMLX5_SET(fte_match_set_lyr_2_4, headers_v, first_cfi, tci_v >> 12);\n \tMLX5_SET(fte_match_set_lyr_2_4, headers_m, first_prio, tci_m >> 13);\n \tMLX5_SET(fte_match_set_lyr_2_4, headers_v, first_prio, tci_v >> 13);\n+\tMLX5_SET(fte_match_set_lyr_2_4, headers_m, ethertype,\n+\t\t rte_be_to_cpu_16(vlan_m->inner_type));\n+\tMLX5_SET(fte_match_set_lyr_2_4, headers_v, ethertype,\n+\t\t rte_be_to_cpu_16(vlan_m->inner_type & vlan_v->inner_type));\n }\n \n /**\n",
    "prefixes": []
}