[4/4] crypto/qat: disable asym and compression for new gen3 device

Message ID 20231219155124.4133385-5-ciara.power@intel.com (mailing list archive)
State Superseded, archived
Delegated to: akhil goyal
Series add new QAT gen3 device |


Context Check Description
ci/checkpatch success coding style OK
ci/loongarch-compilation success Compilation OK
ci/loongarch-unit-testing success Unit Testing PASS
ci/Intel-compilation success Compilation OK
ci/github-robot: build success github build: passed
ci/intel-Testing success Testing PASS
ci/intel-Functional success Functional PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-unit-amd64-testing success Testing PASS
ci/iol-compile-amd64-testing success Testing PASS
ci/iol-abi-testing success Testing PASS
ci/iol-unit-arm64-testing success Testing PASS
ci/iol-sample-apps-testing success Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-compile-arm64-testing success Testing PASS

Commit Message

Ciara Power Dec. 19, 2023, 3:51 p.m. UTC
  Currently only symmetric crypto has been added for the new gen3 device,
adding a check to disable asym and comp PMDs for this device.

Signed-off-by: Ciara Power <ciara.power@intel.com>
 drivers/compress/qat/qat_comp_pmd.c | 3 ++-
 drivers/crypto/qat/qat_asym.c       | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)


diff --git a/drivers/compress/qat/qat_comp_pmd.c b/drivers/compress/qat/qat_comp_pmd.c
index 6fb8cf69be..bdc35b5949 100644
--- a/drivers/compress/qat/qat_comp_pmd.c
+++ b/drivers/compress/qat/qat_comp_pmd.c
@@ -687,7 +687,8 @@  qat_comp_dev_create(struct qat_pci_device *qat_pci_dev,
 			qat_pci_dev->name, "comp");
 	QAT_LOG(DEBUG, "Creating QAT COMP device %s", name);
-	if (qat_comp_gen_ops->compressdev_ops == NULL) {
+	if (qat_comp_gen_ops->compressdev_ops == NULL ||
+			qat_dev_instance->pci_dev->id.device_id == 0x578b) {
 		QAT_LOG(DEBUG, "Device %s does not support compression", name);
 		return -ENOTSUP;
diff --git a/drivers/crypto/qat/qat_asym.c b/drivers/crypto/qat/qat_asym.c
index 2bf3060278..036813e977 100644
--- a/drivers/crypto/qat/qat_asym.c
+++ b/drivers/crypto/qat/qat_asym.c
@@ -1522,7 +1522,8 @@  qat_asym_dev_create(struct qat_pci_device *qat_pci_dev,
 			qat_pci_dev->name, "asym");
 	QAT_LOG(DEBUG, "Creating QAT ASYM device %s\n", name);
-	if (gen_dev_ops->cryptodev_ops == NULL) {
+	if (gen_dev_ops->cryptodev_ops == NULL ||
+			qat_dev_instance->pci_dev->id.device_id == 0x578b) {
 		QAT_LOG(ERR, "Device %s does not support asymmetric crypto",
 		return -(EFAULT);