get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 58416,
    "url": "http://patches.dpdk.org/api/patches/58416/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/8e64226330f14eb028610514ae361e9b3be35978.1567436185.git.motih@mellanox.com/",
    "project": {
        "id": 1,
        "url": "http://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": "<8e64226330f14eb028610514ae361e9b3be35978.1567436185.git.motih@mellanox.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/8e64226330f14eb028610514ae361e9b3be35978.1567436185.git.motih@mellanox.com",
    "date": "2019-09-02T15:00:46",
    "name": "[v3,1/7] net/mlx5: support for an action search in a list",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "b4981ec56ddef7f48a1d7108061b7432297eb355",
    "submitter": {
        "id": 748,
        "url": "http://patches.dpdk.org/api/people/748/?format=api",
        "name": "Moti Haimovsky",
        "email": "motih@mellanox.com"
    },
    "delegate": {
        "id": 3268,
        "url": "http://patches.dpdk.org/api/users/3268/?format=api",
        "username": "rasland",
        "first_name": "Raslan",
        "last_name": "Darawsheh",
        "email": "rasland@nvidia.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/8e64226330f14eb028610514ae361e9b3be35978.1567436185.git.motih@mellanox.com/mbox/",
    "series": [
        {
            "id": 6207,
            "url": "http://patches.dpdk.org/api/series/6207/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=6207",
            "date": "2019-09-02T15:00:48",
            "name": "net/mlx5: support for flow action on VLAN header",
            "version": 3,
            "mbox": "http://patches.dpdk.org/series/6207/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/58416/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/58416/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 ED2F21EA3D;\n\tMon,  2 Sep 2019 17:01:03 +0200 (CEST)",
            "from git-send-mailer.rdmz.labs.mlnx (unknown [37.142.13.130])\n\tby dpdk.org (Postfix) with ESMTP id 34A3F1E945\n\tfor <dev@dpdk.org>; Mon,  2 Sep 2019 17:00:55 +0200 (CEST)"
        ],
        "From": "Moti Haimovsky <motih@mellanox.com>",
        "To": "viacheslavo@mellanox.com,\n\trasland@mellanox.com",
        "Cc": "dev@dpdk.org",
        "Date": "Mon,  2 Sep 2019 18:00:46 +0300",
        "Message-Id": "<8e64226330f14eb028610514ae361e9b3be35978.1567436185.git.motih@mellanox.com>",
        "X-Mailer": "git-send-email 1.7.1",
        "In-Reply-To": "<cover.1567436185.git.motih@mellanox.com>",
        "References": "<cover.1567332903.git.motih@mellanox.com>\n\t<cover.1567436185.git.motih@mellanox.com>",
        "Subject": "[dpdk-dev] [PATCH v3 1/7] net/mlx5: support for an action search in\n\ta list",
        "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": "This commit adds a helper routine that supports searching for a\nspecific action in a list of actions.\n\nSigned-off-by: Moti Haimovsky <motih@mellanox.com>\n---\n drivers/net/mlx5/mlx5_flow.c | 23 +++++++++++++++++++++++\n drivers/net/mlx5/mlx5_flow.h |  3 +++\n 2 files changed, 26 insertions(+)",
    "diff": "diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c\nindex 9d2c8c9..92f33d8 100644\n--- a/drivers/net/mlx5/mlx5_flow.c\n+++ b/drivers/net/mlx5/mlx5_flow.c\n@@ -689,6 +689,29 @@ uint32_t mlx5_flow_adjust_priority(struct rte_eth_dev *dev, int32_t priority,\n }\n \n /*\n+ * return a pointer to the desired action in the list of actions.\n+ *\n+ * @param[in] actions\n+ *   The list of actions to search the action in.\n+ * @param[in] action\n+ *   The action to find.\n+ *\n+ * @return\n+ *   Pointer to the action in the list, if found. NULL otherwise.\n+ */\n+const struct rte_flow_action *\n+mlx5_flow_find_action(const struct rte_flow_action *actions,\n+\t\t      enum rte_flow_action_type action)\n+{\n+\tif (actions == NULL)\n+\t\treturn NULL;\n+\tfor (; actions->type != RTE_FLOW_ACTION_TYPE_END; actions++)\n+\t\tif (actions->type == action)\n+\t\t\treturn actions;\n+\treturn NULL;\n+}\n+\n+/*\n  * Validate the flag action.\n  *\n  * @param[in] action_flags\ndiff --git a/drivers/net/mlx5/mlx5_flow.h b/drivers/net/mlx5/mlx5_flow.h\nindex 822ff36..8d193b6 100644\n--- a/drivers/net/mlx5/mlx5_flow.h\n+++ b/drivers/net/mlx5/mlx5_flow.h\n@@ -442,6 +442,9 @@ uint64_t mlx5_flow_hashfields_adjust(struct mlx5_flow *dev_flow, int tunnel,\n \t\t\t\t     uint64_t hash_fields);\n uint32_t mlx5_flow_adjust_priority(struct rte_eth_dev *dev, int32_t priority,\n \t\t\t\t   uint32_t subpriority);\n+const struct rte_flow_action *mlx5_flow_find_action\n+\t\t\t\t\t(const struct rte_flow_action *actions,\n+\t\t\t\t\t enum rte_flow_action_type action);\n int mlx5_flow_validate_action_count(struct rte_eth_dev *dev,\n \t\t\t\t    const struct rte_flow_attr *attr,\n \t\t\t\t    struct rte_flow_error *error);\n",
    "prefixes": [
        "v3",
        "1/7"
    ]
}