git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
net/bnxt: update TruFlow resource allocation numbers
[dpdk.git]
/
drivers
/
crypto
/
qat
/
qat_sym.c
diff --git
a/drivers/crypto/qat/qat_sym.c
b/drivers/crypto/qat/qat_sym.c
index
6d568ab
..
e6bf115
100644
(file)
--- a/
drivers/crypto/qat/qat_sym.c
+++ b/
drivers/crypto/qat/qat_sym.c
@@
-108,18
+108,18
@@
qat_crc_generate(struct qat_sym_session *ctx,
struct rte_crypto_op *op)
{
struct rte_crypto_sym_op *sym_op = op->sym;
struct rte_crypto_op *op)
{
struct rte_crypto_sym_op *sym_op = op->sym;
- uint32_t *crc, crc_
length
;
+ uint32_t *crc, crc_
data_len
;
uint8_t *crc_data;
if (ctx->qat_dir == ICP_QAT_HW_CIPHER_ENCRYPT &&
sym_op->auth.data.length != 0) {
uint8_t *crc_data;
if (ctx->qat_dir == ICP_QAT_HW_CIPHER_ENCRYPT &&
sym_op->auth.data.length != 0) {
- crc_
length
= sym_op->auth.data.length;
+ crc_
data_len
= sym_op->auth.data.length;
crc_data = rte_pktmbuf_mtod_offset(sym_op->m_src, uint8_t *,
sym_op->auth.data.offset);
crc_data = rte_pktmbuf_mtod_offset(sym_op->m_src, uint8_t *,
sym_op->auth.data.offset);
- crc = (uint32_t *)(crc_data + crc_
length
);
+ crc = (uint32_t *)(crc_data + crc_
data_len
);
- *crc = rte_net_crc_calc(crc_data, crc_
length
,
+ *crc = rte_net_crc_calc(crc_data, crc_
data_len
,
RTE_NET_CRC32_ETH);
}
}
RTE_NET_CRC32_ETH);
}
}
@@
-284,13
+284,15
@@
qat_sym_build_request(void *in_op, uint8_t *out_msg,
/* DOCSIS processing */
#ifdef RTE_LIBRTE_SECURITY
if (is_docsis_sec) {
/* DOCSIS processing */
#ifdef RTE_LIBRTE_SECURITY
if (is_docsis_sec) {
- /* Check for OOP */
- if (unlikely((op->sym->m_dst != NULL) &&
+ /* Check for OOP
or multi-segment buffers
*/
+ if (unlikely((
(
op->sym->m_dst != NULL) &&
(op->sym->m_dst !=
(op->sym->m_dst !=
- op->sym->m_src))) {
+ op->sym->m_src)) ||
+ op->sym->m_src->nb_segs > 1)) {
QAT_DP_LOG(ERR,
QAT_DP_LOG(ERR,
- "OOP not supported for DOCSIS "
- "security");
+ "OOP and/or multi-segment "
+ "buffers are not supported for "
+ "DOCSIS security");
op->status =
RTE_CRYPTO_OP_STATUS_INVALID_ARGS;
return -EINVAL;
op->status =
RTE_CRYPTO_OP_STATUS_INVALID_ARGS;
return -EINVAL;