From patchwork Fri Feb 18 07:53:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arkadiusz Kusztal X-Patchwork-Id: 107793 X-Patchwork-Delegate: gakhil@marvell.com Return-Path: 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]) by inbox.dpdk.org (Postfix) with ESMTP id 12110A0032; Fri, 18 Feb 2022 08:53:39 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D5E6A40395; Fri, 18 Feb 2022 08:53:38 +0100 (CET) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by mails.dpdk.org (Postfix) with ESMTP id A73A740150 for ; Fri, 18 Feb 2022 08:53:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1645170816; x=1676706816; h=from:to:cc:subject:date:message-id; bh=4yzPpbVmsym7vVy19V/wwcVWl5wlnx50RxKrpJBtIxA=; b=j9Mx+QWRboRhCOzsrRKhiXyyH9Bn873ZPUsHMOaqCaZG7ngOBQQjV9Ng +jKEXtnKHOMneHtqtPhVBbKQFYarcy8qACrJo7jOsyQZCjwXwXOJm+XEN TtmLGJmSaL0+scPnZLKS/XjtCqJiGqEWHO33jvR4HnldjDdvdEDvIXpnU 90hShYJS0of3kYqqpZh11uOYRURmeXhxvMg8A9UysxVCbZ7lcB/azEHn1 enVdGPf/x8yiwRBCu5uS7e812XUjvVutcswwG8w9RZvtOvwn+1Z2biyxW 6GBgcAFR1d4PMGWGBaZtnnccYcKHOpWGfn06XnoB8nHmAvcGbBnkKdbrY Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10261"; a="251274120" X-IronPort-AV: E=Sophos;i="5.88,378,1635231600"; d="scan'208";a="251274120" Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Feb 2022 23:53:35 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,378,1635231600"; d="scan'208";a="682401114" Received: from silpixa00400308.ir.intel.com ([10.237.214.95]) by fmsmga001.fm.intel.com with ESMTP; 17 Feb 2022 23:53:34 -0800 From: Arek Kusztal To: dev@dpdk.org Cc: gakhil@marvell.com, roy.fan.zhang@intel.com, mdr@ashroe.eu, Arek Kusztal Subject: [PATCH v2] crypto: fix misspelled key in qt format Date: Fri, 18 Feb 2022 07:53:32 +0000 Message-Id: <20220218075332.18916-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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org This patch fixes misspelled RTE_RSA_KEY_TYPE_QT, this will prevent checkpach from complaining wherever change to RSA is being made. Fixes: 26008aaed14c ("cryptodev: add asymmetric xform and op definitions") Signed-off-by: Arek Kusztal Acked-by: Akhil Goyal --- v2: - added ignore hint to abidiff suppression file app/test/test_cryptodev_asym.c | 2 +- app/test/test_cryptodev_rsa_test_vectors.h | 2 +- devtools/libabigail.abignore | 4 ++++ drivers/crypto/qat/qat_asym.c | 4 ++-- lib/cryptodev/rte_crypto_asym.h | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 7cda8bb081..573af2a537 100644 --- a/app/test/test_cryptodev_asym.c +++ b/app/test/test_cryptodev_asym.c @@ -549,7 +549,7 @@ test_one_case(const void *test_case, int sessionless) status = test_cryptodev_asym_op( &testsuite_params, &tc, test_msg, sessionless, i, - RTE_RSA_KET_TYPE_QT); + RTE_RSA_KEY_TYPE_QT); } if (status) break; diff --git a/app/test/test_cryptodev_rsa_test_vectors.h b/app/test/test_cryptodev_rsa_test_vectors.h index 48a72e1492..04539a1ecf 100644 --- a/app/test/test_cryptodev_rsa_test_vectors.h +++ b/app/test/test_cryptodev_rsa_test_vectors.h @@ -378,7 +378,7 @@ struct rte_crypto_asym_xform rsa_xform_crt = { .data = rsa_e, .length = sizeof(rsa_e) }, - .key_type = RTE_RSA_KET_TYPE_QT, + .key_type = RTE_RSA_KEY_TYPE_QT, .qt = { .p = { .data = rsa_p, diff --git a/devtools/libabigail.abignore b/devtools/libabigail.abignore index ef0602975a..10c8f64662 100644 --- a/devtools/libabigail.abignore +++ b/devtools/libabigail.abignore @@ -20,3 +20,7 @@ ; Ignore changes to rte_crypto_asym_op, asymmetric crypto API is experimental [suppress_type] name = rte_crypto_asym_op + +; Ignore name change of rsa qt key type +[suppress_type] + name = rte_crypto_rsa_priv_key_type diff --git a/drivers/crypto/qat/qat_asym.c b/drivers/crypto/qat/qat_asym.c index f46eefd4b3..27ce0337a7 100644 --- a/drivers/crypto/qat/qat_asym.c +++ b/drivers/crypto/qat/qat_asym.c @@ -97,7 +97,7 @@ static void qat_clear_arrays_by_alg(struct qat_asym_op_cookie *cookie, qat_clear_arrays(cookie, QAT_ASYM_MODINV_NUM_IN_PARAMS, QAT_ASYM_MODINV_NUM_OUT_PARAMS, alg_size); else if (xform->xform_type == RTE_CRYPTO_ASYM_XFORM_RSA) { - if (xform->rsa.key_type == RTE_RSA_KET_TYPE_QT) + if (xform->rsa.key_type == RTE_RSA_KEY_TYPE_QT) qat_clear_arrays_crt(cookie, alg_size); else { qat_clear_arrays(cookie, QAT_ASYM_RSA_NUM_IN_PARAMS, @@ -370,7 +370,7 @@ qat_asym_fill_arrays(struct rte_crypto_asym_op *asym_op, return -(EINVAL); } } - if (xform->rsa.key_type == RTE_RSA_KET_TYPE_QT) { + if (xform->rsa.key_type == RTE_RSA_KEY_TYPE_QT) { qat_req->input_param_count = QAT_ASYM_RSA_QT_NUM_IN_PARAMS; diff --git a/lib/cryptodev/rte_crypto_asym.h b/lib/cryptodev/rte_crypto_asym.h index 2eb0f001e3..cd24d4b07b 100644 --- a/lib/cryptodev/rte_crypto_asym.h +++ b/lib/cryptodev/rte_crypto_asym.h @@ -145,7 +145,7 @@ enum rte_crypto_rsa_padding_type { enum rte_crypto_rsa_priv_key_type { RTE_RSA_KEY_TYPE_EXP, /**< RSA private key is an exponent */ - RTE_RSA_KET_TYPE_QT, + RTE_RSA_KEY_TYPE_QT, /**< RSA private key is in quintuple format * See rte_crypto_rsa_priv_key_qt */