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 049D6A0579; Thu, 8 Apr 2021 18:45:41 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E62F0141164; Thu, 8 Apr 2021 18:45:40 +0200 (CEST) Received: from spider.fraudbuster.mobi (spider.fraudbuster.mobi [62.4.12.223]) by mails.dpdk.org (Postfix) with ESMTP id D334F4068B for ; Thu, 8 Apr 2021 18:45:38 +0200 (CEST) Received: from [10.8.0.214] (gypsy.fraudbuster.mobi [212.129.1.221]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by spider.fraudbuster.mobi (Postfix) with ESMTPSA id 6454B21C23; Thu, 8 Apr 2021 18:45:38 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=fraudbuster.mobi; s=rsa-20200712; t=1617900338; bh=2wQZv+3dB0UHjZ/dBY26Gp07CYh3aWZ1xOxmsrGDnGM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=neQtgheEFQW8ExQO4ajIe8/S43rvXTd2NpVLkESZHvzvfbxsXn7EJ15bWcvZ2K4Zy Oa5hbPy2xGzjx0cB0Xtq+d9JWMv52gzl3OukEHMor6W6lgeeOgyLuL5D4pgD9Q9uFC VAB0SUasBG1AHpH9JxCoXL2utmJKnRv+QDWDS0TRR/fBt5Rq8B+8FG1iaBdnrZSfO8 bMNa3TB/UVcmj9HWFxOeUBKmt7caKsIFHmHCOU5xj7ov4dTq3x6OmpQmRh34Hfue2W VoYy3Uwi31qDeH20yeKFA5l4aUdWtWBDtyQOiER6OZwvGm0gIAbDNtzlAz5/Ut0ESl FRt1Zas36oVMA== To: Matan Azrad , Asaf Penso , "dev@dpdk.org" Cc: Jack Min References: <26698242-bb7b-baa0-9e61-235ac3725cd7@fraudbuster.mobi> <1ad78db6-38bd-2e01-0d81-60dd3b256c2a@fraudbuster.mobi> <72f4c179-35d3-9139-ccf0-57cceb6a19c2@fraudbuster.mobi> From: David Bouyeure Message-ID: <052ea86a-44f4-f5d4-ba0a-47c024865303@fraudbuster.mobi> Date: Thu, 8 Apr 2021 18:45:37 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.1 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-Spamd-Result: default: False [0.00 / 15.00]; ASN(0.00)[asn:12876, ipnet:212.129.0.0/18, country:FR]; IP_WHITELIST(0.00)[212.129.1.221] X-Rspamd-Queue-Id: 6454B21C23 X-Rspamd-Server: spider Content-Type: text/plain; charset=windows-1255; format=flowed Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [dpdk-dev] rte_flow ageing 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" As seen with Matan, there's really a bug preventing to schedule a later age event(with /rte_flow_get_aged_flows()/) from the user's callback itself. I could suggest the following patch: --- dpdk-21.02/drivers/net/mlx5/mlx5.c    2021-02-14 10:58:34.000000000 +0100 +++ dpdk-21.02/drivers/net/mlx5/mlx5.c.new    2021-04-08 18:35:44.124965176 +0200 @@ -554,7 +554,7 @@              rte_eth_dev_callback_process (&rte_eth_devices[sh->port[i].devx_ih_port_id],                  RTE_ETH_EVENT_FLOW_AGED, NULL); -        age_info->flags = 0; +        age_info->flags &= ~MLX5_AGE_EVENT_NEW;      }  } Thanks. On 4/8/21 11:52 AM, Matan Azrad wrote: > > Yes, you right for the meaning of MLX5_AGE_TRIGGER. > > But why you said it is erased when the callback return? > > It is erased when a new aged-out flow is detected by the driver…. > > Do you have an issue with option 1? > > Matan > > *From:*David Bouyeure > *Sent:* Thursday, April 8, 2021 10:50 AM > *To:* Matan Azrad ; Asaf Penso ; > dev@dpdk.org > *Cc:* Jack Min > *Subject:* Re: [dpdk-dev] rte_flow ageing > > *External email: Use caution opening links or attachments* > > Hi Matan, > > below are my comments. > > Thank you. > > On 4/7/21 8:09 PM, Matan Azrad wrote: > > Yes you can call it from the event callback. > > Sure, but it won't trigger the event callback as it would for the next > aged-out flow(s) if called from outside the callback. > > Yes, MLX5_AGE_TRIGGER probably means that event was sent and no > need to send it again in the next aged-out flow. > > I don't think so. MLX5_AGE_TRIGGER means 'Do call the callback for > next aged-out flow(s)'. > > Erasing it cause new event to be sent in the next aged-out flow... > > No, I think it's the reverse. > > I don't understand what is the issue for you in option 1... > > äùâ àú þOutlookòáåø Androidþ > > > ------------------------------------------------------------------------ > > *From:*David Bouyeure > > *Sent:* Wednesday, April 7, 2021 7:19:34 PM > *To:* Matan Azrad ; > Asaf Penso ; > dev@dpdk.org > > *Cc:* Jack Min > *Subject:* Re: [dpdk-dev] rte_flow ageing > > *External email: Use caution opening links or attachments* > > Hi Matan, and thanks a lot, > > regarding the mode *1*, I still have a doubt: > > 1. Register the AGE event -> in event time to query the > aged-out flows by the rte_flow_get_aged_flows API, this > call will trigger a new event when new aged-out flow will > be detected for the port.(if you don’t call > rte_flow_get_aged_flows the event will not be retriggered.) > > You meant calling rte_flow_get_aged_flows() from the event > callback I guess...? > > I think this is not working because MLX5_AGE_TRIGGER is erased > when the callback returns. > > Anyway, the polling mode is enough to me so far. > > Thanks again. > > Regards. > > On 4/5/21 12:23 PM, Matan Azrad wrote: > > --> >