From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 000184568D; Tue, 23 Jul 2024 08:52:46 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7E5D6402D3; Tue, 23 Jul 2024 08:52:46 +0200 (CEST) Received: from mail.lysator.liu.se (mail.lysator.liu.se [130.236.254.3]) by mails.dpdk.org (Postfix) with ESMTP id 8C88A40289 for ; Tue, 23 Jul 2024 08:40:40 +0200 (CEST) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id 3FF65BE53 for ; Tue, 23 Jul 2024 08:40:40 +0200 (CEST) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id 34A09BECD; Tue, 23 Jul 2024 08:40:40 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on hermod.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=ALL_TRUSTED,AWL, T_SCC_BODY_TEXT_LINE autolearn=disabled version=4.0.0 X-Spam-Score: -1.3 Received: from [192.168.1.86] (h-62-63-215-114.A163.priv.bahnhof.se [62.63.215.114]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id 7F9F9BDDD; Tue, 23 Jul 2024 08:40:38 +0200 (CEST) Message-ID: <80d67453-5a63-40b5-82ea-6648738d932a@lysator.liu.se> Date: Tue, 23 Jul 2024 08:40:37 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v6 2/3] eventdev: add support for independent enqueue To: Abdullah Sevincer , dev@dpdk.org Cc: jerinj@marvell.com, bruce.richardson@intel.com, pravin.pathak@intel.com, mattias.ronnblom@ericsson.com, manish.aggarwal@intel.com References: <20240621222408.583464-3-abdullah.sevincer@intel.com> <20240711195444.2627373-1-abdullah.sevincer@intel.com> <20240711195444.2627373-3-abdullah.sevincer@intel.com> Content-Language: en-US From: =?UTF-8?Q?Mattias_R=C3=B6nnblom?= In-Reply-To: <20240711195444.2627373-3-abdullah.sevincer@intel.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On 2024-07-11 21:54, Abdullah Sevincer wrote: > This commit adds support for independent enqueue feature > and updates Event Device and PMD feature list. > > A new capability RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ is introduced > to support independent enqueue to support PMD to enqueue in any order > even the underlined hardware device needs enqueues in a strict dequeue > order. > > To use this capability applications need to set flag > RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ during port setup only if the > capability RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ exists. > > Signed-off-by: Abdullah Sevincer > --- > doc/guides/eventdevs/features/default.ini | 1 + > doc/guides/eventdevs/features/dlb2.ini | 1 + > doc/guides/rel_notes/release_24_07.rst | 5 ++++ > lib/eventdev/rte_eventdev.h | 36 +++++++++++++++++++++++ > 4 files changed, 43 insertions(+) > > diff --git a/doc/guides/eventdevs/features/default.ini b/doc/guides/eventdevs/features/default.ini > index 1cc4303fe5..7c4ee99238 100644 > --- a/doc/guides/eventdevs/features/default.ini > +++ b/doc/guides/eventdevs/features/default.ini > @@ -22,6 +22,7 @@ carry_flow_id = > maintenance_free = > runtime_queue_attr = > profile_links = > +independent_enq = > > ; > ; Features of a default Ethernet Rx adapter. > diff --git a/doc/guides/eventdevs/features/dlb2.ini b/doc/guides/eventdevs/features/dlb2.ini > index 7b80286927..c7193b47c1 100644 > --- a/doc/guides/eventdevs/features/dlb2.ini > +++ b/doc/guides/eventdevs/features/dlb2.ini > @@ -15,6 +15,7 @@ implicit_release_disable = Y > runtime_port_link = Y > multiple_queue_port = Y > maintenance_free = Y > +independent_enq = Y > > [Eth Rx adapter Features] > > diff --git a/doc/guides/rel_notes/release_24_07.rst b/doc/guides/rel_notes/release_24_07.rst > index 76a79093d1..d8564b19f0 100644 > --- a/doc/guides/rel_notes/release_24_07.rst > +++ b/doc/guides/rel_notes/release_24_07.rst > @@ -162,6 +162,11 @@ New Features > ``RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ`` to enable the feature if the capability > ``RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ`` exists. > > +* **Updated Event Device Library for independent enqueue feature** > + > + * Added support for independent enqueue feature. Updated Event Device and > + PMD feature list. > + > > Removed Items > ------------- > diff --git a/lib/eventdev/rte_eventdev.h b/lib/eventdev/rte_eventdev.h > index 08e5f9320b..462fc3f18f 100644 > --- a/lib/eventdev/rte_eventdev.h > +++ b/lib/eventdev/rte_eventdev.h > @@ -446,6 +446,30 @@ struct rte_event; > * @see RTE_SCHED_TYPE_PARALLEL > */ > > +#define RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ (1ULL << 16) > +/**< Event device is capable of independent enqueue. > + * A new capability, RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ, will indicate that Eventdev > + * supports the enqueue in any order or specifically in a different order than the > + * dequeue. Eventdev PMD can either transmit events in the changed order in which > + * they are enqueued or restore the original order before sending them to the > + * underlying hardware device. A flag is provided during the port configuration to > + * inform Eventdev PMD that the application intends to use an independent enqueue > + * order on a particular port. Note that this capability only matters for Eventdevs > + * supporting burst mode. > + * > + * To Inform PMD that the application plans to use independent enqueue order on a port > + * this code example can be used: > + * > + * if (capability & RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ) > + * port_config = port_config | RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ; > + * > + * When an implicit release is enabled on a port, Eventdev PMD will also handle > + * the insertion of RELEASE events in place of dropped events. The order restoration "The independent enqueue feature only applies to /../" maybe? > + * only applies to FORWARD and RELEASE events. New events (op=RTE_EVENT_OP_NEW) will > + * be transmitted in the order the application enqueues them. New events do not > + * maintain any order relative to FORWARD/RELEASE events. Is FORWARD<->NEW relaxed ordering specific to ports which has enabled RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ? If not, that information should probably be somewhere else. Either way, Reviewed-by: Mattias Rönnblom > + */ > + > /* Event device priority levels */ > #define RTE_EVENT_DEV_PRIORITY_HIGHEST 0 > /**< Highest priority level for events and queues. > @@ -1072,6 +1096,18 @@ rte_event_queue_attr_set(uint8_t dev_id, uint8_t queue_id, uint32_t attr_id, > * > * @see rte_event_port_setup() > */ > + #define RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ (1ULL << 5) > +/**< Flag to enable independent enqueue. Must not be set if the device > + * is not RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ capable. This feature > + * allows an application to enqueue RTE_EVENT_OP_FORWARD or > + * RTE_EVENT_OP_RELEASE in an order different than the order the > + * events were dequeued from the event device, while maintaining > + * RTE_SCHED_TYPE_ATOMIC or RTE_SCHED_TYPE_ORDERED semantics. > + * > + * Note that this flag only matters for Eventdevs supporting burst mode. > + * > + * @see rte_event_port_setup() > + */ > > /** Event port configuration structure */ > struct rte_event_port_conf {