From fe1f26de59cb4a26eca477fd3f340445443cc633 Mon Sep 17 00:00:00 2001 From: Tomasz Zawadzki Date: Thu, 19 Jan 2023 16:36:14 +0100 Subject: [PATCH] dpdk/crypto: define NO_COMPAT_IMB_API_053 intel-ipsec-mb added NO_COMPAT_IMB_API_053 to allow for backwards compatiblity for certain enums. See intel-ipsec-mb patch: (53a8371)Document and use new compilation flag NO_COMPAT_IMB_API_053 Meanwhile starting with DPDK 22.07, qat crypto updated the required intel-ipsec-mb and disabled OPENSSL_API_COMPAT. Resulting in redefinitions from aes.h. Patch breaking it: (3227bc7)crypto/qat: use intel-ipsec-mb for partial hash and AES Only _after_ DPDK 22.11 it was fixed: (2a21107) crypto/qat: fix build This means that DPDK 22.07 and DPDK 22.11.1 does not work with latest intel-ipsec-mb. It does not affect earlier versions of DPDK, nor intel-ipsec-mb. Only for this case, if the DPDK fix is not present, define NO_COMPAT_IMB_API_053. Change-Id: Ibe2edc5c79ac09b5260eeb0f7d53b4dcb26bcaa5 Signed-off-by: Tomasz Zawadzki Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/16359 Reviewed-by: Jim Harris Reviewed-by: Paul Luse Reviewed-by: Konrad Sztyber Reviewed-by: Aleksey Marchuk Reviewed-by: Krzysztof Karas Tested-by: SPDK CI Jenkins --- dpdkbuild/Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dpdkbuild/Makefile b/dpdkbuild/Makefile index cefae048c..6a5b65389 100644 --- a/dpdkbuild/Makefile +++ b/dpdkbuild/Makefile @@ -59,6 +59,11 @@ endif ifeq ($(CONFIG_IPSEC_MB),y) DPDK_DRIVERS += crypto/ipsec_mb DPDK_CFLAGS += -I$(IPSEC_MB_DIR) +# Workaround for DPDK 22.07 and DPDK 22.11.1, +# will be able to remove starting with DPDK 23.03. +ifeq ($(shell grep "#define NO_COMPAT_IMB_API_053" $(SPDK_ROOT_DIR)/dpdk/drivers/crypto/qat/qat_sym_session.c), ) +DPDK_CFLAGS += -DNO_COMPAT_IMB_API_053 +endif DPDK_LDFLAGS += -L$(IPSEC_MB_DIR) endif endif