get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 102422,
    "url": "http://patches.dpdk.org/api/patches/102422/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20211020112754.1270163-3-gakhil@marvell.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": "<20211020112754.1270163-3-gakhil@marvell.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20211020112754.1270163-3-gakhil@marvell.com",
    "date": "2021-10-20T11:27:48",
    "name": "[v4,2/8] cryptodev: allocate max space for internal qp array",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "81c6c01ab33cefa3ff124e481526eea7fca99f6c",
    "submitter": {
        "id": 2094,
        "url": "http://patches.dpdk.org/api/people/2094/?format=api",
        "name": "Akhil Goyal",
        "email": "gakhil@marvell.com"
    },
    "delegate": {
        "id": 6690,
        "url": "http://patches.dpdk.org/api/users/6690/?format=api",
        "username": "akhil",
        "first_name": "akhil",
        "last_name": "goyal",
        "email": "gakhil@marvell.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20211020112754.1270163-3-gakhil@marvell.com/mbox/",
    "series": [
        {
            "id": 19839,
            "url": "http://patches.dpdk.org/api/series/19839/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=19839",
            "date": "2021-10-20T11:27:46",
            "name": "cryptodev: hide internal structures",
            "version": 4,
            "mbox": "http://patches.dpdk.org/series/19839/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/102422/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/102422/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 mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 997D5A0C43;\n\tWed, 20 Oct 2021 13:28:32 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 0D1D94118F;\n\tWed, 20 Oct 2021 13:28:31 +0200 (CEST)",
            "from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com\n [67.231.156.173])\n by mails.dpdk.org (Postfix) with ESMTP id 26509411FD\n for <dev@dpdk.org>; Wed, 20 Oct 2021 13:28:30 +0200 (CEST)",
            "from pps.filterd (m0045851.ppops.net [127.0.0.1])\n by mx0b-0016f401.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id\n 19K8kiWp020984;\n Wed, 20 Oct 2021 04:28:23 -0700",
            "from dc5-exch02.marvell.com ([199.233.59.182])\n by mx0b-0016f401.pphosted.com with ESMTP id 3bt05g4pv6-1\n (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT);\n Wed, 20 Oct 2021 04:28:23 -0700",
            "from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com\n (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18;\n Wed, 20 Oct 2021 04:28:21 -0700",
            "from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com\n (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.18 via Frontend\n Transport; Wed, 20 Oct 2021 04:28:21 -0700",
            "from localhost.localdomain (unknown [10.28.36.185])\n by maili.marvell.com (Postfix) with ESMTP id 0D8953F7098;\n Wed, 20 Oct 2021 04:28:14 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com;\n h=from : to : cc :\n subject : date : message-id : in-reply-to : references : mime-version :\n content-transfer-encoding : content-type; s=pfpt0220;\n bh=nzybg0JJejNCCop6BqF7461gKDp7Ql8YPonwXvLx9is=;\n b=XW228ngzjZfGaOpqGenl0pnWIvTehvnMVunRNfgn3ReeGQhFcQ4hso8NB3YpXcGYujRn\n WyldmsLUtfTBs1CWx3sPrix1VAVKelXagmzKfgs0s7ei/7300ABWOupa+YAMFxLRI7z1\n n2779mlEgyiPRpm9nh69vs1ty7OIH9XsVUFLaTc1Kh5MNMrx6OAajjbsTPB2+eo7T06Z\n rMBtvu41l0tzmxc+VZ5q2JXWMAJ5g/rBR6qG83hb1e3IY1tFrhma/X047FnPPeMrKpOZ\n NZjUFtuDePGw7HoXdOhgkCQRO8K95fzmJiDNyVcKFmiG3CpaE+AEgR6I4XPTSqTOqrka 1A==",
        "From": "Akhil Goyal <gakhil@marvell.com>",
        "To": "<dev@dpdk.org>",
        "CC": "<thomas@monjalon.net>, <david.marchand@redhat.com>,\n <hemant.agrawal@nxp.com>, <anoobj@marvell.com>,\n <pablo.de.lara.guarch@intel.com>, <fiona.trahe@intel.com>,\n <declan.doherty@intel.com>, <matan@nvidia.com>, <g.singh@nxp.com>,\n <roy.fan.zhang@intel.com>, <jianjay.zhou@huawei.com>,\n <asomalap@amd.com>, <ruifeng.wang@arm.com>,\n <konstantin.ananyev@intel.com>, <radu.nicolau@intel.com>,\n <ajit.khaparde@broadcom.com>, <rnagadheeraj@marvell.com>,\n <adwivedi@marvell.com>, <ciara.power@intel.com>,\n Akhil Goyal <gakhil@marvell.com>",
        "Date": "Wed, 20 Oct 2021 16:57:48 +0530",
        "Message-ID": "<20211020112754.1270163-3-gakhil@marvell.com>",
        "X-Mailer": "git-send-email 2.25.1",
        "In-Reply-To": "<20211020112754.1270163-1-gakhil@marvell.com>",
        "References": "<20211018144201.2028022-1-gakhil@marvell.com>\n <20211020112754.1270163-1-gakhil@marvell.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "Content-Type": "text/plain",
        "X-Proofpoint-GUID": "bijQ647aR5uECrNrlbiCn9BUZGHrO9Hy",
        "X-Proofpoint-ORIG-GUID": "bijQ647aR5uECrNrlbiCn9BUZGHrO9Hy",
        "X-Proofpoint-Virus-Version": "vendor=baseguard\n engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.0.607.475\n definitions=2021-10-20_04,2021-10-20_02,2020-04-07_01",
        "Subject": "[dpdk-dev] [PATCH v4 2/8] cryptodev: allocate max space for\n internal qp array",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "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": "At queue_pair config stage, allocate memory for maximum\nnumber of queue pair pointers that a device can support.\n\nThis will allow fast path APIs(enqueue_burst/dequeue_burst) to\nrefer pointer to internal QP data without checking for currently\nconfigured QPs.\nThis is required to hide the rte_cryptodev and rte_cryptodev_data\nstructure from user.\n\nSigned-off-by: Akhil Goyal <gakhil@marvell.com>\nAcked-by: Fan Zhang <roy.fan.zhang@intel.com>\nAcked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>\n---\n lib/cryptodev/rte_cryptodev.c | 21 +++------------------\n 1 file changed, 3 insertions(+), 18 deletions(-)",
    "diff": "diff --git a/lib/cryptodev/rte_cryptodev.c b/lib/cryptodev/rte_cryptodev.c\nindex b913c434c5..eb86e629aa 100644\n--- a/lib/cryptodev/rte_cryptodev.c\n+++ b/lib/cryptodev/rte_cryptodev.c\n@@ -978,7 +978,8 @@ rte_cryptodev_queue_pairs_config(struct rte_cryptodev *dev, uint16_t nb_qpairs,\n \tif (dev->data->queue_pairs == NULL) { /* first time configuration */\n \t\tdev->data->queue_pairs = rte_zmalloc_socket(\n \t\t\t\t\"cryptodev->queue_pairs\",\n-\t\t\t\tsizeof(dev->data->queue_pairs[0]) * nb_qpairs,\n+\t\t\t\tsizeof(dev->data->queue_pairs[0]) *\n+\t\t\t\tdev_info.max_nb_queue_pairs,\n \t\t\t\tRTE_CACHE_LINE_SIZE, socket_id);\n \n \t\tif (dev->data->queue_pairs == NULL) {\n@@ -1001,25 +1002,9 @@ rte_cryptodev_queue_pairs_config(struct rte_cryptodev *dev, uint16_t nb_qpairs,\n \t\t\tret = (*dev->dev_ops->queue_pair_release)(dev, i);\n \t\t\tif (ret < 0)\n \t\t\t\treturn ret;\n+\t\t\tqp[i] = NULL;\n \t\t}\n \n-\t\tqp = rte_realloc(qp, sizeof(qp[0]) * nb_qpairs,\n-\t\t\t\tRTE_CACHE_LINE_SIZE);\n-\t\tif (qp == NULL) {\n-\t\t\tCDEV_LOG_ERR(\"failed to realloc qp meta data,\"\n-\t\t\t\t\t\t\" nb_queues %u\", nb_qpairs);\n-\t\t\treturn -(ENOMEM);\n-\t\t}\n-\n-\t\tif (nb_qpairs > old_nb_queues) {\n-\t\t\tuint16_t new_qs = nb_qpairs - old_nb_queues;\n-\n-\t\t\tmemset(qp + old_nb_queues, 0,\n-\t\t\t\tsizeof(qp[0]) * new_qs);\n-\t\t}\n-\n-\t\tdev->data->queue_pairs = qp;\n-\n \t}\n \tdev->data->nb_queue_pairs = nb_qpairs;\n \treturn 0;\n",
    "prefixes": [
        "v4",
        "2/8"
    ]
}