From: "Kundapura, Ganapati" <ganapati.kundapura@intel.com>
To: "Gujjar, Abhinandan S" <abhinandan.gujjar@intel.com>,
"dev@dpdk.org" <dev@dpdk.org>,
"jerinj@marvell.com" <jerinj@marvell.com>,
"Naga Harish K, S V" <s.v.naga.harish.k@intel.com>
Cc: "Jayatheerthan, Jay" <jay.jayatheerthan@intel.com>
Subject: RE: [PATCH v2 1/5] eventdev/event_crypto: process event port's impl rel cap
Date: Wed, 7 Dec 2022 06:53:17 +0000 [thread overview]
Message-ID: <MW4PR11MB59117E81FC6E79C7DC99F852871A9@MW4PR11MB5911.namprd11.prod.outlook.com> (raw)
In-Reply-To: <PH0PR11MB5832F73CD7F2F6654CD05934E81B9@PH0PR11MB5832.namprd11.prod.outlook.com>
Hi Abhi,
> -----Original Message-----
> From: Gujjar, Abhinandan S <abhinandan.gujjar@intel.com>
> Sent: Tuesday, December 6, 2022 9:14 PM
> To: Kundapura, Ganapati <ganapati.kundapura@intel.com>; dev@dpdk.org;
> jerinj@marvell.com; Naga Harish K, S V <s.v.naga.harish.k@intel.com>
> Cc: Jayatheerthan, Jay <jay.jayatheerthan@intel.com>
> Subject: RE: [PATCH v2 1/5] eventdev/event_crypto: process event port's
> impl rel cap
>
>
>
> > -----Original Message-----
> > From: Kundapura, Ganapati <ganapati.kundapura@intel.com>
> > Sent: Thursday, December 1, 2022 12:17 PM
> > To: dev@dpdk.org; jerinj@marvell.com; Naga Harish K, S V
> > <s.v.naga.harish.k@intel.com>; Gujjar, Abhinandan S
> > <abhinandan.gujjar@intel.com>
> > Cc: Jayatheerthan, Jay <jay.jayatheerthan@intel.com>
> > Subject: [PATCH v2 1/5] eventdev/event_crypto: process event port's
> > impl rel cap
> >
> > In the current implementation adapter queries event device's
> > capability for implicit release support.
> >
> > This information is used to decide whether events are enqueued back as
> > NEW or FWD events.
> >
> > This patch updates the adapter to query the port caps for implicit
> > release to decide on events enqueuing back as NEW/FWD events.
> >
> > Signed-off-by: Ganapati Kundapura <ganapati.kundapura@intel.com>
> > ---
> > v2:
> > * Updated subject line in commit message
> >
> > diff --git a/lib/eventdev/rte_event_crypto_adapter.c
> > b/lib/eventdev/rte_event_crypto_adapter.c
> > index 3c585d7..1c0a22b 100644
> > --- a/lib/eventdev/rte_event_crypto_adapter.c
> > +++ b/lib/eventdev/rte_event_crypto_adapter.c
> > @@ -53,7 +53,7 @@ struct event_crypto_adapter {
> > uint8_t eventdev_id;
> > /* Event port identifier */
> > uint8_t event_port_id;
> > - /* Store event device's implicit release capability */
> > + /* Store event port's implicit release capability */
> > uint8_t implicit_release_disabled;
> > /* Flag to indicate backpressure at cryptodev
> > * Stop further dequeuing events from eventdev @@ -320,7 +320,6
> @@
> > rte_event_crypto_adapter_create_ext(uint8_t id, uint8_t dev_id, {
> > struct event_crypto_adapter *adapter;
> > char mem_name[CRYPTO_ADAPTER_NAME_LEN];
> > - struct rte_event_dev_info dev_info;
> > int socket_id;
> > uint8_t i;
> > int ret;
> > @@ -361,17 +360,6 @@ rte_event_crypto_adapter_create_ext(uint8_t id,
> > uint8_t dev_id,
> > return -ENOMEM;
> > }
> >
> > - ret = rte_event_dev_info_get(dev_id, &dev_info);
> > - if (ret < 0) {
> > - RTE_EDEV_LOG_ERR("Failed to get info for eventdev %d:
> > %s!",
> > - dev_id, dev_info.driver_name);
> > - eca_circular_buffer_free(&adapter->ebuf);
> > - rte_free(adapter);
> > - return ret;
> > - }
> > -
> > - adapter->implicit_release_disabled = (dev_info.event_dev_cap &
> > - RTE_EVENT_DEV_CAP_IMPLICIT_RELEASE_DISABLE);
> > adapter->eventdev_id = dev_id;
> > adapter->socket_id = socket_id;
> > adapter->conf_cb = conf_cb;
> > @@ -837,6 +825,7 @@ eca_init_service(struct event_crypto_adapter
> > *adapter, uint8_t id)
> > struct rte_event_crypto_adapter_conf adapter_conf;
> > struct rte_service_spec service;
> > int ret;
> > + uint32_t impl_rel;
> >
> > if (adapter->service_inited)
> > return 0;
> > @@ -866,6 +855,17 @@ eca_init_service(struct event_crypto_adapter
> > *adapter, uint8_t id)
> >
> > adapter->max_nb = adapter_conf.max_nb;
> > adapter->event_port_id = adapter_conf.event_port_id;
> > +
> > + if (rte_event_port_attr_get(adapter->eventdev_id,
> > + adapter->event_port_id,
> > +
> > RTE_EVENT_PORT_ATTR_IMPLICIT_RELEASE_DISABLE,
> > + &impl_rel)) {
> > + RTE_EDEV_LOG_ERR("Failed to get port info for eventdev %"
> > PRId32,
> > + adapter->eventdev_id);
> You need to free memory allocated for adapter + adapter->ebuf before
> returning error
Updated in V3
> > + return -EINVAL;
> > + }
> > +
> > + adapter->implicit_release_disabled = (uint8_t)impl_rel;
> > adapter->service_inited = 1;
> >
> > return ret;
> > --
> > 2.6.4
next prev parent reply other threads:[~2022-12-07 6:53 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-30 17:10 [PATCH v1 " Ganapati Kundapura
2022-11-30 17:10 ` [PATCH v1 2/5] eventdev/crypto: wrong crypto enqueue count stats Ganapati Kundapura
2022-12-01 6:07 ` Naga Harish K, S V
2022-12-01 6:56 ` Kundapura, Ganapati
2022-11-30 17:10 ` [PATCH v1 3/5] eventdev/crypto: wrong offset used while flushing events Ganapati Kundapura
2022-11-30 17:10 ` [PATCH v1 4/5] eventdev/crypto: overflow in circular buffer Ganapati Kundapura
2022-11-30 17:10 ` [PATCH v1 5/5] eventdev/crypto: add all failed events to " Ganapati Kundapura
2022-12-01 6:46 ` [PATCH v2 1/5] eventdev/event_crypto: process event port's impl rel cap Ganapati Kundapura
2022-12-01 6:46 ` [PATCH v2 2/5] eventdev/crypto: fix wrong crypto enqueue count stats Ganapati Kundapura
2022-12-05 11:34 ` [EXT] " Volodymyr Fialko
2022-12-07 5:40 ` Gujjar, Abhinandan S
2022-12-01 6:46 ` [PATCH v2 3/5] eventdev/crypto: fix wrong offset used while flushing events Ganapati Kundapura
2022-12-05 11:35 ` [EXT] " Volodymyr Fialko
2022-12-06 16:17 ` Gujjar, Abhinandan S
2022-12-01 6:46 ` [PATCH v2 4/5] eventdev/crypto: fix overflow in circular buffer Ganapati Kundapura
2022-12-05 11:37 ` [EXT] " Volodymyr Fialko
2022-12-06 16:25 ` Gujjar, Abhinandan S
2022-12-07 6:53 ` Kundapura, Ganapati
2022-12-01 6:46 ` [PATCH v2 5/5] eventdev/crypto: add all failed events to " Ganapati Kundapura
2022-12-05 11:37 ` [EXT] " Volodymyr Fialko
2022-12-06 16:37 ` Gujjar, Abhinandan S
2022-12-01 13:20 ` [EXT] [PATCH v2 1/5] eventdev/event_crypto: process event port's impl rel cap Volodymyr Fialko
2022-12-06 15:44 ` Gujjar, Abhinandan S
2022-12-07 6:53 ` Kundapura, Ganapati [this message]
2022-12-07 6:49 ` [PATCH v3 " Ganapati Kundapura
2022-12-07 6:49 ` [PATCH v3 2/5] eventdev/crypto: fix wrong crypto enqueue count stats Ganapati Kundapura
2022-12-07 6:55 ` Gujjar, Abhinandan S
2022-12-07 6:49 ` [PATCH v3 3/5] eventdev/crypto: fix wrong offset used while flushing events Ganapati Kundapura
2022-12-07 6:55 ` Gujjar, Abhinandan S
2022-12-07 6:49 ` [PATCH v3 4/5] eventdev/crypto: fix overflow in circular buffer Ganapati Kundapura
2022-12-07 7:04 ` Gujjar, Abhinandan S
2022-12-07 6:49 ` [PATCH v3 5/5] eventdev/crypto: fix failed events Ganapati Kundapura
2022-12-07 6:56 ` Gujjar, Abhinandan S
2023-01-12 12:59 ` Jerin Jacob
2022-12-07 6:54 ` [PATCH v3 1/5] eventdev/event_crypto: process event port's impl rel cap Gujjar, Abhinandan S
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=MW4PR11MB59117E81FC6E79C7DC99F852871A9@MW4PR11MB5911.namprd11.prod.outlook.com \
--to=ganapati.kundapura@intel.com \
--cc=abhinandan.gujjar@intel.com \
--cc=dev@dpdk.org \
--cc=jay.jayatheerthan@intel.com \
--cc=jerinj@marvell.com \
--cc=s.v.naga.harish.k@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).