[PATCH 21.11] common/mlx5: fix error CQE handling for 128 bytes CQE

Kevin Traynor ktraynor at redhat.com
Tue Dec 3 18:54:54 CET 2024


On 03/12/2024 18:43, Kevin Traynor wrote:
> On 27/11/2024 18:48, Alexander Kozyrev wrote:
>> [ upstream commit 3cddeba0ca38b00c7dc646277484d08a4cb2d862 ]
>>
>> The completion queue element size can be independently configured
>> to report either 64 or 128 bytes CQEs by programming cqe_sz parameter
>> at CQ creation. This parameter depends on the cache line size and
>> affects both regular CQEs and error CQEs. But the error handling
>> assumes that an error CQE is 64 bytes and doesn't take the padding
>> into consideration on platforms with 128-byte cache lines.
>> Fix the error CQE size in all error handling routines in mlx5.
>>
> Hi Alexander,
> 
> This is causing a build error [1] on windows in the crypto code [2].
> 
> ref
> https://dpdkdashboard.iol.unh.edu/results/dashboard/testruns/logs/1475543/
> 
> I didn't spend time to analyse. If you have a fix I can apply, or else
> we can drop the patch.
> 
> thanks,
> Kevin.
> 
> [1]
> ../drivers/crypto/mlx5/mlx5_crypto.c
> ../drivers/crypto/mlx5/mlx5_crypto.c:480:52: error: incomplete
> definition of type 'struct mlx5_err_cqe'
>         DRV_LOG(ERR, "CQE ERR:%x.\n", rte_be_to_cpu_32(cqe->syndrome));
>                                                        ~~~^
> [2]
> mlx5_crypto_cqe_err_handle(struct mlx5_crypto_qp *qp, struct
> rte_crypto_op *op)
> {
> 	const uint32_t idx = qp->ci & (qp->entries_n - 1);
> 	volatile struct mlx5_err_cqe *cqe = (volatile struct mlx5_err_cqe *)
> 							&qp->cq_obj.cqes[idx];
> 
> 	op->status = RTE_CRYPTO_OP_STATUS_ERROR;
> 	qp->stats.dequeue_err_count++;
> 	DRV_LOG(ERR, "CQE ERR:%x.\n", rte_be_to_cpu_32(cqe->syndrome));
> }
> 

btw, the code that was run is ahead of the 21.11 branch.

It is at: https://dpdk.org/git/dpdk-stable on branch 21.11-staging



More information about the stable mailing list