Skip to content

Introduce CPU crypto mode

Marcin Smoczynski dpdk-dev 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v6 Latest8 patches 7 repliesIn review
  2. v58 patches 9 repliesSuperseded
  3. v48 patches 4 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v36 patches16 repliesSuperseded

Changes in v6 from the cover letter

- unit tests integrated in the current test application for cryptodev
- iova fix
- moved mbuf to sgl helper function to crypo sym header

Patches in v6 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8cryptodev: introduce cpu crypto support APIdoc/guides/cryptodevs/features/default.ini doc/guides/prog_guide/cryptodev_lib.rst lib/librte_cryptodev/rte_crypto_sym.h +4 more+236 -55 replies
2/8crypto/aesni_gcm: cpu crypto supportdoc/guides/cryptodevs/aesni_gcm.rst doc/guides/cryptodevs/features/aesni_gcm.ini drivers/crypto/aesni_gcm/aesni_gcm_ops.h +3 more+247 -110 replies
3/8security: add cpu crypto action typedoc/guides/prog_guide/rte_security.rst lib/librte_security/rte_security.h+17 -61 reply
4/8test/crypto: add cpu crypto mode to testsapp/test/test_cryptodev.c+151 -105 replies
5/8ipsec: introduce support for cpu crypto modedoc/guides/prog_guide/ipsec_lib.rst lib/librte_ipsec/esp_inb.c lib/librte_ipsec/esp_outb.c +5 more+475 -581 reply
6/8examples/ipsec-secgw: cpu crypto supportexamples/ipsec-secgw/ipsec.c examples/ipsec-secgw/ipsec_process.c examples/ipsec-secgw/sa.c+131 -601 reply
7/8examples/ipsec-secgw: cpu crypto testingexamples/ipsec-secgw/test/common_defs.sh examples/ipsec-secgw/test/linux_test4.sh examples/ipsec-secgw/test/linux_test6.sh +6 more+47 -440 replies
8/8doc: add release notes for cpu cryptodoc/guides/rel_notes/release_20_02.rst+7 -00 replies

Reviews trailers per patch

7 of 8 patches have a Reviewed-by or Acked-by.

PatchPablo de LaraFan ZhangKonstantin AnanyevAkhil Goyal
1/8A-b A-b
2/8A-b A-b T-b A-b
3/8A-b A-b A-b
4/8T-b A-b A-b
5/8A-b T-b A-b
6/8A-b A-b
7/8A-b
8/8

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.

Read the v6 thread

Cover letter [dpdk-dev] [PATCH v6 0/8] Introduce CPU crypto mode

Originally both SW and HW crypto PMDs use rte_crypot_op based API to process the crypto workload asynchronously. This way provides uniformity to both PMD types, but also introduce unnecessary performance penalty to SW PMDs that have to "simulate" HW async behavior (crypto-ops enqueue/dequeue, HW addresses computations, storing/dereferencing user provided data (mbuf) for each crypto-op, etc).

The aim is to introduce a new optional API for SW crypto-devices to perform crypto processing in a synchronous manner.

v3 to v4 changes:
- add feature discovery in the ipsec example application when using cpu-crypto
- add gmac in aesni-gcm
- add tests for aesni-gcm/cpu crypto mode
- add documentation: pg and rel notes
- remove xform flags as no longer needed
- add some extra API comments
- remove compilation error from v3

v4 to v5 changes:
- fixed build error for arm64 (missing header include)
- update licensing information

v5 to v6 changes:
- unit tests integrated in the current test application for cryptodev
- iova fix
- moved mbuf to sgl helper function to crypo sym header

Marcin Smoczynski (8):
cryptodev: introduce cpu crypto support API
crypto/aesni_gcm: cpu crypto support
security: add cpu crypto action type
test/crypto: add cpu crypto mode to tests
ipsec: introduce support for cpu crypto mode
examples/ipsec-secgw: cpu crypto support
examples/ipsec-secgw: cpu crypto testing
doc: add release notes for cpu crypto

 app/test/test_cryptodev.c                     | 161 ++++++++++++-
 doc/guides/cryptodevs/aesni_gcm.rst           |   7 +-
 doc/guides/cryptodevs/features/aesni_gcm.ini  |   1 +
 doc/guides/cryptodevs/features/default.ini    |   1 +
 doc/guides/prog_guide/cryptodev_lib.rst       |  33 ++-
 doc/guides/prog_guide/ipsec_lib.rst           |  10 +-
 doc/guides/prog_guide/rte_security.rst        |  15 +-
 doc/guides/rel_notes/release_20_02.rst        |   7 +
 drivers/crypto/aesni_gcm/aesni_gcm_ops.h      |  11 +-
 drivers/crypto/aesni_gcm/aesni_gcm_pmd.c      | 222 +++++++++++++++++-
 drivers/crypto/aesni_gcm/aesni_gcm_pmd_ops.c  |   4 +-
 .../crypto/aesni_gcm/aesni_gcm_pmd_private.h  |  13 +-
 examples/ipsec-secgw/ipsec.c                  |  25 +-
 examples/ipsec-secgw/ipsec_process.c          | 136 +++++++----
 examples/ipsec-secgw/sa.c                     |  30 ++-
 examples/ipsec-secgw/test/common_defs.sh      |  21 ++
 examples/ipsec-secgw/test/linux_test4.sh      |  11 +-
 examples/ipsec-secgw/test/linux_test6.sh      |  11 +-
 .../test/trs_3descbc_sha1_common_defs.sh      |   8 +-
 .../test/trs_aescbc_sha1_common_defs.sh       |   8 +-
 .../test/trs_aesctr_sha1_common_defs.sh       |   8 +-
 .../test/tun_3descbc_sha1_common_defs.sh      |   8 +-
 .../test/tun_aescbc_sha1_common_defs.sh       |   8 +-
 .../test/tun_aesctr_sha1_common_defs.sh       |   8 +-
 lib/librte_cryptodev/rte_crypto_sym.h         | 128 +++++++++-
 lib/librte_cryptodev/rte_cryptodev.c          |  35 ++-
 lib/librte_cryptodev/rte_cryptodev.h          |  22 +-
 lib/librte_cryptodev/rte_cryptodev_pmd.h      |  21 +-
 .../rte_cryptodev_version.map                 |   1 +
 lib/librte_ipsec/esp_inb.c                    | 156 ++++++++++--
 lib/librte_ipsec/esp_outb.c                   | 136 ++++++++++-
 lib/librte_ipsec/misc.h                       |  73 +++++-
 lib/librte_ipsec/rte_ipsec.h                  |  20 +-
 lib/librte_ipsec/sa.c                         | 114 +++++++--
 lib/librte_ipsec/sa.h                         |  19 +-
 lib/librte_ipsec/ses.c                        |   5 +-
 lib/librte_security/rte_security.h            |   8 +-
 37 files changed, 1311 insertions(+), 194 deletions(-)
Signature · 1 line
2.17.1