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 8C412A0548; Tue, 20 Apr 2021 19:13:13 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 15E3641735; Tue, 20 Apr 2021 19:13:13 +0200 (CEST) Received: from mail-qk1-f178.google.com (mail-qk1-f178.google.com [209.85.222.178]) by mails.dpdk.org (Postfix) with ESMTP id D0E0F41439 for ; Tue, 20 Apr 2021 19:13:11 +0200 (CEST) Received: by mail-qk1-f178.google.com with SMTP id d19so4382221qkk.12 for ; Tue, 20 Apr 2021 10:13:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=/zzhXjhFphVH3Cq+LaTE42Xm+9VCBXlqCgFDKcAhkLQ=; b=JRKUo23S4906zrf7cAYgP3y8QbudXv2Te2hK+MnkN96Aj0vZECnKXXoecW1DPb+Ysg RFuk1gjSOYrm0wkwBO+ee0+rSbasPjT1iEbtg+w8pXm69pAthW+y1nP+ZumwYRLQ+in5 1Fxa0Ovxm47miiVDhndGFpEX9DHiijCMQzp2I= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=/zzhXjhFphVH3Cq+LaTE42Xm+9VCBXlqCgFDKcAhkLQ=; b=FnUBlW69ERgpmI7ECa59wFO4SyUlFOWdluA3y2W7vjL7Dgm7anjx18+qWKyOtJiFgB 3qOeuzTOGr9ngg1794Xbm1Be8lHJUfzDoew/6yBbqM3cAYt9cWtSpYblzKOypRYghgJy M4ctgN06cvoKuYiwsDTJEZPD+ItSAy+ETQrsWj3yBU1/kr+YrZtClJebxIXA0lTH4Jtw lXmlbuTJoGFuAp/O/Et1kC2ojJezhmD8n2LsVmR+32yGtMGjWVcGr3SiwCASVnn04ZqG Pf/ieQBY4L1q4ViLettxm8Vy8UxCch6JoqGEHAg8s4wBIHg8n6iJ6vHWDoErEXHuIbMZ Rlyg== X-Gm-Message-State: AOAM531hefSQcQ1YBBuFgerCap9YYauxlEfs/G7OcJqSSRGIz6HcHtHG 05LOiLkgyHt6i7BKeM0HYoTw3IDjNPdZ8D2M0vowRw== X-Google-Smtp-Source: ABdhPJxWBokk4M1JKvdH+b9occ24Mwc9/oU3wLnm9dLzsnOkTIWJ6Ixk1Um5HuhK5MaFvSB625Z/pZy8Jv9FovGSk94= X-Received: by 2002:a37:7985:: with SMTP id u127mr18844904qkc.333.1618938790635; Tue, 20 Apr 2021 10:13:10 -0700 (PDT) MIME-Version: 1.0 References: <1618848506-37569-1-git-send-email-jiaweiw@nvidia.com> <1618927490-229267-1-git-send-email-jiaweiw@nvidia.com> <1618927490-229267-2-git-send-email-jiaweiw@nvidia.com> In-Reply-To: <1618927490-229267-2-git-send-email-jiaweiw@nvidia.com> From: Ajit Khaparde Date: Tue, 20 Apr 2021 10:12:54 -0700 Message-ID: To: Jiawei Wang Cc: Matan Azrad , Ori Kam , Slava Ovsiienko , Shahaf Shuler , Ferruh Yigit , Wisam Jaddo , Xiaoyun Li , Jasvinder Singh , Cristian Dumitrescu , Thomas Monjalon , Andrew Rybchenko , Ray Kinsella , Neil Horman , dpdk-dev , Raslan Darawsheh , Roni Bar Yanai , Asaf Penso , Li Zhang , Haifei Luo Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="00000000000091e67405c06a8f6a" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [dpdk-dev] [PATCH v10 1/2] ethdev: add pre-defined meter policy API 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 Sender: "dev" --00000000000091e67405c06a8f6a Content-Type: text/plain; charset="UTF-8" On Tue, Apr 20, 2021 at 7:05 AM Jiawei Wang wrote: > > From: Li Zhang > > Currently, the flow meter policy does not support multiple actions > per color; also the allowed action types per color are very limited. > In addition, the policy cannot be pre-defined. > > Due to the growing in flow actions offload abilities there is a potential > for the user to use variety of actions per color differently. > This new meter policy API comes to allow this potential in the most ethdev > common way using rte_flow action definition. > A list of rte_flow actions will be provided by the user per color > in order to create a meter policy. > In addition, the API forces to pre-define the policy before > the meters creation in order to allow sharing of single policy > with multiple meters efficiently. > > meter_policy_id is added into struct rte_mtr_params. > So that it can get the policy during the meters creation. > > Allow coloring the packet using a new rte_flow_action_color > as could be done by the old policy API. > > Add two common policy template as macros in the head file. > > The next API function were added: > - rte_mtr_meter_policy_add > - rte_mtr_meter_policy_delete > - rte_mtr_meter_policy_update > - rte_mtr_meter_policy_validate > The next struct was changed: > - rte_mtr_params > - rte_mtr_capabilities > The next API was deleted: > - rte_mtr_policer_actions_update > > To support this API the following app were changed: > app/test-flow-perf: clean meter policer > app/testpmd: clean meter policer > > To support this API the following drivers were changed: > net/softnic: support meter policy API > 1. Cleans meter rte_mtr_policer_action. > 2. Supports policy API to get color action as policer action did. > The color action will be mapped into rte_table_action_policer. > > net/mlx5: clean meter creation management > Cleans and breaks part of the current meter management > in order to allow better design with policy API. > > Signed-off-by: Li Zhang > Signed-off-by: Haifei Luo > Signed-off-by: Jiawei Wang > Acked-by: Matan Azrad > Acked-by: Ray Kinsella > Acked-by: Ori Kam > Acked-by: Jasvinder Singh > Acked-by: Cristian Dumitrescu Acked-by: Ajit Khaparde > -- > 1.8.3.1 > --00000000000091e67405c06a8f6a--