Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/56441/?format=api
http://patches.dpdk.org/api/patches/56441/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/patch/20190715121451.6020-1-damianx.nowak@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": "<20190715121451.6020-1-damianx.nowak@intel.com>", "list_archive_url": "https://inbox.dpdk.org/dev/20190715121451.6020-1-damianx.nowak@intel.com", "date": "2019-07-15T12:14:51", "name": "test/crypto: add capability check for ZUC test cases", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": true, "hash": "9bce5f143af2e5aad1506828ebfb905d2e7d926d", "submitter": { "id": 1184, "url": "http://patches.dpdk.org/api/people/1184/?format=api", "name": "Damian Nowak", "email": "damianx.nowak@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/20190715121451.6020-1-damianx.nowak@intel.com/mbox/", "series": [ { "id": 5495, "url": "http://patches.dpdk.org/api/series/5495/?format=api", "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=5495", "date": "2019-07-15T12:14:51", "name": "test/crypto: add capability check for ZUC test cases", "version": 1, "mbox": "http://patches.dpdk.org/series/5495/mbox/" } ], "comments": "http://patches.dpdk.org/api/patches/56441/comments/", "check": "fail", "checks": "http://patches.dpdk.org/api/patches/56441/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 93B3A3256;\n\tMon, 15 Jul 2019 14:17:57 +0200 (CEST)", "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n\tby dpdk.org (Postfix) with ESMTP id 2EF4F2BF4\n\tfor <dev@dpdk.org>; Mon, 15 Jul 2019 14:17:55 +0200 (CEST)", "from fmsmga001.fm.intel.com ([10.253.24.23])\n\tby fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t15 Jul 2019 05:17:55 -0700", "from damiannx-mobl1.ger.corp.intel.com ([10.103.104.107])\n\tby fmsmga001.fm.intel.com with ESMTP; 15 Jul 2019 05:17:53 -0700" ], "X-Amp-Result": "SKIPPED(no attachment in message)", "X-Amp-File-Uploaded": "False", "X-ExtLoop1": "1", "X-IronPort-AV": "E=Sophos;i=\"5.63,493,1557212400\"; d=\"scan'208\";a=\"187105216\"", "From": "Damian Nowak <damianx.nowak@intel.com>", "To": "dev@dpdk.org", "Cc": "akhil.goyal@nxp.com, fiona.trahe@intel.com, arkadiuszx.kusztal@intel.com,\n\tDamian Nowak <damianx.nowak@intel.com>", "Date": "Mon, 15 Jul 2019 14:14:51 +0200", "Message-Id": "<20190715121451.6020-1-damianx.nowak@intel.com>", "X-Mailer": "git-send-email 2.21.0.windows.1", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[dpdk-dev] [PATCH] test/crypto: add capability check for ZUC test\n\tcases", "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 patch adds checking if device support ZUC\nalgorithms before running ZUC test cases.\nIt also removes unnecessary checks of digest\nappended space and fixes some comments wording.\n\nSigned-off-by: Damian Nowak <damianx.nowak@intel.com>\n---\n app/test/test_cryptodev.c | 28 ++++++++++++++++++++--------\n 1 file changed, 20 insertions(+), 8 deletions(-)", "diff": "diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c\nindex 05422da..c822164 100644\n--- a/app/test/test_cryptodev.c\n+++ b/app/test/test_cryptodev.c\n@@ -2909,8 +2909,6 @@ create_wireless_algo_auth_cipher_operation(unsigned int auth_tag_len,\n \t\t\t(op_mode == IN_PLACE ?\n \t\t\t\tut_params->ibuf : ut_params->obuf),\n \t\t\tdata_pad_len);\n-\t\tTEST_ASSERT_NOT_NULL(sym_op->auth.digest.data,\n-\t\t\t\"no room to append auth tag\");\n \t\tmemset(sym_op->auth.digest.data, 0, auth_tag_len);\n \t} else {\n \t\tuint16_t remaining_off = (auth_offset >> 3) + (auth_len >> 3);\n@@ -2924,8 +2922,6 @@ create_wireless_algo_auth_cipher_operation(unsigned int auth_tag_len,\n \t\t\t\tuint8_t *, remaining_off);\n \t\tsym_op->auth.digest.phys_addr = rte_pktmbuf_iova_offset(sgl_buf,\n \t\t\t\tremaining_off);\n-\t\tTEST_ASSERT_NOT_NULL(sym_op->auth.digest.data,\n-\t\t\t\"no room to append auth tag\");\n \t\tmemset(sym_op->auth.digest.data, 0, remaining_off);\n \t\twhile (sgl_buf->next != NULL) {\n \t\t\tmemset(rte_pktmbuf_mtod(sgl_buf, uint8_t *),\n@@ -5002,7 +4998,7 @@ test_kasumi_auth_cipher_sgl(const struct kasumi_test_data *tdata,\n \t}\n \tmemset(buffer, 0, sizeof(buffer));\n \n-\t/* Create SNOW 3G operation */\n+\t/* Create KASUMI operation */\n \tretval = create_wireless_algo_auth_cipher_operation(\n \t\ttdata->digest.len,\n \t\ttdata->cipher_iv.data, tdata->cipher_iv.len,\n@@ -5432,6 +5428,15 @@ test_zuc_auth_cipher(const struct wireless_test_data *tdata,\n \tunsigned int ciphertext_len;\n \n \tstruct rte_cryptodev_info dev_info;\n+\tstruct rte_cryptodev_sym_capability_idx cap_idx;\n+\n+\t/* Check if device supports ZUC EIA3 */\n+\tcap_idx.type = RTE_CRYPTO_SYM_XFORM_AUTH;\n+\tcap_idx.algo.auth = RTE_CRYPTO_AUTH_ZUC_EIA3;\n+\n+\tif (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],\n+\t\t\t&cap_idx) == NULL)\n+\t\treturn -ENOTSUP;\n \n \trte_cryptodev_info_get(ts_params->valid_devs[0], &dev_info);\n \n@@ -5444,7 +5449,7 @@ test_zuc_auth_cipher(const struct wireless_test_data *tdata,\n \t\t}\n \t}\n \n-\t/* Create KASUMI session */\n+\t/* Create ZUC session */\n \tretval = create_wireless_algo_auth_cipher_session(\n \t\t\tts_params->valid_devs[0],\n \t\t\t(verify ? RTE_CRYPTO_CIPHER_OP_DECRYPT\n@@ -5473,8 +5478,6 @@ test_zuc_auth_cipher(const struct wireless_test_data *tdata,\n \n \tciphertext_len = ceil_byte_length(tdata->ciphertext.len);\n \tplaintext_len = ceil_byte_length(tdata->plaintext.len);\n-\t/* Append data which is padded to a multiple of */\n-\t/* the algorithms block size */\n \tciphertext_pad_len = RTE_ALIGN_CEIL(ciphertext_len, 16);\n \tplaintext_pad_len = RTE_ALIGN_CEIL(plaintext_len, 16);\n \n@@ -5600,6 +5603,15 @@ test_zuc_auth_cipher_sgl(const struct wireless_test_data *tdata,\n \tuint8_t digest_buffer[10000];\n \n \tstruct rte_cryptodev_info dev_info;\n+\tstruct rte_cryptodev_sym_capability_idx cap_idx;\n+\n+\t/* Check if device supports ZUC EIA3 */\n+\tcap_idx.type = RTE_CRYPTO_SYM_XFORM_AUTH;\n+\tcap_idx.algo.auth = RTE_CRYPTO_AUTH_ZUC_EIA3;\n+\n+\tif (rte_cryptodev_sym_capability_get(ts_params->valid_devs[0],\n+\t\t\t&cap_idx) == NULL)\n+\t\treturn -ENOTSUP;\n \n \trte_cryptodev_info_get(ts_params->valid_devs[0], &dev_info);\n \n", "prefixes": [] }{ "id": 56441, "url": "