get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 64296,
    "url": "http://patches.dpdk.org/api/patches/64296/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1578500161-20156-4-git-send-email-viacheslavo@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": "<1578500161-20156-4-git-send-email-viacheslavo@mellanox.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1578500161-20156-4-git-send-email-viacheslavo@mellanox.com",
    "date": "2020-01-08T16:16:00",
    "name": "[3/4] net/mlx5: add free on completion queue",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "211d5d51ac2307a9e88cbad8b595e2310e1a6e8b",
    "submitter": {
        "id": 1102,
        "url": "http://patches.dpdk.org/api/people/1102/?format=api",
        "name": "Slava Ovsiienko",
        "email": "viacheslavo@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/1578500161-20156-4-git-send-email-viacheslavo@mellanox.com/mbox/",
    "series": [
        {
            "id": 8020,
            "url": "http://patches.dpdk.org/api/series/8020/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=8020",
            "date": "2020-01-08T16:15:57",
            "name": "net/mlx5: remove Tx descriptor reserved field usage",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/8020/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/64296/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/64296/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Received": [
            "from dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 7535AA04F3;\n\tWed,  8 Jan 2020 17:16:40 +0100 (CET)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id C16701DAC8;\n\tWed,  8 Jan 2020 17:16:29 +0100 (CET)",
            "from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129])\n by dpdk.org (Postfix) with ESMTP id A60241DAC8\n for <dev@dpdk.org>; Wed,  8 Jan 2020 17:16:28 +0100 (CET)",
            "from Internal Mail-Server by MTLPINE1 (envelope-from\n viacheslavo@mellanox.com)\n with ESMTPS (AES256-SHA encrypted); 8 Jan 2020 18:16:26 +0200",
            "from pegasus11.mtr.labs.mlnx (pegasus11.mtr.labs.mlnx\n [10.210.16.104])\n by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id 008GGQuc000812;\n Wed, 8 Jan 2020 18:16:26 +0200",
            "from pegasus11.mtr.labs.mlnx (localhost [127.0.0.1])\n by pegasus11.mtr.labs.mlnx (8.14.7/8.14.7) with ESMTP id 008GGQIn020238;\n Wed, 8 Jan 2020 16:16:26 GMT",
            "(from viacheslavo@localhost)\n by pegasus11.mtr.labs.mlnx (8.14.7/8.14.7/Submit) id 008GGQTj020237;\n Wed, 8 Jan 2020 16:16:26 GMT"
        ],
        "X-Authentication-Warning": "pegasus11.mtr.labs.mlnx: viacheslavo set sender to\n viacheslavo@mellanox.com using -f",
        "From": "Viacheslav Ovsiienko <viacheslavo@mellanox.com>",
        "To": "dev@dpdk.org",
        "Cc": "matan@mellanox.com, rasland@mellanox.com, orika@mellanox.com",
        "Date": "Wed,  8 Jan 2020 16:16:00 +0000",
        "Message-Id": "<1578500161-20156-4-git-send-email-viacheslavo@mellanox.com>",
        "X-Mailer": "git-send-email 1.8.3.1",
        "In-Reply-To": "<1578500161-20156-1-git-send-email-viacheslavo@mellanox.com>",
        "References": "<1578500161-20156-1-git-send-email-viacheslavo@mellanox.com>",
        "Subject": "[dpdk-dev] [PATCH 3/4] net/mlx5: add free on completion queue",
        "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 <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 <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "The new software manged entity is introduced in Tx datapath\n- free on completion queue. This queue keeps the information\nhow many buffers stored in elts array must freed on send\ncomletion. Each element of the queue contains transmitting\ndescriptor index to be in synch with completion entries (in\ndebug build only) and the index in elts array to free buffers.\n\nSigned-off-by: Viacheslav Ovsiienko <viacheslavo@mellanox.com>\nAcked-by: Matan Azrad <matan@mellanox.com>\n---\n drivers/net/mlx5/mlx5_rxtx.h |  5 +++++\n drivers/net/mlx5/mlx5_txq.c  | 17 +++++++++++++++++\n 2 files changed, 22 insertions(+)",
    "diff": "diff --git a/drivers/net/mlx5/mlx5_rxtx.h b/drivers/net/mlx5/mlx5_rxtx.h\nindex 8a2185a..ee1895b 100644\n--- a/drivers/net/mlx5/mlx5_rxtx.h\n+++ b/drivers/net/mlx5/mlx5_rxtx.h\n@@ -297,6 +297,11 @@ struct mlx5_txq_data {\n \tstruct mlx5_mr_ctrl mr_ctrl; /* MR control descriptor. */\n \tstruct mlx5_wqe *wqes; /* Work queue. */\n \tstruct mlx5_wqe *wqes_end; /* Work queue array limit. */\n+#ifdef NDEBUG\n+\tuint32_t *fcqs; /* Free completion queue. */\n+#else\n+\tuint32_t *fcqs; /* Free completion queue (debug extended). */\n+#endif\n \tvolatile struct mlx5_cqe *cqes; /* Completion queue. */\n \tvolatile uint32_t *qp_db; /* Work queue doorbell. */\n \tvolatile uint32_t *cq_db; /* Completion queue doorbell. */\ndiff --git a/drivers/net/mlx5/mlx5_txq.c b/drivers/net/mlx5/mlx5_txq.c\nindex abe0947..5e6a605 100644\n--- a/drivers/net/mlx5/mlx5_txq.c\n+++ b/drivers/net/mlx5/mlx5_txq.c\n@@ -724,6 +724,19 @@ struct mlx5_txq_obj *\n \ttxq_data->wqe_pi = 0;\n \ttxq_data->wqe_comp = 0;\n \ttxq_data->wqe_thres = txq_data->wqe_s / MLX5_TX_COMP_THRESH_INLINE_DIV;\n+\ttxq_data->fcqs = rte_calloc_socket(__func__,\n+\t\t\t\t\t   txq_data->cqe_s,\n+\t\t\t\t\t   sizeof(*txq_data->fcqs),\n+\t\t\t\t\t   RTE_CACHE_LINE_SIZE,\n+\t\t\t\t\t   txq_ctrl->socket);\n+\tif (!txq_data->fcqs) {\n+\t\tDRV_LOG(ERR, \"port %u Tx queue %u cannot allocate memory (FCQ)\",\n+\t\t\tdev->data->port_id, idx);\n+\t\trte_errno = ENOMEM;\n+\t\tgoto error;\n+\t}\n+\ttxq_data->fcq_head = 0;\n+\ttxq_data->fcq_tail = 0;\n #ifdef HAVE_IBV_FLOW_DV_SUPPORT\n \t/*\n \t * If using DevX need to query and store TIS transport domain value.\n@@ -772,6 +785,8 @@ struct mlx5_txq_obj *\n \t\tclaim_zero(mlx5_glue->destroy_cq(tmpl.cq));\n \tif (tmpl.qp)\n \t\tclaim_zero(mlx5_glue->destroy_qp(tmpl.qp));\n+\tif (txq_data && txq_data->fcqs)\n+\t\trte_free(txq_data->fcqs);\n \tif (txq_obj)\n \t\trte_free(txq_obj);\n \tpriv->verbs_alloc_ctx.type = MLX5_VERBS_ALLOC_TYPE_NONE;\n@@ -826,6 +841,8 @@ struct mlx5_txq_obj *\n \t\t} else {\n \t\t\tclaim_zero(mlx5_glue->destroy_qp(txq_obj->qp));\n \t\t\tclaim_zero(mlx5_glue->destroy_cq(txq_obj->cq));\n+\t\t\t\tif (txq_obj->txq_ctrl->txq.fcqs)\n+\t\t\t\t\trte_free(txq_obj->txq_ctrl->txq.fcqs);\n \t\t}\n \t\tLIST_REMOVE(txq_obj, next);\n \t\trte_free(txq_obj);\n",
    "prefixes": [
        "3/4"
    ]
}