This patch add pdcp security short MAC-I support for dpaa_sec driver. Signed-off-by: Gagandeep Singh <g.si...@nxp.com> --- doc/guides/rel_notes/release_21_11.rst | 4 ++++ drivers/crypto/dpaa_sec/dpaa_sec.c | 3 +++ drivers/crypto/dpaa_sec/dpaa_sec.h | 11 ++++++++++- 3 files changed, 17 insertions(+), 1 deletion(-)
diff --git a/doc/guides/rel_notes/release_21_11.rst b/doc/guides/rel_notes/release_21_11.rst index b7e5128be5..7a07161f9d 100644 --- a/doc/guides/rel_notes/release_21_11.rst +++ b/doc/guides/rel_notes/release_21_11.rst @@ -81,6 +81,10 @@ New Features * Added PDCP short MAC-I support. +* **Updated NXP dpaa_sec crypto PMD.** + + * Added PDCP short MAC-I support. + Removed Items ------------- diff --git a/drivers/crypto/dpaa_sec/dpaa_sec.c b/drivers/crypto/dpaa_sec/dpaa_sec.c index fa4d276ead..d5aa2748d6 100644 --- a/drivers/crypto/dpaa_sec/dpaa_sec.c +++ b/drivers/crypto/dpaa_sec/dpaa_sec.c @@ -311,6 +311,9 @@ dpaa_sec_prep_pdcp_cdb(dpaa_sec_session *ses) ses->pdcp.hfn_threshold, &cipherdata, &authdata, 0); + } else if (ses->pdcp.domain == RTE_SECURITY_PDCP_MODE_SHORT_MAC) { + shared_desc_len = cnstr_shdsc_pdcp_short_mac(cdb->sh_desc, + 1, swap, &authdata); } else { if (ses->dir == DIR_ENC) { if (ses->pdcp.sdap_enabled) diff --git a/drivers/crypto/dpaa_sec/dpaa_sec.h b/drivers/crypto/dpaa_sec/dpaa_sec.h index c94d78e046..503047879e 100644 --- a/drivers/crypto/dpaa_sec/dpaa_sec.h +++ b/drivers/crypto/dpaa_sec/dpaa_sec.h @@ -1,6 +1,6 @@ /* SPDX-License-Identifier: BSD-3-Clause * - * Copyright 2016-2020 NXP + * Copyright 2016-2021 NXP * */ @@ -958,6 +958,15 @@ static const struct rte_security_capability dpaa_sec_security_cap[] = { }, .crypto_capabilities = dpaa_pdcp_capabilities }, + { /* PDCP Lookaside Protocol offload Short MAC */ + .action = RTE_SECURITY_ACTION_TYPE_LOOKASIDE_PROTOCOL, + .protocol = RTE_SECURITY_PROTOCOL_PDCP, + .pdcp = { + .domain = RTE_SECURITY_PDCP_MODE_SHORT_MAC, + .capa_flags = 0 + }, + .crypto_capabilities = dpaa_pdcp_capabilities + }, { .action = RTE_SECURITY_ACTION_TYPE_NONE } -- 2.25.1