From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 937D0A034E; Wed, 9 Feb 2022 16:39:06 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7C43F41144; Wed, 9 Feb 2022 16:39:06 +0100 (CET) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by mails.dpdk.org (Postfix) with ESMTP id C6B2E41143 for ; Wed, 9 Feb 2022 16:39:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1644421144; x=1675957144; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=pkCMRXzzanI41c6iKLYJhJivKL8aFhTsRg4KVQweLvE=; b=Fp+TT1XFEQBZoKKcYqNZHkBKqnk3b317/2I6L7IRmhbzX9kwMlxz+NZH RJ3pWed2x+ZoA+qBOfQA4il/mm1OebiIxflEfIPXlhcxpj5NIFaR5IjyE nxIR+mc05JmwvVdt844/LJfnjhfHbF8JrIFs8JXxYzKCT90/FgyOfyGtY yLYSNblyA8DXPRnP+L173teW46ec1QmtF+mk1ixaGgzODbyAMhr2amSYt 9/uFVKZ9P1rOsQe2bbUZSmJkE6oqW9KT3dJxcw+YaZ0zOW5M6sy1h2PM6 zeSCg/V272nBjQ17wsYnkGN2m6MoSs+ClHKVWPmbOydAN6rDBmKuZ7XDR Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10252"; a="312523435" X-IronPort-AV: E=Sophos;i="5.88,356,1635231600"; d="scan'208";a="312523435" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Feb 2022 07:39:01 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,356,1635231600"; d="scan'208";a="482362763" Received: from silpixa00400355.ir.intel.com (HELO silpixa00400355.ger.corp.intel.com) ([10.237.222.49]) by orsmga003.jf.intel.com with ESMTP; 09 Feb 2022 07:39:00 -0800 From: Ciara Power To: dev@dpdk.org Cc: roy.fan.zhang@intel.com, gakhil@marvell.com, anoobj@marvell.com, mdr@ashroe.eu, Ciara Power Subject: [PATCH v4 0/5] crypto: improve asym session usage Date: Wed, 9 Feb 2022 15:38:49 +0000 Message-Id: <20220209153854.2740455-1-ciara.power@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 patchset includes improvements for the asymmetric session. The main change is to the session structure, which is now a single mempool object, rather than having pointers to private data elsewhere. This session structure is now hidden in an internal header, so the app will never use it directly. Some other changes include adding a user data API, and modifying the return value for the create session function. This create session function now also initialises the session, and subsequently the clear/free functions have been merged into one. Sample code in the programmer's guide that showed basic steps for using Asymmetric crypto in DPDK has been replaced with literal includes in the first patch of this patchset. This ensures all subsequent code changes in the patchset are automatically reflected in the documentation. v4: - Added new patch to add literal includes usage in programmer's guide. - Merged asym crypto session clear and free functions. - Reordered some function parameters. - Updated trace function for asym crypto session create. - Fixed cnxk clear, the PMD no longer needs to put private data back into a mempool. - Renamed struct field for max private session size. - Replaced __extension__ with RTE_STD_C11. - Moved some parameter validity checks to before functional code. - Reworded release note. - Removed mempool parameter from session configure function. - Removed docs code additions, these are included due to patch 1 changing sample doc to use literal includes. - Initialised session variables as NULL. - Added possible error return values in user data API comment. Ciara Power (5): doc: replace asym crypto code with literal includes crypto: use single buffer for asymmetric session crypto: hide asym session structure crypto: add asym session user data API crypto: modify return value for asym session create app/test-crypto-perf/cperf_ops.c | 22 +- app/test-crypto-perf/cperf_test_throughput.c | 8 +- app/test/test_cryptodev_asym.c | 380 ++++++------------- app/test/test_cryptodev_mod_test_vectors.h | 4 + doc/guides/prog_guide/cryptodev_lib.rst | 212 +++-------- doc/guides/rel_notes/release_22_03.rst | 14 + drivers/crypto/cnxk/cn10k_cryptodev_ops.c | 6 +- drivers/crypto/cnxk/cn9k_cryptodev_ops.c | 6 +- drivers/crypto/cnxk/cnxk_cryptodev_ops.c | 21 +- drivers/crypto/cnxk/cnxk_cryptodev_ops.h | 3 +- drivers/crypto/octeontx/otx_cryptodev_ops.c | 30 +- drivers/crypto/openssl/rte_openssl_pmd.c | 5 +- drivers/crypto/openssl/rte_openssl_pmd_ops.c | 24 +- drivers/crypto/qat/qat_asym.c | 54 +-- drivers/crypto/qat/qat_asym.h | 5 +- lib/cryptodev/cryptodev_pmd.h | 36 +- lib/cryptodev/cryptodev_trace_points.c | 9 +- lib/cryptodev/rte_cryptodev.c | 258 ++++++++----- lib/cryptodev/rte_cryptodev.h | 133 ++++--- lib/cryptodev/rte_cryptodev_trace.h | 38 +- lib/cryptodev/version.map | 9 +- 21 files changed, 517 insertions(+), 760 deletions(-) -- 2.25.1