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 79D7645AB8; Sat, 5 Oct 2024 09:02:58 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 49166402E6; Sat, 5 Oct 2024 09:02:58 +0200 (CEST) Received: from mail-qt1-f181.google.com (mail-qt1-f181.google.com [209.85.160.181]) by mails.dpdk.org (Postfix) with ESMTP id B89B34028C for ; Sat, 5 Oct 2024 09:02:56 +0200 (CEST) Received: by mail-qt1-f181.google.com with SMTP id d75a77b69052e-4582fb3822eso17132101cf.1 for ; Sat, 05 Oct 2024 00:02:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1728111776; x=1728716576; darn=dpdk.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=GkjKxBpcXiDexWKpusuhgZxvctqMljr9xC2QqLAGsgI=; b=OfjgFC9WKKSe+Z8eLSO+ZBFxDe4VxY5/Sc8WCwBpKPMPS9xMr7ijP1qI+IotfqEGr9 M25vtIhiZvKZJ1dhcEyhrNdUkEzl4b3FEuYysr3dh9YpsvD7ApwQS+keD6AY2hRVXV6i BYrkOTYUIdLCPLSIdbj8AviCd2BkDDSK2bEY9cuKZPn8iGV84jiSA6OYCqt1XgEZGlEU W/ILdL9YQ3/8YUYWjXQYK+jX1O9fAX3WC5yCqUNNUXRB1gV9mx1BipreTVfwgmEzBxr9 S4XbvM9L51AcRkimbUmX88pFPCXBdrDfNp3wGe+L623YubZw1jYliuTGYjOrt4OrLGQw Ytvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728111776; x=1728716576; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GkjKxBpcXiDexWKpusuhgZxvctqMljr9xC2QqLAGsgI=; b=qW25pxmXLhbDFVaG/R9JdOrUG6eDkai7bBbAidNz93ub+UYvufdgC6zAsB8EGsDaqc f69SRq45jgrzWWmLTQT4qFcfEI6pPZYyAJzlTlFCA4KU7yQR7pNKl6xpmz4X3+OmAJSM Vm86HKN4tnIFq9rABHAptYWn0WLIwjSvC3xgCN2eXSTDpmacyJqWfWxsEAv1l5BC1ts6 8Ov4i6ha1AwhewTKv/Dxf5QAwdg60Nmm9gDKvLYatwlxwZiAap++2yP14i0DTim4+RGb frLU+kv9vO9kvfC0mSez3HfZV50fg9fXMoLrdNqWqzE/iBC0IdCaj5sxhMkWV28iobmB jQBg== X-Gm-Message-State: AOJu0Ywkom8MGVmARaEjZsSydYSHTj2XQ9KOa6b9ARz4eTEllTre3pLl I6dA2JU4i7y9V7w+Tge6CQ1uH3yzKBcXBMuc78sZP7lkNai60hOiLXQHktWiljC0CZ2FP1Z/JmS NCJbShyJxKZ2NHLXNWSFEOke1uqo= X-Google-Smtp-Source: AGHT+IGOcGrJDGAHwi1geRl7hDprGz6aYKEL0Eww1dg/SML7gimTo4sf7aAeR/gMkJTdYjWy8/Vy94PFWd1lFcfyneI= X-Received: by 2002:ac8:5991:0:b0:458:417f:89cb with SMTP id d75a77b69052e-45d9ba38648mr68029741cf.19.1728111776013; Sat, 05 Oct 2024 00:02:56 -0700 (PDT) MIME-Version: 1.0 References: <20240909160506.2655354-3-abdullah.sevincer@intel.com> <20241003203658.4090323-1-abdullah.sevincer@intel.com> <20241003203658.4090323-3-abdullah.sevincer@intel.com> In-Reply-To: <20241003203658.4090323-3-abdullah.sevincer@intel.com> From: Jerin Jacob Date: Sat, 5 Oct 2024 12:32:29 +0530 Message-ID: Subject: Re: [PATCH v13 2/3] event/dlb2: add support for independent enqueue To: Abdullah Sevincer Cc: dev@dpdk.org, jerinj@marvell.com, bruce.richardson@intel.com, pravin.pathak@intel.com, mattias.ronnblom@ericsson.com, manish.aggarwal@intel.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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 Fri, Oct 4, 2024 at 6:34=E2=80=AFPM Abdullah Sevincer wrote: > > DLB devices need events to be enqueued in the same order they are > dequeued. Applications are not suppose to change event order between > dequeue and to enqueue. Since Eventdev standard does not add such > restrictions independent enqueue support is needed for DLB PMD so that > it restores dequeue order on enqueue if applications happen to change > it. It also adds missing releases in places where events are dropped > by the application and it expects implicit release to handle it. > > By default the feature will be off on all DLB ports and they will > behave the same as older releases. To enable reordering feature, > applications need to add the flag RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ > to port configuration if only the device advertises the capability > RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ. > > Signed-off-by: Abdullah Sevincer > Acked-by: Mattias R=C3=B6nnblom > --- > doc/guides/prog_guide/eventdev/eventdev.rst | 33 ++ > doc/guides/rel_notes/release_24_11.rst | 5 + > drivers/event/dlb2/dlb2.c | 490 +++++++++++++------- > drivers/event/dlb2/dlb2_avx512.c | 27 +- > drivers/event/dlb2/dlb2_inline_fns.h | 8 + > drivers/event/dlb2/dlb2_priv.h | 25 +- > drivers/event/dlb2/rte_pmd_dlb2.h | 24 + > 7 files changed, 422 insertions(+), 190 deletions(-) > > diff --git a/doc/guides/prog_guide/eventdev/eventdev.rst b/doc/guides/pro= g_guide/eventdev/eventdev.rst > index fb6dfce102..dd22ab69d2 100644 > --- a/doc/guides/prog_guide/eventdev/eventdev.rst > +++ b/doc/guides/prog_guide/eventdev/eventdev.rst > +Independent Enqueue Capability > +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > + > +Some eventdev hardware devices such as DLB2 expects all forwarded events= to be Remove DLB2 from _generic+ documentation. Instead, express with capability. > +enqueued in the same order as they are dequeued. For dropped events, the= ir > +releases should come at the same location as the original event was expe= cted. > +Hardware has this restriction as it uses the order to retrieve informati= on about > +the original event that was sent to the CPU. This contains information l= ike atomic flow > +ID to release the flow lock and ordered events sequence number to restor= e the > +original order. > + > +Some applications, like those based on the DPDK dispatcher library, want > +enqueue order independence. To support this, DLB2 PMD supports the Remove DLB2 from generic documentation. > +``RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ`` capability. > + > +This capability applies to Eventdevs supporting burst mode. On ports whe= re > +the application is going to change enqueue order, > +``RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ`` support should be enabled. > + > +Example code to inform PMD that the application plans to use independent= enqueue > +order on a port: > + > + .. code-block:: c > + > + if (capability & RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ) > + port_config =3D port_config | RTE_EVENT_PORT_CFG_INDEPENDENT_EN= Q; > + -------------------- AS MENTIONED IN THE LAST comment, Please move this section to 1/3 patch. > +This code example enables enqueue event reordering inside DLB2 PMD befor= e the events > +are sent to the DLB2 hardware. If the application is not going to change= the enqueue > +order, this flag should not be enabled to get better performance. DLB2 P= MD saves > +ordering information inside the impl_opaque field of the event, and this= field should > +be preserved for all FORWARD or RELEASE events. This section is a candidate for DLB2 specific documentation. DONT ADD IN doc/guides/prog_guide/eventdev/eventdev.rst instead move any DLB2 specific documentation DLB2 specific document if needed. > + > Stopping the EventDev > ~~~~~~~~~~~~~~~~~~~~~ > > diff --git a/doc/guides/rel_notes/release_24_11.rst b/doc/guides/rel_note= s/release_24_11.rst > index dee6723b70..98e9732100 100644 > --- a/doc/guides/rel_notes/release_24_11.rst > +++ b/doc/guides/rel_notes/release_24_11.rst > @@ -72,6 +72,11 @@ New Features > * Added support for independent enqueue feature. Updated Event Device = and > PMD feature list. > > + * Updated DLB2 driver for independent enqueue feature. Applications sh= ould > + use ``RTE_EVENT_PORT_CFG_INDEPENDENT_ENQ`` to enable the feature if = the > + capability ``RTE_EVENT_DEV_CAP_INDEPENDENT_ENQ`` exists. Starting from =E2=80=9CApplications ...=E2=80=9D is not specific to DLB2, r= emove from release notes. Please send the next version on Monday, planning to submit rc1 PR on Tuesda= y.