test/crypto-perf: support SDAP for PDCP operations
[dpdk.git] / app / test-crypto-perf / cperf_test_verify.c
index 496eb0d..5c0dc82 100644 (file)
@@ -42,8 +42,7 @@ cperf_verify_test_free(struct cperf_verify_ctx *ctx)
                        rte_cryptodev_sym_session_free(ctx->sess);
                }
 
-               if (ctx->pool)
-                       rte_mempool_free(ctx->pool);
+               rte_mempool_free(ctx->pool);
 
                rte_free(ctx);
        }
@@ -196,42 +195,6 @@ out:
        return !!res;
 }
 
-static void
-cperf_mbuf_set(struct rte_mbuf *mbuf,
-               const struct cperf_options *options,
-               const struct cperf_test_vector *test_vector)
-{
-       uint32_t segment_sz = options->segment_sz;
-       uint8_t *mbuf_data;
-       uint8_t *test_data;
-       uint32_t remaining_bytes = options->max_buffer_size;
-
-       if (options->op_type == CPERF_AEAD) {
-               test_data = (options->aead_op == RTE_CRYPTO_AEAD_OP_ENCRYPT) ?
-                                       test_vector->plaintext.data :
-                                       test_vector->ciphertext.data;
-       } else {
-               test_data =
-                       (options->cipher_op == RTE_CRYPTO_CIPHER_OP_ENCRYPT) ?
-                               test_vector->plaintext.data :
-                               test_vector->ciphertext.data;
-       }
-
-       while (remaining_bytes) {
-               mbuf_data = rte_pktmbuf_mtod(mbuf, uint8_t *);
-
-               if (remaining_bytes <= segment_sz) {
-                       memcpy(mbuf_data, test_data, remaining_bytes);
-                       return;
-               }
-
-               memcpy(mbuf_data, test_data, segment_sz);
-               remaining_bytes -= segment_sz;
-               test_data += segment_sz;
-               mbuf = mbuf->next;
-       }
-}
-
 int
 cperf_verify_test_runner(void *test_ctx)
 {