Go to file
Matan Azrad d014dddb2d cryptodev: support multiple cipher data-units
In cryptography, a block cipher is a deterministic algorithm operating
on fixed-length groups of bits, called blocks.

A block cipher consists of two paired algorithms, one for encryption
and the other for decryption. Both algorithms accept two inputs:
an input block of size n bits and a key of size k bits; and both yield
an n-bit output block. The decryption algorithm is defined to be the
inverse function of the encryption.

For AES standard the block size is 16 bytes.
For AES in XTS mode, the data to be encrypted\decrypted does not have to
be multiple of 16B size, the unit of data is called data-unit.
The data-unit size can be any size in range [16B, 2^24B], so, in this
case, a data stream is divided into N amount of equal data-units and
must be encrypted\decrypted in the same data-unit resolution.

For ABI compatibility reason, the size is limited to 64K (16-bit field).
The new field dataunit_len is inserted in a struct padding hole,
which is only 2 bytes long in 32-bit build.
It could be moved and extended later during an ABI-breakage window.

The current cryptodev API doesn't allow the user to select a specific
data-unit length supported by the devices.
In addition, there is no definition how the IV is detected per data-unit
when single operation includes more than one data-unit.

That causes applications to use single operation per data-unit even though
all the data is continuous in memory what reduces datapath performance.

Add a new feature flag to support multiple data-unit sizes, called
RTE_CRYPTODEV_FF_CIPHER_MULTIPLE_DATA_UNITS.
Add a new field in cipher capability, called dataunit_set,
where the devices can report the range of the supported data-unit sizes.
Add a new cipher transformation field, called dataunit_len, where the user
can select the data-unit length for all the operations.

All the new fields do not change the size of their structures,
by filling some struct padding holes.
They are added as exceptions in the ABI check file libabigail.abignore.

Using a bitmap to report the supported data-unit sizes capability allows
the devices to report a range simply as same as the user to read it
simply. also, thus sizes are usually common and probably will be shared
among different devices.

Signed-off-by: Matan Azrad <matan@nvidia.com>
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Akhil Goyal <gakhil@marvell.com>
2021-04-16 12:43:33 +02:00
.ci ci: fix ABI reference generation 2021-04-16 14:09:03 +02:00
.github/workflows ci: bump ABI reference version 2021-04-16 14:09:03 +02:00
app app/crypto-perf: close device after benchmark run 2021-04-16 12:43:33 +02:00
buildtools config: enable/disable drivers in Arm builds 2021-04-15 22:34:37 +02:00
config config/arm: fix implementer and its SoCs 2021-04-15 22:34:37 +02:00
devtools cryptodev: support multiple cipher data-units 2021-04-16 12:43:33 +02:00
doc cryptodev: support multiple cipher data-units 2021-04-16 12:43:33 +02:00
drivers crypto/qat: fix offset for out-of-place scatter-gather 2021-04-16 12:43:33 +02:00
examples examples/l2fwd-crypto: fix packet length while decryption 2021-04-16 12:43:33 +02:00
kernel build: support KNI cross-compilation 2021-03-15 23:43:40 +01:00
lib cryptodev: support multiple cipher data-units 2021-04-16 12:43:33 +02:00
license license: fix typos 2021-04-13 13:56:52 +02:00
usertools usertools: show hugepages requested/set on failure 2021-03-25 18:07:47 +01:00
.editorconfig devtools: add EditorConfig file 2020-02-22 21:05:22 +01:00
.gitattributes improve git diff 2016-11-13 15:25:12 +01:00
.gitignore regex/mlx5: introduce driver for BlueField 2 2020-07-21 19:04:05 +02:00
.travis.yml ci: bump ABI reference version 2021-04-16 14:09:03 +02:00
ABI_VERSION version: 21.05-rc0 2021-02-15 11:08:19 +01:00
MAINTAINERS pflock: add phase-fair reader writer locks 2021-04-14 21:59:47 +02:00
Makefile build: create dummy Makefile 2020-09-07 23:51:57 +02:00
meson_options.txt config/arm: add platform config option 2021-04-15 22:34:37 +02:00
meson.build build: enable a developer mode setting 2021-04-09 19:07:25 +02:00
README license: introduce SPDX identifiers 2018-01-04 22:41:38 +01:00
VERSION version: 21.05-rc0 2021-02-15 11:08:19 +01:00

DPDK is a set of libraries and drivers for fast packet processing.
It supports many processor architectures and both FreeBSD and Linux.

The DPDK uses the Open Source BSD-3-Clause license for the core libraries
and drivers. The kernel components are GPL-2.0 licensed.

Please check the doc directory for release notes,
API documentation, and sample application information.

For questions and usage discussions, subscribe to: users@dpdk.org
Report bugs and issues to the development mailing list: dev@dpdk.org