DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH -v1] Update num_ops type to be uint32_t in rte_bbdev_enc_op_alloc_bulk
@ 2021-11-16  5:12 Zhang, Mingshan
  2021-11-16  5:12 ` [PATCH -v1] SCSY-51090 ACC100 Padding 5GDL input BLEN Zhang, Mingshan
  0 siblings, 1 reply; 2+ messages in thread
From: Zhang, Mingshan @ 2021-11-16  5:12 UTC (permalink / raw)
  To: dev, akhil.goyal; +Cc: nicolas.chautru, Zhang, Mingshan

From: "Zhang, Mingshan" <mingshan.zhang@intel.com>

Update num_ops type from uint16_t to uint32_t in rte_bbdev_enc_op_alloc_bulk to enlarge the input range.

Nicolas Chautru (1):
  SCSY-51090 ACC100 Padding 5GDL input BLEN

 drivers/baseband/acc100/rte_acc100_pmd.c | 22 +++++++++++++---------
 1 file changed, 13 insertions(+), 9 deletions(-)

-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [PATCH -v1] SCSY-51090 ACC100 Padding 5GDL input BLEN
  2021-11-16  5:12 [PATCH -v1] Update num_ops type to be uint32_t in rte_bbdev_enc_op_alloc_bulk Zhang, Mingshan
@ 2021-11-16  5:12 ` Zhang, Mingshan
  0 siblings, 0 replies; 2+ messages in thread
From: Zhang, Mingshan @ 2021-11-16  5:12 UTC (permalink / raw)
  To: dev, akhil.goyal; +Cc: nicolas.chautru

From: Nicolas Chautru <nicolas.chautru@intel.com>

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
 drivers/baseband/acc100/rte_acc100_pmd.c | 22 +++++++++++++---------
 1 file changed, 13 insertions(+), 9 deletions(-)

diff --git a/drivers/baseband/acc100/rte_acc100_pmd.c b/drivers/baseband/acc100/rte_acc100_pmd.c
index 392b0f9..794ebcc 100644
--- a/drivers/baseband/acc100/rte_acc100_pmd.c
+++ b/drivers/baseband/acc100/rte_acc100_pmd.c
@@ -1694,6 +1694,15 @@ static inline uint32_t hq_index(uint32_t offset)
 	return 0;
 }
 
+/* May need to pad LDPC Encoder input to avoid small beat */
+static inline uint16_t pad_le_in(uint16_t blen)
+{
+	uint16_t last_beat = blen % 64;
+	if ((last_beat > 0) && (last_beat <= 8))
+		blen += 8;
+	return blen;
+}
+
 static inline int
 acc100_dma_desc_le_fill(struct rte_bbdev_enc_op *op,
 		struct acc100_dma_req_desc *desc, struct rte_mbuf **input,
@@ -1722,10 +1731,9 @@ static inline uint32_t hq_index(uint32_t offset)
 	}
 
 	next_triplet = acc100_dma_fill_blk_type_in(desc, input, in_offset,
-			in_length_in_bytes,
+			pad_le_in(in_length_in_bytes),
 			seg_total_left, next_triplet,
-			check_bit(op->ldpc_enc.op_flags,
-			RTE_BBDEV_LDPC_ENC_SCATTER_GATHER));
+			false);
 	if (unlikely(next_triplet < 0)) {
 		rte_bbdev_log(ERR,
 				"Mismatch between data to process and mbuf data length in bbdev_op: %p",
@@ -2689,6 +2697,7 @@ static inline uint32_t hq_index(uint32_t offset)
 	return 1;
 }
 
+
 /* Enqueue one encode operations for ACC100 device in CB mode
  * multiplexed on the same descriptor
  */
@@ -2719,7 +2728,7 @@ static inline uint32_t hq_index(uint32_t offset)
 	acc100_header_init(&desc->req);
 	desc->req.numCBs = num;
 
-	in_length_in_bytes = ops[0]->ldpc_enc.input.data->data_len;
+	in_length_in_bytes = pad_le_in(ops[0]->ldpc_enc.input.data->data_len);
 	out_length = (enc->cb_params.e + 7) >> 3;
 	desc->req.m2dlen = 1 + num;
 	desc->req.d2mlen = num;
@@ -4252,9 +4261,6 @@ static inline uint32_t hq_index(uint32_t offset)
 
 	/* Clearing status, it will be set based on response */
 	op->status = 0;
-
-	op->status |= ((rsp.input_err)
-			? (1 << RTE_BBDEV_DATA_ERROR) : 0);
 	op->status |= ((rsp.dma_err) ? (1 << RTE_BBDEV_DRV_ERROR) : 0);
 	op->status |= ((rsp.fcw_err) ? (1 << RTE_BBDEV_DRV_ERROR) : 0);
 
@@ -4332,8 +4338,6 @@ static inline uint32_t hq_index(uint32_t offset)
 				rsp.val, descs_in_tb,
 				desc->req.numCBs);
 
-		op->status |= ((rsp.input_err)
-				? (1 << RTE_BBDEV_DATA_ERROR) : 0);
 		op->status |= ((rsp.dma_err) ? (1 << RTE_BBDEV_DRV_ERROR) : 0);
 		op->status |= ((rsp.fcw_err) ? (1 << RTE_BBDEV_DRV_ERROR) : 0);
 
-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-11-16 10:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-16  5:12 [PATCH -v1] Update num_ops type to be uint32_t in rte_bbdev_enc_op_alloc_bulk Zhang, Mingshan
2021-11-16  5:12 ` [PATCH -v1] SCSY-51090 ACC100 Padding 5GDL input BLEN Zhang, Mingshan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).