Add zsda cryptodev capabilities.
Signed-off-by: Hanxiao Li
---
doc/guides/compressdevs/features/zsda.ini | 9 +++++
doc/guides/compressdevs/zsda.rst | 46 +++++++++++++----------
drivers/compress/zsda/zsda_comp_pmd.c | 15 +++++++-
3 files changed, 49 insertions(+), 21 deletions(-)
diff --git a/doc/guides/compressdevs/features/zsda.ini b/doc/guides/compressdevs/features/zsda.ini
index 5cc9a3b1a6..3b087ea7f9 100644
--- a/doc/guides/compressdevs/features/zsda.ini
+++ b/doc/guides/compressdevs/features/zsda.ini
@@ -4,3 +4,12 @@
; Supported features of 'ZSDA' compression driver.
;
[Features]
+HW Accelerated = Y
+OOP SGL In SGL Out = Y
+OOP SGL In LB Out = Y
+OOP LB In SGL Out = Y
+Deflate = Y
+Adler32 = Y
+Crc32 = Y
+Fixed = Y
+Dynamic = Y
diff --git a/doc/guides/compressdevs/zsda.rst b/doc/guides/compressdevs/zsda.rst
index 56d4ca5245..6e3be87805 100644
--- a/doc/guides/compressdevs/zsda.rst
+++ b/doc/guides/compressdevs/zsda.rst
@@ -13,6 +13,29 @@ support for the following hardware accelerator devices:
Features
--------
+ZSDA compression PMD has support for:
+
+Compression/Decompression algorithm:
+
+ * DEFLATE - using Fixed and Dynamic Huffman encoding
+
+Checksum generation:
+
+ * CRC32, Adler32
+
+Huffman code type:
+
+* FIXED
+* DYNAMIC
+
+
+Limitations
+-----------
+
+* Compressdev level 0, no compression, is not supported.
+* No BSD support as BSD ZSDA kernel driver not available.
+* Stateful is not supported.
+
Limitations
@@ -193,24 +216,7 @@ ZSDA compression PMD can be tested by running the test application::
Debugging
~~~~~~~~~
-There are 2 sets of trace available via the dynamic logging feature:
-
-* pmd.zsda.dp exposes trace on the data-path.
-* pmd.zsda.general exposes all other trace.
-
-pmd.zsda exposes both sets of traces.
-They can be enabled using the log-level option (where 8=maximum log level) on
-the process cmdline, e.g. using any of the following::
-
- --log-level="pmd.zsda.general,8"
- --log-level="pmd.zsda.dp,8"
-
-.. Note::
-
- The global RTE_LOG_DP_LEVEL overrides data-path trace so must be set to
- RTE_LOG_DEBUG to see all the trace. This variable is in config/rte_config.h
- for meson build.
- Also the dynamic global log level overrides both sets of trace, so e.g. no
- ZSDA trace would display in this case::
+ZSDA logging feature can be enabled using the log-level option (where 8=maximum
+log level) on the process cmdline, e.g. using any of the following::
- --log-level="pmd.zsda.general,8" --log-level="pmd.zsda,8"
+ --log-level="gen,8"
diff --git a/drivers/compress/zsda/zsda_comp_pmd.c b/drivers/compress/zsda/zsda_comp_pmd.c
index ea3de2f505..85c934ace1 100644
--- a/drivers/compress/zsda/zsda_comp_pmd.c
+++ b/drivers/compress/zsda/zsda_comp_pmd.c
@@ -9,6 +9,19 @@
#include "zsda_comp_pmd.h"
#include "zsda_comp.h"
+static const struct rte_compressdev_capabilities zsda_comp_capabilities[] = {
+ {
+ .algo = RTE_COMP_ALGO_DEFLATE,
+ .comp_feature_flags = RTE_COMP_FF_HUFFMAN_DYNAMIC |
+ RTE_COMP_FF_OOP_SGL_IN_SGL_OUT |
+ RTE_COMP_FF_OOP_SGL_IN_LB_OUT |
+ RTE_COMP_FF_OOP_LB_IN_SGL_OUT |
+ RTE_COMP_FF_CRC32_CHECKSUM |
+ RTE_COMP_FF_ADLER32_CHECKSUM,
+ .window_size = {.min = 15, .max = 15, .increment = 0},
+ },
+};
+
static int
zsda_comp_xform_size(void)
{
@@ -405,7 +418,7 @@ zsda_comp_dev_create(struct zsda_pci_device *zsda_pci_dev)
comp_dev->zsda_pci_dev = zsda_pci_dev;
comp_dev->compressdev = compressdev;
- capabilities = NULL;
+ capabilities = zsda_comp_capabilities;
comp_dev->capa_mz = rte_memzone_lookup(capa_memz_name);
if (comp_dev->capa_mz == NULL) {
--
2.27.0