Commit f546f28e authored by Kamil Godzwon's avatar Kamil Godzwon Committed by Tomasz Zawadzki
Browse files

pkgdep/patches: remove qat patches



Remove QAT patches as they are no longer needed

Signed-off-by: default avatarKamil Godzwon <kamilx.godzwon@intel.com>
Change-Id: Ibfbe2087aac9431b0b7c8e2addeef555e407bf40
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12994


Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Reviewed-by: default avatarBen Walker <benjamin.walker@intel.com>
Reviewed-by: default avatarPawel Piatek <pawelx.piatek@intel.com>
parent 7493be13
Loading
Loading
Loading
Loading
+0 −28
Original line number Diff line number Diff line
Cipher routines were moved to their own header file and the symbol exports
are now available under a new namespace, CRYPTO_INTERNAL.

Details: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0eb76ba29d16df2951d37c54ca279c4e5630b071
---

diff --git a/quickassist/lookaside/access_layer/src/linux/icp_qa_module.c b/quickassist/lookaside/access_layer/src/linux/icp_qa_module.c
index 413eb07..f7d09bd 100644
--- a/quickassist/lookaside/access_layer/src/linux/icp_qa_module.c
+++ b/quickassist/lookaside/access_layer/src/linux/icp_qa_module.c
@@ -120,3 +120,4 @@ module_exit(kapi_mod_exit);
 MODULE_DESCRIPTION("Intel(R) Quickassist Technology Acceleration Driver");
 MODULE_AUTHOR("Intel");
 MODULE_LICENSE("Dual BSD/GPL");
+MODULE_IMPORT_NS(CRYPTO_INTERNAL);
diff --git a/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c b/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
index 9d2e85c..f265422 100644
--- a/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
+++ b/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
@@ -65,7 +65,7 @@
  */
 
 #include "Osal.h"
-#include <linux/crypto.h>
+#include <crypto/internal/cipher.h>
 #include <linux/version.h>
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29))
 #include <crypto/internal/hash.h>
+0 −17
Original line number Diff line number Diff line
cryptohash.h was dropped and merged with crypto/sha.sh in 5.8 kernel. Details in:
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=228c4f265c6eb60eaa4ed0edb3bf7c113173576c

---
diff --git a/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c b/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
index 4c389da..e602377 100644
--- a/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
+++ b/quickassist/utilities/osal/src/linux/kernel_space/OsalCryptoInterface.c
@@ -66,7 +66,7 @@
 
 #include "Osal.h"
 #include <linux/crypto.h>
-#include <linux/cryptohash.h>
+#include <crypto/sha.h>
 #include <linux/version.h>
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,29))
 #include <crypto/internal/hash.h>
+0 −20
Original line number Diff line number Diff line
In kernel 5.7 the pci_cleanup_aer_uncorrect_error_status() function was
renamed with the following commit:

git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=894020fdd88c1e9a74c60b67c0f19f1c7696ba2f

This simply updates the function call with the proper name (pci_aer_clear_nonfatal_status()).

---
diff --git a/quickassist/qat/drivers/crypto/qat/qat_common/adf_aer.c b/quickassist/qat/drivers/crypto/qat/qat_common/adf_aer.c
index a6ce6df..545bb79 100644
--- a/quickassist/qat/drivers/crypto/qat/qat_common/adf_aer.c
+++ b/quickassist/qat/drivers/crypto/qat/qat_common/adf_aer.c
@@ -304,7 +304,7 @@ static pci_ers_result_t adf_slot_reset(struct pci_dev *pdev)
 		pr_err("QAT: Can't find acceleration device\n");
 		return PCI_ERS_RESULT_DISCONNECT;
 	}
-	pci_cleanup_aer_uncorrect_error_status(pdev);
+	pci_aer_clear_nonfatal_status(pdev);
 	if (adf_dev_aer_schedule_reset(accel_dev, ADF_DEV_RESET_SYNC))
 		return PCI_ERS_RESULT_DISCONNECT;
+0 −26
Original line number Diff line number Diff line
Latest kernels available for centos8 (4.18) include backport patches which
dropped use of pci_cleanup_aer_uncorrect_error_status(). Make sure this
call won't be referenced for kernels older than 5.7. To make it work, this
patch is going to be applied only when pci_cleanup_aer_uncorrect_error_status()
is not detected in older kernels (like the centos8's builds).
---
 quickassist/qat/compat/qat_compat.h | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/quickassist/qat/compat/qat_compat.h b/quickassist/qat/compat/qat_compat.h
index 06d640d..cee298c 100644
--- a/quickassist/qat/compat/qat_compat.h
+++ b/quickassist/qat/compat/qat_compat.h
@@ -478,12 +478,6 @@ static inline void pci_ignore_hotplug(struct pci_dev *dev)
 #define QAT_KPT_CAP_DISCOVERY
 #endif
 
-#if ((SLE_VERSION_CODE && (SLE_VERSION(15, 2, 0) > SLE_VERSION_CODE)) || \
-	(!SLE_VERSION_CODE && KERNEL_VERSION(5, 7, 0) > LINUX_VERSION_CODE))
-#define pci_aer_clear_nonfatal_status(pdev) \
-			pci_cleanup_aer_uncorrect_error_status(pdev)
-#endif /* SUSE15 SP2 */
-
 #if (KERNEL_VERSION(3, 17, 0) > LINUX_VERSION_CODE)
 #ifndef ktime_get_real_ts64
 #define ktime_get_real_ts64 getnstimeofday
+0 −21
Original line number Diff line number Diff line
Due to git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit?id=6212804f2d78e86f15dba5b46a4065cbf1403cde
built-in objects are not being built for the external modules anymore. To mitigate, don't set obj-m to an empty
list to force the build.

---
diff --git a/quickassist/build_system/build_files/OS/linux_2.6_kernel_space_rules.mk b/quickassist/build_system/build_files/OS/linux_2.6_kernel_space_rules.mk
index 71bbeb7..324fa96 100644
--- a/quickassist/build_system/build_files/OS/linux_2.6_kernel_space_rules.mk
+++ b/quickassist/build_system/build_files/OS/linux_2.6_kernel_space_rules.mk
@@ -72,7 +72,7 @@ endif
 
 $(LIB_STATIC): dirs
 	@echo 'Creating static library ${LIB_STATIC}'; \
-	$(MAKE) -C $(KERNEL_SOURCE_ROOT)/ M=$(PWD) obj-m=""; \
+	$(MAKE) -C $(KERNEL_SOURCE_ROOT)/ M=$(PWD); \
 	echo 'Copying outputs';\
 	test -f lib.a  &&  (ar -t lib.a | xargs ar -rcsD $(LIB_STATIC)); \
 	test -f $(LIB_STATIC)  &&  mv -f $(LIB_STATIC) $($(PROG_ACY)_FINAL_OUTPUT_DIR)/$(LIB_STATIC); \
-- 
2.26.2
Loading