1 #ifndef NDNDPDK_DPDK_CRYPTODEV_H
2 #define NDNDPDK_DPDK_CRYPTODEV_H
6 #include "../core/common.h"
7 #include <rte_cryptodev.h>
27 __attribute__((nonnull))
static inline void
28 CryptoQueuePair_PrepareSha256(
CryptoQueuePair* cqp,
struct rte_crypto_op* op,
struct rte_mbuf* m,
29 uint32_t offset, uint32_t length, uint8_t* output) {
30 __rte_crypto_op_reset(op, RTE_CRYPTO_OP_TYPE_SYMMETRIC);
32 op->sym->auth.data.offset = offset;
33 op->sym->auth.data.length = length;
34 op->sym->auth.digest.data = output;
35 int res = rte_crypto_op_attach_sym_session(op, cqp->
sha256sess);
#define NDNDPDK_ASSERT(x)
Definition: common.h:60
struct CryptoQueuePair CryptoQueuePair
Crypto queue pair.
struct rte_crypto_sym_xform CryptoDev_Sha256Xform
Definition: cryptodev.c:3
Crypto queue pair.
Definition: cryptodev.h:12
uint8_t dev
Definition: cryptodev.h:14
uint16_t qp
Definition: cryptodev.h:15
void * sha256sess
Definition: cryptodev.h:13