From patchwork Sat Jul 31 18:13:24 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akhil Goyal X-Patchwork-Id: 96496 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 C2290A0547; Sat, 31 Jul 2021 20:13:48 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A322840DDC; Sat, 31 Jul 2021 20:13:48 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 6B61840042 for ; Sat, 31 Jul 2021 20:13:47 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 16VIAw6f020553; Sat, 31 Jul 2021 11:13:42 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=8mbGemHZVbTCrdSW9yDiBKV3EN+FiKf08Z0FbsXEIrc=; b=IQoP5HOdQLfI8hN4q4MrJkxhANcTSgr6cXaR6v24Dv2kU7WEm1XmZNZU57GXVhPfpidD vmUjgwkrtUyQJJuKKHqyx6HPTCYFI0jU5nxIvPi5vQ/Ql42ni6SS5ZsS/4+twqk46tRT HL0R+9zKEZ+USvdj5XjVKI+JlFfrSpfESCyiLFFaR3Z4wHyeY2qk+IABShg0uz9bdfha BGhKotPwk0wc1Hlce4QeBIuZjmtDwvYGtK7qdLjGFXbyN3zmrqUAfWH3p7xX64EbFTc5 2hcp33eZrh5/GZJI0PmW3/yUn200XhROdj8kgET/mSFhZTspARW+F3Jh20B5nrmUVVeB jQ== Received: from dc5-exch01.marvell.com ([199.233.59.181]) by mx0a-0016f401.pphosted.com with ESMTP id 3a53vr8xff-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Sat, 31 Jul 2021 11:13:41 -0700 Received: from DC5-EXCH02.marvell.com (10.69.176.39) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Sat, 31 Jul 2021 11:13:40 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Sat, 31 Jul 2021 11:13:40 -0700 Received: from localhost.localdomain (unknown [10.28.36.185]) by maili.marvell.com (Postfix) with ESMTP id 650B33F7075; Sat, 31 Jul 2021 11:13:36 -0700 (PDT) From: Akhil Goyal To: CC: , , , , , , , , , , , , , Akhil Goyal Date: Sat, 31 Jul 2021 23:43:24 +0530 Message-ID: <20210731181327.660296-2-gakhil@marvell.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210731181327.660296-1-gakhil@marvell.com> References: <20210731181327.660296-1-gakhil@marvell.com> MIME-Version: 1.0 X-Proofpoint-ORIG-GUID: DJVVYveV531IRvt-TYn3rUrnV9bhbppp X-Proofpoint-GUID: DJVVYveV531IRvt-TYn3rUrnV9bhbppp X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-07-31_05:2021-07-30, 2021-07-31 signatures=0 Subject: [dpdk-dev] [PATCH 1/4] cryptodev: remove LIST_END enumerators 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 Sender: "dev" Remove *_LIST_END enumerators from asymmetric crypto lib to avoid ABI breakage for every new addition in enums. Signed-off-by: Akhil Goyal --- app/test/test_cryptodev_asym.c | 4 ++-- drivers/crypto/qat/qat_asym.c | 2 +- lib/cryptodev/rte_crypto_asym.h | 4 ---- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 847b074a4f..afa0e91a45 100644 --- a/app/test/test_cryptodev_asym.c +++ b/app/test/test_cryptodev_asym.c @@ -542,7 +542,7 @@ test_one_case(const void *test_case, int sessionless) printf(" %u) TestCase %s %s\n", test_index++, tc.modex.description, test_msg); } else { - for (i = 0; i < RTE_CRYPTO_ASYM_OP_LIST_END; i++) { + for (i = 0; i <= RTE_CRYPTO_ASYM_OP_SHARED_SECRET_COMPUTE; i++) { if (tc.modex.xform_type == RTE_CRYPTO_ASYM_XFORM_RSA) { if (tc.rsa_data.op_type_flags & (1 << i)) { if (tc.rsa_data.key_exp) { @@ -1028,7 +1028,7 @@ static inline void print_asym_capa( rte_crypto_asym_xform_strings[capa->xform_type]); printf("operation supported -"); - for (i = 0; i < RTE_CRYPTO_ASYM_OP_LIST_END; i++) { + for (i = 0; i <= RTE_CRYPTO_ASYM_OP_SHARED_SECRET_COMPUTE; i++) { /* check supported operations */ if (rte_cryptodev_asym_xform_capability_check_optype(capa, i)) printf(" %s", diff --git a/drivers/crypto/qat/qat_asym.c b/drivers/crypto/qat/qat_asym.c index 85973812a8..026625a4d2 100644 --- a/drivers/crypto/qat/qat_asym.c +++ b/drivers/crypto/qat/qat_asym.c @@ -742,7 +742,7 @@ qat_asym_session_configure(struct rte_cryptodev *dev, err = -EINVAL; goto error; } - } else if (xform->xform_type >= RTE_CRYPTO_ASYM_XFORM_TYPE_LIST_END + } else if (xform->xform_type > RTE_CRYPTO_ASYM_XFORM_ECPM || xform->xform_type <= RTE_CRYPTO_ASYM_XFORM_NONE) { QAT_LOG(ERR, "Invalid asymmetric crypto xform"); err = -EINVAL; diff --git a/lib/cryptodev/rte_crypto_asym.h b/lib/cryptodev/rte_crypto_asym.h index 9c866f553f..5edf658572 100644 --- a/lib/cryptodev/rte_crypto_asym.h +++ b/lib/cryptodev/rte_crypto_asym.h @@ -94,8 +94,6 @@ enum rte_crypto_asym_xform_type { */ RTE_CRYPTO_ASYM_XFORM_ECPM, /**< Elliptic Curve Point Multiplication */ - RTE_CRYPTO_ASYM_XFORM_TYPE_LIST_END - /**< End of list */ }; /** @@ -116,7 +114,6 @@ enum rte_crypto_asym_op_type { /**< DH Public Key generation operation */ RTE_CRYPTO_ASYM_OP_SHARED_SECRET_COMPUTE, /**< DH Shared Secret compute operation */ - RTE_CRYPTO_ASYM_OP_LIST_END }; /** @@ -133,7 +130,6 @@ enum rte_crypto_rsa_padding_type { /**< RSA PKCS#1 OAEP padding scheme */ RTE_CRYPTO_RSA_PADDING_PSS, /**< RSA PKCS#1 PSS padding scheme */ - RTE_CRYPTO_RSA_PADDING_TYPE_LIST_END }; /** From patchwork Sat Jul 31 18:13:25 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akhil Goyal X-Patchwork-Id: 96497 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 B9403A0547; Sat, 31 Jul 2021 20:13:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BD881410DA; Sat, 31 Jul 2021 20:13:51 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by mails.dpdk.org (Postfix) with ESMTP id 1F4C240DDB for ; Sat, 31 Jul 2021 20:13:51 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 16VIDlTP025477; Sat, 31 Jul 2021 11:13:47 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=A0l+a0X7vBf3pDsiaaIp3iNj0+ym2e05Wl05huwZeIQ=; b=Co49ifOxxKA8Zms3oC+psQnPavobtcdc56qFBmG4LeiSyD2qH1WOXXjtQdXmvTbk3mMc 22g3QTBvPETR78EZS7Q2CgEfv+xFUmYJX3KMkwLqyBJS+P2E6bJNIBhli7qbpQ5BM055 MA2w3iWRJ8XQoUUl/tJ6lKKh7xKxRRQM8o6eBiUy0UUpRHZNeUyk6CZRaYOS3BrfWk2I Ie6VjxEpYfTc8VrprIDGuKZFH5jwJazDu9//oIWQCPEdTp47CqaE/zrb0QtcOw8scdTN xi3DZ/lRfK9FymjjWMu1bo/+z/AdAJh8lYSS9sprGpPLPdy3IkRvqk13YYsxlFELHMmn 5w== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0b-0016f401.pphosted.com with ESMTP id 3a561rrmre-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Sat, 31 Jul 2021 11:13:47 -0700 Received: from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Sat, 31 Jul 2021 11:13:45 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Sat, 31 Jul 2021 11:13:44 -0700 Received: from localhost.localdomain (unknown [10.28.36.185]) by maili.marvell.com (Postfix) with ESMTP id F00333F7070; Sat, 31 Jul 2021 11:13:40 -0700 (PDT) From: Akhil Goyal To: CC: , , , , , , , , , , , , , Akhil Goyal Date: Sat, 31 Jul 2021 23:43:25 +0530 Message-ID: <20210731181327.660296-3-gakhil@marvell.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210731181327.660296-1-gakhil@marvell.com> References: <20210731181327.660296-1-gakhil@marvell.com> MIME-Version: 1.0 X-Proofpoint-ORIG-GUID: zXQAaudfyazpbTtb31Tv85mwbKeqGWLk X-Proofpoint-GUID: zXQAaudfyazpbTtb31Tv85mwbKeqGWLk X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-07-31_05:2021-07-30, 2021-07-31 signatures=0 Subject: [dpdk-dev] [PATCH 2/4] cryptodev: promote asym APIs to stable 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 Sender: "dev" Asymmetric crypto APIs have been stable from quite some time, hence moving them from experimental to stable in DPDK 21.11 Signed-off-by: Akhil Goyal --- lib/cryptodev/rte_cryptodev.h | 10 ---------- lib/cryptodev/version.map | 24 +++++++++++++----------- 2 files changed, 13 insertions(+), 21 deletions(-) diff --git a/lib/cryptodev/rte_cryptodev.h b/lib/cryptodev/rte_cryptodev.h index 11f4e6fdbf..425f459143 100644 --- a/lib/cryptodev/rte_cryptodev.h +++ b/lib/cryptodev/rte_cryptodev.h @@ -247,7 +247,6 @@ rte_cryptodev_sym_capability_get(uint8_t dev_id, * - Return description of the asymmetric crypto capability if exist. * - Return NULL if the capability not exist. */ -__rte_experimental const struct rte_cryptodev_asymmetric_xform_capability * rte_cryptodev_asym_capability_get(uint8_t dev_id, const struct rte_cryptodev_asym_capability_idx *idx); @@ -317,7 +316,6 @@ rte_cryptodev_sym_capability_check_aead( * - Return 1 if the op type is supported * - Return 0 if unsupported */ -__rte_experimental int rte_cryptodev_asym_xform_capability_check_optype( const struct rte_cryptodev_asymmetric_xform_capability *capability, @@ -333,7 +331,6 @@ rte_cryptodev_asym_xform_capability_check_optype( * - Return 0 if the parameters are in range of the capability. * - Return -1 if the parameters are out of range of the capability. */ -__rte_experimental int rte_cryptodev_asym_xform_capability_check_modlen( const struct rte_cryptodev_asymmetric_xform_capability *capability, @@ -395,7 +392,6 @@ rte_cryptodev_get_aead_algo_enum(enum rte_crypto_aead_algorithm *algo_enum, * - Return -1 if string is not valid * - Return 0 if the string is valid */ -__rte_experimental int rte_cryptodev_asym_get_xform_enum(enum rte_crypto_asym_xform_type *xform_enum, const char *xform_string); @@ -1192,7 +1188,6 @@ rte_cryptodev_sym_session_create(struct rte_mempool *mempool); * - On success return pointer to asym-session * - On failure returns NULL */ -__rte_experimental struct rte_cryptodev_asym_session * rte_cryptodev_asym_session_create(struct rte_mempool *mempool); @@ -1223,7 +1218,6 @@ rte_cryptodev_sym_session_free(struct rte_cryptodev_sym_session *sess); * - -EINVAL if session is NULL. * - -EBUSY if not all device private data has been freed. */ -__rte_experimental int rte_cryptodev_asym_session_free(struct rte_cryptodev_asym_session *sess); @@ -1264,7 +1258,6 @@ rte_cryptodev_sym_session_init(uint8_t dev_id, * - -ENOTSUP if crypto device does not support the crypto transform. * - -ENOMEM if the private session could not be allocated. */ -__rte_experimental int rte_cryptodev_asym_session_init(uint8_t dev_id, struct rte_cryptodev_asym_session *sess, @@ -1299,7 +1292,6 @@ rte_cryptodev_sym_session_clear(uint8_t dev_id, * - 0 if successful. * - -EINVAL if device is invalid or session is NULL. */ -__rte_experimental int rte_cryptodev_asym_session_clear(uint8_t dev_id, struct rte_cryptodev_asym_session *sess); @@ -1336,7 +1328,6 @@ rte_cryptodev_sym_get_existing_header_session_size( * @return * Size of the asymmetric header session. */ -__rte_experimental unsigned int rte_cryptodev_asym_get_header_session_size(void); @@ -1364,7 +1355,6 @@ rte_cryptodev_sym_get_private_session_size(uint8_t dev_id); * - Size of the asymmetric private data, if successful * - 0 if device is invalid or does not have private session */ -__rte_experimental unsigned int rte_cryptodev_asym_get_private_session_size(uint8_t dev_id); diff --git a/lib/cryptodev/version.map b/lib/cryptodev/version.map index 9f04737aed..707a2e32d3 100644 --- a/lib/cryptodev/version.map +++ b/lib/cryptodev/version.map @@ -1,4 +1,4 @@ -DPDK_21 { +DPDK_22 { global: rte_crypto_aead_algorithm_strings; @@ -9,6 +9,18 @@ DPDK_21 { rte_crypto_cipher_operation_strings; rte_crypto_op_pool_create; rte_cryptodev_allocate_driver; + + rte_cryptodev_asym_capability_get; + rte_cryptodev_asym_get_header_session_size; + rte_cryptodev_asym_get_private_session_size; + rte_cryptodev_asym_get_xform_enum; + rte_cryptodev_asym_session_clear; + rte_cryptodev_asym_session_create; + rte_cryptodev_asym_session_free; + rte_cryptodev_asym_session_init; + rte_cryptodev_asym_xform_capability_check_modlen; + rte_cryptodev_asym_xform_capability_check_optype; + rte_cryptodev_callback_register; rte_cryptodev_callback_unregister; rte_cryptodev_close; @@ -61,16 +73,6 @@ DPDK_21 { EXPERIMENTAL { global: - rte_cryptodev_asym_capability_get; - rte_cryptodev_asym_get_header_session_size; - rte_cryptodev_asym_get_private_session_size; - rte_cryptodev_asym_get_xform_enum; - rte_cryptodev_asym_session_clear; - rte_cryptodev_asym_session_create; - rte_cryptodev_asym_session_free; - rte_cryptodev_asym_session_init; - rte_cryptodev_asym_xform_capability_check_modlen; - rte_cryptodev_asym_xform_capability_check_optype; rte_cryptodev_sym_cpu_crypto_process; rte_cryptodev_sym_get_existing_header_session_size; rte_cryptodev_sym_session_get_user_data; From patchwork Sat Jul 31 18:13:26 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akhil Goyal X-Patchwork-Id: 96498 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 93C9CA0547; Sat, 31 Jul 2021 20:13:58 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DC51140DDB; Sat, 31 Jul 2021 20:13:56 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id C774940DDB for ; Sat, 31 Jul 2021 20:13:55 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 16VIATh3020458; Sat, 31 Jul 2021 11:13:51 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=kFxlBtKuOTObSiV6fhDvKl1m/xMu9NtDmp6jytsLA7Q=; b=NKdeNuP9B+xsMHawsQ1clCxsk9LioIRriXcaVAPVXyAKVi2oD5ACPwn7UAxbkz4Kxh5C 1Iwus+wmQHYJtQCU+OSMCHoIBkZWpIu3QuDDB/GCIRbb7mydjrKX+iOAaMZL3OP31MRL jrWxeGLXO6j+1/3ezeNymu3o1NeWqfbBnJdQEOHwBcGoHQ/X8OIIu2HTpHRUWMP13a1u u/pDOiMKa9paBSUGUHt0KJWKvWMfFWGQHphoLKA5xekEfX00ts0EFsjbXR7jW+mqEQPM c4cbM8brKjpRVB+3NqsjTQltYincthtEagjnoIZQjLGU6pgYSCZl5d8IXYV44MQc626P 1g== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0a-0016f401.pphosted.com with ESMTP id 3a53vr8xfx-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Sat, 31 Jul 2021 11:13:50 -0700 Received: from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Sat, 31 Jul 2021 11:13:49 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Sat, 31 Jul 2021 11:13:49 -0700 Received: from localhost.localdomain (unknown [10.28.36.185]) by maili.marvell.com (Postfix) with ESMTP id 864173F7075; Sat, 31 Jul 2021 11:13:45 -0700 (PDT) From: Akhil Goyal To: CC: , , , , , , , , , , , , , Akhil Goyal Date: Sat, 31 Jul 2021 23:43:26 +0530 Message-ID: <20210731181327.660296-4-gakhil@marvell.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210731181327.660296-1-gakhil@marvell.com> References: <20210731181327.660296-1-gakhil@marvell.com> MIME-Version: 1.0 X-Proofpoint-ORIG-GUID: UwHL-z-JSlfhmPVuMP2Gn4dz2mQwpVbN X-Proofpoint-GUID: UwHL-z-JSlfhmPVuMP2Gn4dz2mQwpVbN X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-07-31_05:2021-07-30, 2021-07-31 signatures=0 Subject: [dpdk-dev] [PATCH 3/4] security: hide internal API 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 Sender: "dev" rte_security_dynfield_register() is an internal API to be used by the driver, hence moving it to internal. Signed-off-by: Akhil Goyal Acked-by: Konstantin Ananyev --- lib/security/rte_security_driver.h | 2 +- lib/security/version.map | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/security/rte_security_driver.h b/lib/security/rte_security_driver.h index 938373205c..b0253e962e 100644 --- a/lib/security/rte_security_driver.h +++ b/lib/security/rte_security_driver.h @@ -89,7 +89,7 @@ typedef int (*security_session_stats_get_t)(void *device, struct rte_security_session *sess, struct rte_security_stats *stats); -__rte_experimental +__rte_internal int rte_security_dynfield_register(void); /** diff --git a/lib/security/version.map b/lib/security/version.map index 22775558c8..bd91d9a16c 100644 --- a/lib/security/version.map +++ b/lib/security/version.map @@ -16,8 +16,13 @@ EXPERIMENTAL { global: rte_security_dynfield_offset; - rte_security_dynfield_register; rte_security_get_userdata; rte_security_session_stats_get; rte_security_session_update; }; + +INTERNAL { + global: + + rte_security_dynfield_register; +}; From patchwork Sat Jul 31 18:13:27 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Akhil Goyal X-Patchwork-Id: 96499 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 C3D69A0547; Sat, 31 Jul 2021 20:14:03 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 105E4410FA; Sat, 31 Jul 2021 20:14:00 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by mails.dpdk.org (Postfix) with ESMTP id 32C5B40042 for ; Sat, 31 Jul 2021 20:13:59 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 16VIDqBc025488; Sat, 31 Jul 2021 11:13:56 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=NZ4qYPLbns5xnjBKQSZOtTtl2Odbu0lvFz99p4e9/ds=; b=NYAPm5eg/+AHBeeqI2mu8Cx/5IMsjjOevvT0ejqt3KlX/Yk7NzyEJFxxmQ32GUOrTRWW mtrB5LihpatcPDpBoD3SmYwE91Bq6pQnextr1XFERsS+oP5YlZAtAmh3n2wDa0t2mKN1 mtiH7IK0bCbQCTpGBIROXD+q6cSud8nxpcAbyLBG3fnsVKOmKRhjrr8Sy/1LOhDmCeRh A4+WpIFFp3LkSVOXlHDu5cn4GHYgHRw4JFhoepC78J/2QEMYtItRkNXh8jM/bGpsnkoO 7DCLv6/qlF7BSuMzsx4ojxi3xtSTXS+6bARYIxh8oSnaqvt09LWU3SkT2q6IU/aBJ7ma +g== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0b-0016f401.pphosted.com with ESMTP id 3a561rrmrv-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Sat, 31 Jul 2021 11:13:56 -0700 Received: from DC5-EXCH01.marvell.com (10.69.176.38) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Sat, 31 Jul 2021 11:13:54 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Sat, 31 Jul 2021 11:13:54 -0700 Received: from localhost.localdomain (unknown [10.28.36.185]) by maili.marvell.com (Postfix) with ESMTP id 1CA833F707A; Sat, 31 Jul 2021 11:13:49 -0700 (PDT) From: Akhil Goyal To: CC: , , , , , , , , , , , , , Akhil Goyal Date: Sat, 31 Jul 2021 23:43:27 +0530 Message-ID: <20210731181327.660296-5-gakhil@marvell.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210731181327.660296-1-gakhil@marvell.com> References: <20210731181327.660296-1-gakhil@marvell.com> MIME-Version: 1.0 X-Proofpoint-ORIG-GUID: 20mVWSaP5IcPwmePlOzZhC341k-_y4QC X-Proofpoint-GUID: 20mVWSaP5IcPwmePlOzZhC341k-_y4QC X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.391, 18.0.790 definitions=2021-07-31_05:2021-07-30, 2021-07-31 signatures=0 Subject: [dpdk-dev] [PATCH 4/4] security: add reserved bitfields 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 Sender: "dev" In struct rte_security_ipsec_sa_options, for every new option added, there is an ABI breakage, to avoid, a reserved_opts bitfield is added to for the remaining bits available in the structure. Now for every new sa option, these reserved_opts can be reduced and new option can be added. A corresponding exception is also added in devtools/libabigail.abignore Signed-off-by: Akhil Goyal Acked-by: Konstantin Ananyev --- devtools/libabigail.abignore | 4 ++++ lib/security/rte_security.h | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/devtools/libabigail.abignore b/devtools/libabigail.abignore index 93158405e0..5d8da28e55 100644 --- a/devtools/libabigail.abignore +++ b/devtools/libabigail.abignore @@ -52,3 +52,7 @@ ; https://sourceware.org/bugzilla/show_bug.cgi?id=28060 [suppress_type] name = rte_eth_dev_data + +; Ignore changes in reserved_opts bitfield of rte_security_ipsec_sa_options +[suppress_variable] + name = reserved_opts diff --git a/lib/security/rte_security.h b/lib/security/rte_security.h index 88d31de0a6..4606425e8d 100644 --- a/lib/security/rte_security.h +++ b/lib/security/rte_security.h @@ -181,6 +181,12 @@ struct rte_security_ipsec_sa_options { * * 0: Disable per session security statistics collection for this SA. */ uint32_t stats : 1; + + /** Reserved bit fields for future extension + * + * Note: reduce number of bits in reserved_opts for every new option + */ + uint32_t reserved_opts : 24; }; /** IPSec security association direction */