summaryrefslogtreecommitdiff
path: root/drivers/common
diff options
context:
space:
mode:
authorFiona Trahe <fiona.trahe@intel.com>2018-10-26 19:18:30 +0100
committerThomas Monjalon <thomas@monjalon.net>2018-10-27 01:30:21 +0200
commita124830a6f00cf767372f98542449b7470f3dfab (patch)
treef02c8e2508c9543878418f45625cd6e048c38179 /drivers/common
parenta72a1ef34e75f40efc0a2051f55d555af9138e9c (diff)
downloaddpdk-next-eventdev-a124830a6f00cf767372f98542449b7470f3dfab.zip
dpdk-next-eventdev-a124830a6f00cf767372f98542449b7470f3dfab.tar.gz
dpdk-next-eventdev-a124830a6f00cf767372f98542449b7470f3dfab.tar.xz
compress/qat: enable dynamic huffman encoding
Enable dynamic huffman encoding in the QAT comp PMD. Signed-off-by: Tomasz Jozwiak <tomaszx.jozwiak@intel.com> Signed-off-by: Fiona Trahe <fiona.trahe@intel.com> Acked-by: Arek Kusztal <arkadiuszx.kusztal@intel.com>
Diffstat (limited to 'drivers/common')
-rw-r--r--drivers/common/qat/qat_device.c4
-rw-r--r--drivers/common/qat/qat_device.h7
2 files changed, 11 insertions, 0 deletions
diff --git a/drivers/common/qat/qat_device.c b/drivers/common/qat/qat_device.c
index 4ff8b88..2a1cf3e 100644
--- a/drivers/common/qat/qat_device.c
+++ b/drivers/common/qat/qat_device.c
@@ -7,6 +7,7 @@
#include "qat_device.h"
#include "adf_transport_access_macros.h"
#include "qat_sym_pmd.h"
+#include "qat_comp_pmd.h"
/* Hardware device information per generation */
__extension__
@@ -14,15 +15,18 @@ struct qat_gen_hw_data qat_gen_config[] = {
[QAT_GEN1] = {
.dev_gen = QAT_GEN1,
.qp_hw_data = qat_gen1_qps,
+ .comp_num_im_bufs_required = QAT_NUM_INTERM_BUFS_GEN1
},
[QAT_GEN2] = {
.dev_gen = QAT_GEN2,
.qp_hw_data = qat_gen1_qps,
/* gen2 has same ring layout as gen1 */
+ .comp_num_im_bufs_required = QAT_NUM_INTERM_BUFS_GEN2
},
[QAT_GEN3] = {
.dev_gen = QAT_GEN3,
.qp_hw_data = qat_gen3_qps,
+ .comp_num_im_bufs_required = QAT_NUM_INTERM_BUFS_GEN3
},
};
diff --git a/drivers/common/qat/qat_device.h b/drivers/common/qat/qat_device.h
index 3a71cd4..eb81c78 100644
--- a/drivers/common/qat/qat_device.h
+++ b/drivers/common/qat/qat_device.h
@@ -16,6 +16,12 @@
#define QAT_DEV_NAME_MAX_LEN 64
+enum qat_comp_num_im_buffers {
+ QAT_NUM_INTERM_BUFS_GEN1 = 12,
+ QAT_NUM_INTERM_BUFS_GEN2 = 20,
+ QAT_NUM_INTERM_BUFS_GEN3 = 20
+};
+
/*
* This struct holds all the data about a QAT pci device
* including data about all services it supports.
@@ -72,6 +78,7 @@ struct qat_pci_device {
struct qat_gen_hw_data {
enum qat_device_gen dev_gen;
const struct qat_qp_hw_data (*qp_hw_data)[ADF_MAX_QPS_ON_ANY_SERVICE];
+ enum qat_comp_num_im_buffers comp_num_im_bufs_required;
};
extern struct qat_gen_hw_data qat_gen_config[];