Acked-by: Abhinandan Gujjar <abhinandan.guj...@intel.com>

> -----Original Message-----
> From: Kundapura, Ganapati <ganapati.kundap...@intel.com>
> Sent: Thursday, February 10, 2022 11:11 PM
> To: Jayatheerthan, Jay <jay.jayatheert...@intel.com>;
> jerinjac...@gmail.com; Gujjar, Abhinandan S
> <abhinandan.guj...@intel.com>; dev@dpdk.org
> Subject: [PATCH v5 2/2] eventdev: update crypto caps get to return SW cap
> 
> update rte_event_crypto_adapter_caps_get() to return SW_CAP if PMD
> callback is not registered.
> 
> Signed-off-by: Ganapati Kundapura <ganapati.kundap...@intel.com>
> 
> diff --git a/lib/eventdev/rte_eventdev.c b/lib/eventdev/rte_eventdev.c
> index 79b9ea3..6988bf1 100644
> --- a/lib/eventdev/rte_eventdev.c
> +++ b/lib/eventdev/rte_eventdev.c
> @@ -176,11 +176,15 @@ rte_event_crypto_adapter_caps_get(uint8_t
> dev_id, uint8_t cdev_id,
> 
>       if (caps == NULL)
>               return -EINVAL;
> -     *caps = 0;
> +
> +     if (dev->dev_ops->crypto_adapter_caps_get == NULL)
> +             *caps = RTE_EVENT_CRYPTO_ADAPTER_SW_CAP;
> +     else
> +             *caps = 0;
> 
>       return dev->dev_ops->crypto_adapter_caps_get ?
>               (*dev->dev_ops->crypto_adapter_caps_get)
> -             (dev, cdev, caps) : -ENOTSUP;
> +             (dev, cdev, caps) : 0;
>  }
> 
>  int
> --
> 2.6.4

Reply via email to