get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 66543,
    "url": "https://patches.dpdk.org/api/patches/66543/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20200311122608.1262-1-adamx.dybkowski@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": "<20200311122608.1262-1-adamx.dybkowski@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20200311122608.1262-1-adamx.dybkowski@intel.com",
    "date": "2020-03-11T12:26:06",
    "name": "[1/3] crypto/qat: improve out-of-place conditional check",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "a9f89b31b71aef569eb790d0813d1ce1d6228a74",
    "submitter": {
        "id": 1322,
        "url": "https://patches.dpdk.org/api/people/1322/?format=api",
        "name": "Dybkowski, AdamX",
        "email": "adamx.dybkowski@intel.com"
    },
    "delegate": {
        "id": 6690,
        "url": "https://patches.dpdk.org/api/users/6690/?format=api",
        "username": "akhil",
        "first_name": "akhil",
        "last_name": "goyal",
        "email": "gakhil@marvell.com"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20200311122608.1262-1-adamx.dybkowski@intel.com/mbox/",
    "series": [
        {
            "id": 8884,
            "url": "https://patches.dpdk.org/api/series/8884/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=8884",
            "date": "2020-03-11T12:26:06",
            "name": "[1/3] crypto/qat: improve out-of-place conditional check",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/8884/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/66543/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/66543/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 A4D99A056E;\n\tWed, 11 Mar 2020 13:28:16 +0100 (CET)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 229DB1BFF5;\n\tWed, 11 Mar 2020 13:28:16 +0100 (CET)",
            "from mga04.intel.com (mga04.intel.com [192.55.52.120])\n by dpdk.org (Postfix) with ESMTP id AB678FEB\n for <dev@dpdk.org>; Wed, 11 Mar 2020 13:28:14 +0100 (CET)",
            "from fmsmga002.fm.intel.com ([10.253.24.26])\n by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n 11 Mar 2020 05:28:11 -0700",
            "from adamdybx-mobl.ger.corp.intel.com (HELO\n addy-VirtualBox.ger.corp.intel.com) ([10.104.121.4])\n by fmsmga002.fm.intel.com with ESMTP; 11 Mar 2020 05:28:09 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.70,540,1574150400\"; d=\"scan'208\";a=\"277356857\"",
        "From": "Adam Dybkowski <adamx.dybkowski@intel.com>",
        "To": "dev@dpdk.org, fiona.trahe@intel.com, akhil.goyal@nxp.com,\n adamx.dybkowski@intel.com",
        "Date": "Wed, 11 Mar 2020 13:26:06 +0100",
        "Message-Id": "<20200311122608.1262-1-adamx.dybkowski@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "Subject": "[dpdk-dev] [PATCH 1/3] crypto/qat: improve out-of-place conditional\n\tcheck",
        "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": "From: Fiona Trahe <fiona.trahe@intel.com>\n\nImprove case where application set m_dst to same as m_src\nso really an in-place operation, though would have been treated\nas out-of-place. No functional change but this path can now benefit\nfrom DMA alignment.\n\nSigned-off-by: Fiona Trahe <fiona.trahe@intel.com>\n---\n drivers/crypto/qat/qat_sym.c | 8 +++++---\n 1 file changed, 5 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/drivers/crypto/qat/qat_sym.c b/drivers/crypto/qat/qat_sym.c\nindex 5c9904cbf..cecced66d 100644\n--- a/drivers/crypto/qat/qat_sym.c\n+++ b/drivers/crypto/qat/qat_sym.c\n@@ -62,7 +62,8 @@ qat_bpicipher_preprocess(struct qat_sym_session *ctx,\n \t\tlast_block = (uint8_t *) rte_pktmbuf_mtod_offset(sym_op->m_src,\n \t\t\t\tuint8_t *, last_block_offset);\n \n-\t\tif (unlikely(sym_op->m_dst != NULL))\n+\t\tif (unlikely((sym_op->m_dst != NULL)\n+\t\t\t\t&& (sym_op->m_dst != sym_op->m_src)))\n \t\t\t/* out-of-place operation (OOP) */\n \t\t\tdst = (uint8_t *) rte_pktmbuf_mtod_offset(sym_op->m_dst,\n \t\t\t\t\t\tuint8_t *, last_block_offset);\n@@ -437,7 +438,8 @@ qat_sym_build_request(void *in_op, uint8_t *out_msg,\n \tif (unlikely(min_ofs >= rte_pktmbuf_data_len(op->sym->m_src) && do_sgl))\n \t\tmin_ofs = 0;\n \n-\tif (unlikely(op->sym->m_dst != NULL)) {\n+\tif (unlikely((op->sym->m_dst != NULL) &&\n+\t\t\t(op->sym->m_dst != op->sym->m_src))) {\n \t\t/* Out-of-place operation (OOP)\n \t\t * Don't align DMA start. DMA the minimum data-set\n \t\t * so as not to overwrite data in dest buffer\n@@ -565,7 +567,7 @@ qat_sym_build_request(void *in_op, uint8_t *out_msg,\n \t\t\treturn ret;\n \t\t}\n \n-\t\tif (likely(op->sym->m_dst == NULL))\n+\t\tif (in_place)\n \t\t\tqat_req->comn_mid.dest_data_addr =\n \t\t\t\tqat_req->comn_mid.src_data_addr =\n \t\t\t\tcookie->qat_sgl_src_phys_addr;\n",
    "prefixes": [
        "1/3"
    ]
}