baseband/acc100: support 4G CRC drop

This implements in PMD the option to drop the CB CRC
after 4G decoding to help transport block concatenation.

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
Reviewed-by: Tom Rix <trix@redhat.com>
This commit is contained in:
Nicolas Chautru 2021-09-07 18:15:39 -07:00 committed by Akhil Goyal
parent 10ea15e35f
commit 765f42f1bd
3 changed files with 14 additions and 3 deletions

View File

@ -58,6 +58,7 @@ ACC100 5G/4G FEC PMD supports the following BBDEV capabilities:
- ``RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN`` : set if negative LLR encoder i/p is supported
- ``RTE_BBDEV_TURBO_POS_LLR_1_BIT_IN`` : set if positive LLR encoder i/p is supported
- ``RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP`` : keep CRC24B bits appended while decoding
- ``RTE_BBDEV_TURBO_DEC_CRC_24B_DROP`` : option to drop the code block CRC after decoding
- ``RTE_BBDEV_TURBO_EARLY_TERMINATION`` : set early termination feature
- ``RTE_BBDEV_TURBO_DEC_SCATTER_GATHER`` : supports scatter-gather for input/output data
- ``RTE_BBDEV_TURBO_HALF_ITERATION_EVEN`` : set half iteration granularity

View File

@ -122,6 +122,10 @@ New Features
* Added PDCP short MAC-I support.
* **Updated the ACC100 bbdev PMD.**
Added support for more comprehensive CRC options.
* **Updated the turbo_sw bbdev PMD.**
Added support for more comprehensive CRC options.

View File

@ -980,6 +980,7 @@ acc100_dev_info_get(struct rte_bbdev *dev,
RTE_BBDEV_TURBO_NEG_LLR_1_BIT_IN |
RTE_BBDEV_TURBO_MAP_DEC |
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP |
RTE_BBDEV_TURBO_DEC_CRC_24B_DROP |
RTE_BBDEV_TURBO_DEC_SCATTER_GATHER,
.max_llr_modulus = INT8_MAX,
.num_buffers_src =
@ -1708,8 +1709,12 @@ acc100_dma_desc_td_fill(struct rte_bbdev_dec_op *op,
}
if ((op->turbo_dec.code_block_mode == RTE_BBDEV_TRANSPORT_BLOCK)
&& !check_bit(op->turbo_dec.op_flags,
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP))
&& !check_bit(op->turbo_dec.op_flags,
RTE_BBDEV_TURBO_DEC_TB_CRC_24B_KEEP))
crc24_overlap = 24;
if ((op->turbo_dec.code_block_mode == RTE_BBDEV_CODE_BLOCK)
&& check_bit(op->turbo_dec.op_flags,
RTE_BBDEV_TURBO_DEC_CRC_24B_DROP))
crc24_overlap = 24;
/* Calculates circular buffer size.
@ -1744,7 +1749,8 @@ acc100_dma_desc_td_fill(struct rte_bbdev_dec_op *op,
next_triplet = acc100_dma_fill_blk_type_out(
desc, h_output, *h_out_offset,
k >> 3, next_triplet, ACC100_DMA_BLKID_OUT_HARD);
k >> 3, next_triplet,
ACC100_DMA_BLKID_OUT_HARD);
if (unlikely(next_triplet < 0)) {
rte_bbdev_log(ERR,
"Mismatch between data to process and mbuf data length in bbdev_op: %p",