get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 109124,
    "url": "http://patches.dpdk.org/api/patches/109124/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20220404130617.5225-1-arkadiuszx.kusztal@intel.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": "<20220404130617.5225-1-arkadiuszx.kusztal@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20220404130617.5225-1-arkadiuszx.kusztal@intel.com",
    "date": "2022-04-04T13:06:16",
    "name": "[1/2] crypto/qat: refactor asym algorithm macros and logs",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "be76a61863413ff6849e6c2ea4c18ff556b5365c",
    "submitter": {
        "id": 452,
        "url": "http://patches.dpdk.org/api/people/452/?format=api",
        "name": "Arkadiusz Kusztal",
        "email": "arkadiuszx.kusztal@intel.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/20220404130617.5225-1-arkadiuszx.kusztal@intel.com/mbox/",
    "series": [
        {
            "id": 22343,
            "url": "http://patches.dpdk.org/api/series/22343/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=22343",
            "date": "2022-04-04T13:06:17",
            "name": "[1/2] crypto/qat: refactor asym algorithm macros and logs",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/22343/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/109124/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/109124/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 65CF9A0506;\n\tMon,  4 Apr 2022 15:06:54 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 99E9C42826;\n\tMon,  4 Apr 2022 15:06:50 +0200 (CEST)",
            "from mga18.intel.com (mga18.intel.com [134.134.136.126])\n by mails.dpdk.org (Postfix) with ESMTP id 8DBE04068C\n for <dev@dpdk.org>; Mon,  4 Apr 2022 15:06:46 +0200 (CEST)",
            "from orsmga006.jf.intel.com ([10.7.209.51])\n by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 04 Apr 2022 06:06:25 -0700",
            "from silpixa00400308.ir.intel.com ([10.237.214.95])\n by orsmga006.jf.intel.com with ESMTP; 04 Apr 2022 06:06:23 -0700"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1649077606; x=1680613606;\n h=from:to:cc:subject:date:message-id;\n bh=YkS/G38bYipa26IllYE0iuyXhaTeLy64GNmMPzr3AJA=;\n b=eIa4KhxTz7cNl2oZ3w7uN6g/Hx/gT2CF5akF2oMXOpR4XOLLLYygSqCV\n nG5EPdoNx3YsZoZZj5S8wrBvWgjTBP1L4Y/Mkatp8S67nyZwduR1Ds2WE\n 1c9HwTR9Wx4DPYxZZQNyTJ6H9nmhSg5rBxmRwIL5iHY0Dc43GwDScrTr3\n V1KP3WbSwULLzthFFYh5e1NKxwiUoKXcipN8mNWT/EHqjeDDdhEpeciIa\n V1BzmuAUk4Rc1E11f/RuDGaUTuQvHBWwp37QoNRR9YW54dpvvx3XKCdDr\n bjcqzCK2bvriwP8hiRBfJU2AbQ2U2NLfDijNf330jqMn/GZ3YbSeUiW3G A==;",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6200,9189,10306\"; a=\"242650352\"",
            "E=Sophos;i=\"5.90,234,1643702400\"; d=\"scan'208\";a=\"242650352\"",
            "E=Sophos;i=\"5.90,234,1643702400\"; d=\"scan'208\";a=\"523573768\""
        ],
        "X-ExtLoop1": "1",
        "From": "Arek Kusztal <arkadiuszx.kusztal@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "gakhil@marvell.com, roy.fan.zhang@intel.com,\n Arek Kusztal <arkadiuszx.kusztal@intel.com>",
        "Subject": "[PATCH 1/2] crypto/qat: refactor asym algorithm macros and logs",
        "Date": "Mon,  4 Apr 2022 14:06:16 +0100",
        "Message-Id": "<20220404130617.5225-1-arkadiuszx.kusztal@intel.com>",
        "X-Mailer": "git-send-email 2.17.1",
        "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"
    },
    "content": "This commit unifies macros for asymmetric parameters,\ntherefore making code easier to maintain.\nIt additionally changes some of PMD output logs that\nright now can only be seen in debug mode.\n\nSigned-off-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>\n---\n drivers/crypto/qat/qat_asym.c | 230 ++++++++++++++++++------------------------\n drivers/crypto/qat/qat_asym.h |   3 +-\n drivers/crypto/qat/qat_ec.h   |   1 -\n 3 files changed, 101 insertions(+), 133 deletions(-)",
    "diff": "diff --git a/drivers/crypto/qat/qat_asym.c b/drivers/crypto/qat/qat_asym.c\nindex 479d5308cf..d2041b2efa 100644\n--- a/drivers/crypto/qat/qat_asym.c\n+++ b/drivers/crypto/qat/qat_asym.c\n@@ -34,7 +34,7 @@ static const struct rte_driver cryptodev_qat_asym_driver = {\n /*\n  * Macros with suffix _F are used with some of predefinded identifiers:\n  * - cookie->input_buffer\n- * - qat_alg_bytesize\n+ * - qat_func_alignsize\n  */\n #if RTE_LOG_DP_LEVEL >= RTE_LOG_DEBUG\n #define HEXDUMP(name, where, size) QAT_DP_HEXDUMP_LOG(DEBUG, name, \\\n@@ -43,8 +43,8 @@ static const struct rte_driver cryptodev_qat_asym_driver = {\n \t\t\t&where[idx * size], size)\n \n #define HEXDUMP_OFF_F(name, idx) QAT_DP_HEXDUMP_LOG(DEBUG, name, \\\n-\t\t\t&cookie->input_buffer[idx * qat_alg_bytesize], \\\n-\t\t\tqat_alg_bytesize)\n+\t\t\t&cookie->input_buffer[idx * qat_func_alignsize], \\\n+\t\t\tqat_func_alignsize)\n #else\n #define HEXDUMP(name, where, size)\n #define HEXDUMP_OFF(name, where, size, idx)\n@@ -69,36 +69,28 @@ static const struct rte_driver cryptodev_qat_asym_driver = {\n \t\t} \\\n \t} while (0)\n \n-#define SET_PKE_LN(where, what, how, idx) \\\n-\trte_memcpy(where[idx] + how - \\\n-\t\twhat.length, \\\n-\t\twhat.data, \\\n-\t\twhat.length)\n-\n-#define SET_PKE_LN_9A(where, what, how, idx) \\\n-\t\trte_memcpy(&where[idx * RTE_ALIGN_CEIL(how, 8)] + \\\n-\t\t\tRTE_ALIGN_CEIL(how, 8) - \\\n+#define SET_PKE_LN(what, how, idx) \\\n+\t\trte_memcpy(cookie->input_array[idx] + how - \\\n \t\t\twhat.length, \\\n \t\t\twhat.data, \\\n \t\t\twhat.length)\n \n-#define SET_PKE_LN_EC(where, what, how, idx) \\\n-\t\trte_memcpy(where[idx] + \\\n-\t\t\tRTE_ALIGN_CEIL(how, 8) - \\\n-\t\t\thow, \\\n-\t\t\twhat.data, \\\n-\t\t\thow)\n+#define SET_PKE_LN_EC(curve, p, idx) \\\n+\t\trte_memcpy(cookie->input_array[idx] + \\\n+\t\t\tqat_func_alignsize - curve.bytesize, \\\n+\t\t\tcurve.p.data, curve.bytesize)\n \n-#define SET_PKE_LN_9A_F(what, idx) \\\n-\t\trte_memcpy(&cookie->input_buffer[idx * qat_alg_bytesize] + \\\n-\t\t\tqat_alg_bytesize - what.length, \\\n+#define SET_PKE_9A_IN(what, idx) \\\n+\t\trte_memcpy(&cookie->input_buffer[idx * \\\n+\t\t\tqat_func_alignsize] + \\\n+\t\t\tqat_func_alignsize - what.length, \\\n \t\t\twhat.data, what.length)\n \n-#define SET_PKE_LN_EC_F(what, how, idx) \\\n+#define SET_PKE_9A_EC(curve, p, idx) \\\n \t\trte_memcpy(&cookie->input_buffer[idx * \\\n-\t\t\tRTE_ALIGN_CEIL(how, 8)] + \\\n-\t\t\tRTE_ALIGN_CEIL(how, 8) - how, \\\n-\t\t\twhat.data, how)\n+\t\t\tqat_func_alignsize] + \\\n+\t\t\tqat_func_alignsize - curve.bytesize, \\\n+\t\t\tcurve.p.data, curve.bytesize)\n \n static void\n request_init(struct icp_qat_fw_pke_request *qat_req)\n@@ -231,12 +223,9 @@ modexp_set_input(struct rte_crypto_asym_op *asym_op,\n \t}\n \talg_bytesize = qat_function.bytesize;\n \n-\tSET_PKE_LN(cookie->input_array, asym_op->modex.base,\n-\t\t\talg_bytesize, 0);\n-\tSET_PKE_LN(cookie->input_array, xform->modex.exponent,\n-\t\t\talg_bytesize, 1);\n-\tSET_PKE_LN(cookie->input_array, xform->modex.modulus,\n-\t\t\talg_bytesize, 2);\n+\tSET_PKE_LN(asym_op->modex.base, alg_bytesize, 0);\n+\tSET_PKE_LN(xform->modex.exponent, alg_bytesize, 1);\n+\tSET_PKE_LN(xform->modex.modulus, alg_bytesize, 2);\n \n \tcookie->alg_bytesize = alg_bytesize;\n \tqat_req->pke_hdr.cd_pars.func_id = func_id;\n@@ -290,10 +279,8 @@ modinv_set_input(struct rte_crypto_asym_op *asym_op,\n \t}\n \talg_bytesize = qat_function.bytesize;\n \n-\tSET_PKE_LN(cookie->input_array, asym_op->modinv.base,\n-\t\t\talg_bytesize, 0);\n-\tSET_PKE_LN(cookie->input_array, xform->modinv.modulus,\n-\t\t\talg_bytesize, 1);\n+\tSET_PKE_LN(asym_op->modinv.base, alg_bytesize, 0);\n+\tSET_PKE_LN(xform->modinv.modulus, alg_bytesize, 1);\n \n \tcookie->alg_bytesize = alg_bytesize;\n \tqat_req->pke_hdr.cd_pars.func_id = func_id;\n@@ -347,8 +334,7 @@ rsa_set_pub_input(struct rte_crypto_asym_op *asym_op,\n \tif (asym_op->rsa.op_type == RTE_CRYPTO_ASYM_OP_ENCRYPT) {\n \t\tswitch (asym_op->rsa.pad) {\n \t\tcase RTE_CRYPTO_RSA_PADDING_NONE:\n-\t\t\tSET_PKE_LN(cookie->input_array, asym_op->rsa.message,\n-\t\t\t\t\talg_bytesize, 0);\n+\t\t\tSET_PKE_LN(asym_op->rsa.message, alg_bytesize, 0);\n \t\t\tbreak;\n \t\tdefault:\n \t\t\tQAT_LOG(ERR,\n@@ -360,8 +346,7 @@ rsa_set_pub_input(struct rte_crypto_asym_op *asym_op,\n \t} else {\n \t\tswitch (asym_op->rsa.pad) {\n \t\tcase RTE_CRYPTO_RSA_PADDING_NONE:\n-\t\t\tSET_PKE_LN(cookie->input_array, asym_op->rsa.sign,\n-\t\t\t\t\talg_bytesize, 0);\n+\t\t\tSET_PKE_LN(asym_op->rsa.sign, alg_bytesize, 0);\n \t\t\tbreak;\n \t\tdefault:\n \t\t\tQAT_LOG(ERR,\n@@ -372,10 +357,8 @@ rsa_set_pub_input(struct rte_crypto_asym_op *asym_op,\n \t\t\t\talg_bytesize);\n \t}\n \n-\tSET_PKE_LN(cookie->input_array, xform->rsa.e,\n-\t\t\talg_bytesize, 1);\n-\tSET_PKE_LN(cookie->input_array, xform->rsa.n,\n-\t\t\talg_bytesize, 2);\n+\tSET_PKE_LN(xform->rsa.e, alg_bytesize, 1);\n+\tSET_PKE_LN(xform->rsa.n, alg_bytesize, 2);\n \n \tcookie->alg_bytesize = alg_bytesize;\n \tqat_req->pke_hdr.cd_pars.func_id = func_id;\n@@ -407,16 +390,11 @@ rsa_set_priv_input(struct rte_crypto_asym_op *asym_op,\n \t\tqat_req->input_param_count =\n \t\t\t\tQAT_ASYM_RSA_QT_NUM_IN_PARAMS;\n \n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.qt.p,\n-\t\t\t(alg_bytesize >> 1), 1);\n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.qt.q,\n-\t\t\t(alg_bytesize >> 1), 2);\n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.qt.dP,\n-\t\t\t(alg_bytesize >> 1), 3);\n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.qt.dQ,\n-\t\t\t(alg_bytesize >> 1), 4);\n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.qt.qInv,\n-\t\t\t(alg_bytesize >> 1), 5);\n+\t\tSET_PKE_LN(xform->rsa.qt.p, (alg_bytesize >> 1), 1);\n+\t\tSET_PKE_LN(xform->rsa.qt.q, (alg_bytesize >> 1), 2);\n+\t\tSET_PKE_LN(xform->rsa.qt.dP, (alg_bytesize >> 1), 3);\n+\t\tSET_PKE_LN(xform->rsa.qt.dQ, (alg_bytesize >> 1), 4);\n+\t\tSET_PKE_LN(xform->rsa.qt.qInv, (alg_bytesize >> 1), 5);\n \n \t\tHEXDUMP(\"RSA p\", cookie->input_array[1],\n \t\t\t\talg_bytesize);\n@@ -438,10 +416,8 @@ rsa_set_priv_input(struct rte_crypto_asym_op *asym_op,\n \t\t}\n \t\talg_bytesize = qat_function.bytesize;\n \n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.d,\n-\t\t\talg_bytesize, 1);\n-\t\tSET_PKE_LN(cookie->input_array, xform->rsa.n,\n-\t\t\talg_bytesize, 2);\n+\t\tSET_PKE_LN(xform->rsa.d, alg_bytesize, 1);\n+\t\tSET_PKE_LN(xform->rsa.n, alg_bytesize, 2);\n \n \t\tHEXDUMP(\"RSA d\", cookie->input_array[1],\n \t\t\t\talg_bytesize);\n@@ -456,8 +432,7 @@ rsa_set_priv_input(struct rte_crypto_asym_op *asym_op,\n \t\t\tRTE_CRYPTO_ASYM_OP_DECRYPT) {\n \t\tswitch (asym_op->rsa.pad) {\n \t\tcase RTE_CRYPTO_RSA_PADDING_NONE:\n-\t\t\tSET_PKE_LN(cookie->input_array, asym_op->rsa.cipher,\n-\t\t\t\talg_bytesize, 0);\n+\t\t\tSET_PKE_LN(asym_op->rsa.cipher,\talg_bytesize, 0);\n \t\t\tHEXDUMP(\"RSA ciphertext\", cookie->input_array[0],\n \t\t\t\talg_bytesize);\n \t\t\tbreak;\n@@ -471,8 +446,7 @@ rsa_set_priv_input(struct rte_crypto_asym_op *asym_op,\n \t\t\tRTE_CRYPTO_ASYM_OP_SIGN) {\n \t\tswitch (asym_op->rsa.pad) {\n \t\tcase RTE_CRYPTO_RSA_PADDING_NONE:\n-\t\t\tSET_PKE_LN(cookie->input_array, asym_op->rsa.message,\n-\t\t\t\talg_bytesize, 0);\n+\t\t\tSET_PKE_LN(asym_op->rsa.message, alg_bytesize, 0);\n \t\t\tHEXDUMP(\"RSA text to be signed\", cookie->input_array[0],\n \t\t\t\talg_bytesize);\n \t\t\tbreak;\n@@ -580,12 +554,12 @@ ecdsa_set_input(struct rte_crypto_asym_op *asym_op,\n \t\tstruct rte_crypto_asym_xform *xform)\n {\n \tstruct qat_asym_function qat_function;\n-\tuint32_t alg_bytesize, qat_alg_bytesize, func_id;\n+\tuint32_t qat_func_alignsize, func_id;\n \tint curve_id;\n \n \tcurve_id = pick_curve(xform);\n \tif (curve_id < 0) {\n-\t\tQAT_LOG(ERR, \"Incorrect elliptic curve\");\n+\t\tQAT_LOG(DEBUG, \"Incorrect elliptic curve\");\n \t\treturn -EINVAL;\n \t}\n \n@@ -597,20 +571,21 @@ ecdsa_set_input(struct rte_crypto_asym_op *asym_op,\n \t\t\tQAT_LOG(ERR, \"Cannot obtain functionality id\");\n \t\t\treturn -EINVAL;\n \t\t}\n-\t\talg_bytesize = qat_function.bytesize;\n-\t\tqat_alg_bytesize = RTE_ALIGN_CEIL(alg_bytesize, 8);\n-\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.pkey, 0);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.message, 1);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.k, 2);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].b, alg_bytesize, 3);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].a, alg_bytesize, 4);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].p, alg_bytesize, 5);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].n, alg_bytesize, 6);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].y, alg_bytesize, 7);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].x, alg_bytesize, 8);\n-\n-\t\tcookie->alg_bytesize = alg_bytesize;\n+\t\tqat_func_alignsize =\n+\t\t\tRTE_ALIGN_CEIL(qat_function.bytesize, 8);\n+\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.pkey, 0);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.message, 1);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.k, 2);\n+\t\tSET_PKE_9A_EC(curve[curve_id], b, 3);\n+\t\tSET_PKE_9A_EC(curve[curve_id], a, 4);\n+\t\tSET_PKE_9A_EC(curve[curve_id], p, 5);\n+\t\tSET_PKE_9A_EC(curve[curve_id], n, 6);\n+\t\tSET_PKE_9A_EC(curve[curve_id], y, 7);\n+\t\tSET_PKE_9A_EC(curve[curve_id], x, 8);\n+\n+\t\tcookie->alg_bytesize = curve[curve_id].bytesize;\n+\t\tcookie->qat_func_alignsize = qat_func_alignsize;\n \t\tqat_req->pke_hdr.cd_pars.func_id = func_id;\n \t\tqat_req->input_param_count =\n \t\t\t\tQAT_ASYM_ECDSA_RS_SIGN_IN_PARAMS;\n@@ -633,22 +608,22 @@ ecdsa_set_input(struct rte_crypto_asym_op *asym_op,\n \t\t\tQAT_LOG(ERR, \"Cannot obtain functionality id\");\n \t\t\treturn -EINVAL;\n \t\t}\n-\t\talg_bytesize = qat_function.bytesize;\n-\t\tqat_alg_bytesize = RTE_ALIGN_CEIL(alg_bytesize, 8);\n-\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.message, 10);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.s, 9);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.r, 8);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].n, alg_bytesize, 7);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].x, alg_bytesize, 6);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].y, alg_bytesize, 5);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.q.x, 4);\n-\t\tSET_PKE_LN_9A_F(asym_op->ecdsa.q.y, 3);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].a, alg_bytesize, 2);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].b, alg_bytesize, 1);\n-\t\tSET_PKE_LN_EC_F(curve[curve_id].p, alg_bytesize, 0);\n-\n-\t\tcookie->alg_bytesize = alg_bytesize;\n+\t\tqat_func_alignsize = RTE_ALIGN_CEIL(qat_function.bytesize, 8);\n+\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.message, 10);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.s, 9);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.r, 8);\n+\t\tSET_PKE_9A_EC(curve[curve_id], n, 7);\n+\t\tSET_PKE_9A_EC(curve[curve_id], x, 6);\n+\t\tSET_PKE_9A_EC(curve[curve_id], y, 5);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.q.x, 4);\n+\t\tSET_PKE_9A_IN(asym_op->ecdsa.q.y, 3);\n+\t\tSET_PKE_9A_EC(curve[curve_id], a, 2);\n+\t\tSET_PKE_9A_EC(curve[curve_id], b, 1);\n+\t\tSET_PKE_9A_EC(curve[curve_id], p, 0);\n+\n+\t\tcookie->alg_bytesize = curve[curve_id].bytesize;\n+\t\tcookie->qat_func_alignsize = qat_func_alignsize;\n \t\tqat_req->pke_hdr.cd_pars.func_id = func_id;\n \t\tqat_req->input_param_count =\n \t\t\t\tQAT_ASYM_ECDSA_RS_VERIFY_IN_PARAMS;\n@@ -679,8 +654,8 @@ ecdsa_collect(struct rte_crypto_asym_op *asym_op,\n \t\tstruct qat_asym_op_cookie *cookie)\n {\n \tuint32_t alg_bytesize = cookie->alg_bytesize;\n-\tuint32_t qat_alg_bytesize = RTE_ALIGN_CEIL(cookie->alg_bytesize, 8);\n-\tuint32_t ltrim = qat_alg_bytesize - alg_bytesize;\n+\tuint32_t qat_func_alignsize = cookie->qat_func_alignsize;\n+\tuint32_t ltrim = qat_func_alignsize - alg_bytesize;\n \n \tif (asym_op->rsa.op_type == RTE_CRYPTO_ASYM_OP_SIGN) {\n \t\tuint8_t *r = asym_op->ecdsa.r.data;\n@@ -692,9 +667,9 @@ ecdsa_collect(struct rte_crypto_asym_op *asym_op,\n \t\trte_memcpy(s, &cookie->output_array[1][ltrim], alg_bytesize);\n \n \t\tHEXDUMP(\"R\", cookie->output_array[0],\n-\t\t\talg_bytesize);\n+\t\t\tqat_func_alignsize);\n \t\tHEXDUMP(\"S\", cookie->output_array[1],\n-\t\t\talg_bytesize);\n+\t\t\tqat_func_alignsize);\n \t}\n \treturn RTE_CRYPTO_OP_STATUS_SUCCESS;\n }\n@@ -706,12 +681,12 @@ ecpm_set_input(struct rte_crypto_asym_op *asym_op,\n \t\tstruct rte_crypto_asym_xform *xform)\n {\n \tstruct qat_asym_function qat_function;\n-\tuint32_t alg_bytesize, __rte_unused qat_alg_bytesize, func_id;\n+\tuint32_t qat_func_alignsize, func_id;\n \tint curve_id;\n \n \tcurve_id = pick_curve(xform);\n \tif (curve_id < 0) {\n-\t\tQAT_LOG(ERR, \"Incorrect elliptic curve\");\n+\t\tQAT_LOG(DEBUG, \"Incorrect elliptic curve\");\n \t\treturn -EINVAL;\n \t}\n \n@@ -721,38 +696,31 @@ ecpm_set_input(struct rte_crypto_asym_op *asym_op,\n \t\tQAT_LOG(ERR, \"Cannot obtain functionality id\");\n \t\treturn -EINVAL;\n \t}\n-\talg_bytesize = qat_function.bytesize;\n-\tqat_alg_bytesize = RTE_ALIGN_CEIL(alg_bytesize, 8);\n-\n-\tSET_PKE_LN_EC(cookie->input_array, asym_op->ecpm.scalar,\n-\t\t\tasym_op->ecpm.scalar.length, 0);\n-\tSET_PKE_LN_EC(cookie->input_array, asym_op->ecpm.p.x,\n-\t\t\t asym_op->ecpm.p.x.length, 1);\n-\tSET_PKE_LN_EC(cookie->input_array, asym_op->ecpm.p.y,\n-\t\t\tasym_op->ecpm.p.y.length, 2);\n-\tSET_PKE_LN_EC(cookie->input_array, curve[curve_id].a,\n-\t\t\talg_bytesize, 3);\n-\tSET_PKE_LN_EC(cookie->input_array, curve[curve_id].b,\n-\t\t\talg_bytesize, 4);\n-\tSET_PKE_LN_EC(cookie->input_array, curve[curve_id].p,\n-\t\t\talg_bytesize, 5);\n-\tSET_PKE_LN_EC(cookie->input_array, curve[curve_id].h,\n-\t\t\talg_bytesize, 6);\n-\n-\tcookie->alg_bytesize = alg_bytesize;\n+\tqat_func_alignsize = RTE_ALIGN_CEIL(qat_function.bytesize, 8);\n+\n+\tSET_PKE_LN(asym_op->ecpm.scalar, qat_func_alignsize, 0);\n+\tSET_PKE_LN(asym_op->ecpm.p.x, qat_func_alignsize, 1);\n+\tSET_PKE_LN(asym_op->ecpm.p.y, qat_func_alignsize, 2);\n+\tSET_PKE_LN_EC(curve[curve_id], a, 3);\n+\tSET_PKE_LN_EC(curve[curve_id], b, 4);\n+\tSET_PKE_LN_EC(curve[curve_id], p, 5);\n+\tSET_PKE_LN_EC(curve[curve_id], h, 6);\n+\n+\tcookie->alg_bytesize = curve[curve_id].bytesize;\n+\tcookie->qat_func_alignsize = qat_func_alignsize;\n \tqat_req->pke_hdr.cd_pars.func_id = func_id;\n \tqat_req->input_param_count =\n \t\t\tQAT_ASYM_ECPM_IN_PARAMS;\n \tqat_req->output_param_count =\n \t\t\tQAT_ASYM_ECPM_OUT_PARAMS;\n \n-\tHEXDUMP(\"k\", cookie->input_array[0], qat_alg_bytesize);\n-\tHEXDUMP(\"xG\", cookie->input_array[1], qat_alg_bytesize);\n-\tHEXDUMP(\"yG\", cookie->input_array[2], qat_alg_bytesize);\n-\tHEXDUMP(\"a\", cookie->input_array[3], qat_alg_bytesize);\n-\tHEXDUMP(\"b\", cookie->input_array[4], qat_alg_bytesize);\n-\tHEXDUMP(\"q\", cookie->input_array[5], qat_alg_bytesize);\n-\tHEXDUMP(\"h\", cookie->input_array[6], qat_alg_bytesize);\n+\tHEXDUMP(\"k\", cookie->input_array[0], qat_func_alignsize);\n+\tHEXDUMP(\"xG\", cookie->input_array[1], qat_func_alignsize);\n+\tHEXDUMP(\"yG\", cookie->input_array[2], qat_func_alignsize);\n+\tHEXDUMP(\"a\", cookie->input_array[3], qat_func_alignsize);\n+\tHEXDUMP(\"b\", cookie->input_array[4], qat_func_alignsize);\n+\tHEXDUMP(\"q\", cookie->input_array[5], qat_func_alignsize);\n+\tHEXDUMP(\"h\", cookie->input_array[6], qat_func_alignsize);\n \n \treturn 0;\n }\n@@ -764,8 +732,8 @@ ecpm_collect(struct rte_crypto_asym_op *asym_op,\n \tuint8_t *x = asym_op->ecpm.r.x.data;\n \tuint8_t *y = asym_op->ecpm.r.y.data;\n \tuint32_t alg_bytesize = cookie->alg_bytesize;\n-\tuint32_t qat_alg_bytesize = RTE_ALIGN_CEIL(cookie->alg_bytesize, 8);\n-\tuint32_t ltrim = qat_alg_bytesize - alg_bytesize;\n+\tuint32_t qat_func_alignsize = cookie->qat_func_alignsize;\n+\tuint32_t ltrim = qat_func_alignsize - alg_bytesize;\n \n \tasym_op->ecpm.r.x.length = alg_bytesize;\n \tasym_op->ecpm.r.y.length = alg_bytesize;\n@@ -773,9 +741,9 @@ ecpm_collect(struct rte_crypto_asym_op *asym_op,\n \trte_memcpy(y, &cookie->output_array[1][ltrim], alg_bytesize);\n \n \tHEXDUMP(\"rX\", cookie->output_array[0],\n-\t\talg_bytesize);\n+\t\tqat_func_alignsize);\n \tHEXDUMP(\"rY\", cookie->output_array[1],\n-\t\talg_bytesize);\n+\t\tqat_func_alignsize);\n \treturn RTE_CRYPTO_OP_STATUS_SUCCESS;\n }\n \n@@ -910,13 +878,13 @@ qat_asym_process_response(void **out_op, uint8_t *resp,\n \t\tcookie->error = 0;\n \t\tif (op->status == RTE_CRYPTO_OP_STATUS_NOT_PROCESSED)\n \t\t\top->status = RTE_CRYPTO_OP_STATUS_ERROR;\n-\t\tQAT_DP_LOG(ERR, \"Cookie status returned error\");\n+\t\tQAT_DP_LOG(DEBUG, \"Cookie status returned error\");\n \t} else {\n \t\tif (ICP_QAT_FW_PKE_RESP_PKE_STAT_GET(\n \t\t\tresp_msg->pke_resp_hdr.resp_status.pke_resp_flags)) {\n \t\t\tif (op->status == RTE_CRYPTO_OP_STATUS_NOT_PROCESSED)\n \t\t\t\top->status = RTE_CRYPTO_OP_STATUS_ERROR;\n-\t\t\tQAT_DP_LOG(ERR, \"Asymmetric response status\"\n+\t\t\tQAT_DP_LOG(DEBUG, \"Asymmetric response status\"\n \t\t\t\t\t\" returned error\");\n \t\t}\n \t\tif (resp_msg->pke_resp_hdr.resp_status.comn_err_code) {\ndiff --git a/drivers/crypto/qat/qat_asym.h b/drivers/crypto/qat/qat_asym.h\nindex b1d403486f..6628656b42 100644\n--- a/drivers/crypto/qat/qat_asym.h\n+++ b/drivers/crypto/qat/qat_asym.h\n@@ -58,8 +58,9 @@ typedef uint64_t large_int_ptr;\n \t}\n \n struct qat_asym_op_cookie {\n-\tsize_t alg_bytesize;\n \tuint64_t error;\n+\tuint32_t alg_bytesize; /*< Bytesize of algorithm */\n+\tuint32_t qat_func_alignsize; /*< Aligned bytesize of qat function */\n \trte_iova_t input_addr;\n \trte_iova_t output_addr;\n \tlarge_int_ptr input_params_ptrs[MAX_PKE_PARAMS] _PKE_ALIGN_;\ndiff --git a/drivers/crypto/qat/qat_ec.h b/drivers/crypto/qat/qat_ec.h\nindex a310e3f4d3..1bcd7d1408 100644\n--- a/drivers/crypto/qat/qat_ec.h\n+++ b/drivers/crypto/qat/qat_ec.h\n@@ -92,7 +92,6 @@ static struct elliptic_curve curve[] = {\n \t\t\t\t},\n \t\t},\n \t},\n-\n \t[SECP521R1] = {\n \t\t.name = \"secp521r1\",\n \t\t.bytesize = 66,\n",
    "prefixes": [
        "1/2"
    ]
}