[dpdk-dev] crypto/qat: fix process type handling
David Marchand
david.marchand at redhat.com
Tue Mar 1 09:00:51 CET 2022
On Mon, Feb 28, 2022 at 6:36 PM Kai Ji <kai.ji at intel.com> wrote:
>
> This patch fix the process type handling in QAT PMDs where
> only primary and secondary process are supported in qat
> build request
>
> Signed-off-by: Kai Ji <kai.ji at intel.com>
> ---
> drivers/crypto/qat/dev/qat_crypto_pmd_gen3.c | 3 +++
> drivers/crypto/qat/dev/qat_crypto_pmd_gen4.c | 3 +++
> drivers/crypto/qat/dev/qat_sym_pmd_gen1.c | 3 +++
> drivers/crypto/qat/qat_sym.c | 8 ++++----
> 4 files changed, 13 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/crypto/qat/dev/qat_crypto_pmd_gen3.c b/drivers/crypto/qat/dev/qat_crypto_pmd_gen3.c
> index 5084a5fcd1..739404b1d4 100644
> --- a/drivers/crypto/qat/dev/qat_crypto_pmd_gen3.c
> +++ b/drivers/crypto/qat/dev/qat_crypto_pmd_gen3.c
> @@ -358,6 +358,9 @@ qat_sym_crypto_set_session_gen3(void *cdev __rte_unused, void *session)
> enum rte_proc_type_t proc_type = rte_eal_process_type();
> int ret;
>
> + if (proc_type < 0 || proc_type == RTE_PROC_INVALID)
> + return -EINVAL;
This is not supposed to happen after rte_eal_init() is called.
I have a doubt on Windows init because I can't see where
rte_config.process_type is initialised.
Are you seeing this issue on Windows?
In any case, the commitlog needs more explanation.
--
David Marchand
More information about the dev
mailing list