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 11E93A0A02; Thu, 14 Jan 2021 09:38:14 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6F01A140FEC; Thu, 14 Jan 2021 09:38:13 +0100 (CET) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mails.dpdk.org (Postfix) with ESMTP id 3E2ED140FDF for ; Thu, 14 Jan 2021 09:38:12 +0100 (CET) IronPort-SDR: HE8tqesS7QNGXUX3q+P6osQlOhJ47jyrbZmDdcKCa72mTE+t7pAbW9RU22AHwMQ/+tGn8UNXhG NUgpifdaFZtA== X-IronPort-AV: E=McAfee;i="6000,8403,9863"; a="175749882" X-IronPort-AV: E=Sophos;i="5.79,346,1602572400"; d="scan'208";a="175749882" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Jan 2021 00:38:11 -0800 IronPort-SDR: e3MmmzSAAr7qWicNBQuPVOFKY6N3tLrLHnqb5f/6covPSdEJsuStEcSOeqkR3eGr+/hcv5pyw0 onrp46DsGxmA== X-IronPort-AV: E=Sophos;i="5.79,346,1602572400"; d="scan'208";a="382191431" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.213.220.143]) ([10.213.220.143]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Jan 2021 00:38:09 -0800 To: Gregory Etelson , Ori Kam References: Cc: bugzilla@dpdk.org, dev@dpdk.org, Ajit Khaparde From: Ferruh Yigit Message-ID: <09d81edf-ad10-4dbe-a1a5-63a5a7ef6987@intel.com> Date: Thu, 14 Jan 2021 08:38:05 +0000 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Subject: Re: [dpdk-dev] [Bug 613] [21.02] rule lost after port stopped 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" On 1/14/2021 7:15 AM, bugzilla@dpdk.org wrote: > https://bugs.dpdk.org/show_bug.cgi?id=613 > > Bug ID: 613 > Summary: [21.02] rule lost after port stopped > Product: DPDK > Version: unspecified > Hardware: x86 > OS: Linux > Status: UNCONFIRMED > Severity: normal > Priority: Normal > Component: testpmd > Assignee: dev@dpdk.org > Reporter: qinx.sun@intel.com > Target Milestone: --- > > create a rule in testpmd, stop port and then flow list port find that rule > lost. > > Environment > > DPDK version: Use make showversion or for a non-released version: git remote -v > && git show-ref --heads > 21.02.0-rc0:0144eeafd1467937a379a7dc005bcb0579b0ae5e > Other software versions: name/version for QEMU, OVS, etc. Repeat as required. > OS: CentOS8.3 > Compiler: gcc version 8.3.1 20191121 (Red Hat 8.3.1-5) > Hardware platform: Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz > NIC hardware: Ethernet Controller E810-C for SFP 1593 > NIC firmware: 2.30 0x80004dcf 1.2839.0 > NIC driver: 1.3.0_dirty > Pkg: ice-comms_1.3.24.0 > > [reproduce steps] > 1. bind to vfio-pci and create 2 vfs > usertools/dpdk-devbind.py --force --bind=vfio-pci 0000:03:00.0 > echo 2 > /sys/bus/pci/devices/0000:03:00.0/sriov_numvfs > > 2. start testpmd > x86_64-native-linuxapp-gcc/app/dpdk-testpmd -l 1,2,3,4 -n 4 -a > 0000:03:01.0,cap=dcf -a 0000:03:01.1 --file-prefix=dpdk_1965_20210114114229 > -- -i > > 3. create a rule > testpmd> flow create 0 ingress pattern eth dst is 68:05:ca:8d:ed:a8 / ipv4 src > is 192.168.0.1 dst is 192.168.0.2 tos is 4 ttl is 3 / udp src is 25 dst is 23 / > end actions vf id 1 / end > Flow rule #1 created > > 4. list rule > testpmd> flow list 0 > ID Group Prio Attr Rule > 0 0 0 i-- ETH IPV4 UDP => VF > > 5.stop port 0 > testpmd> port stop 0 > Stopping ports... > Checking link statuses... > Done > > 6.list rule > testpmd> flow list 0 > testpmd> > > Actual Result: rule lost after port stopped > > Expected Result: The result of rule list is the same as step 4. > > Regression > Is this issue a regression: (Y) > > Version the regression was introduced: Specify git id if known. > > commit 0f93edbf7c874480e21e365f527fecdb305984b9 > Author: Gregory Etelson > Date: Thu Nov 26 18:43:02 2020 +0200 > > app/testpmd: release flows left before port stop > > According to RTE flow user guide, PMD will not keep flow rules after > port stop. Application resources that refer to flow rules become > obsolete after port stop and must not be used. > Testpmd maintains linked list of active flows for each port. Entries in > that list are allocated dynamically and must be explicitly released to > prevent memory leak. > The patch releases testpmd port flow_list that holds remaining flows > before port is stopped. > > Cc: stable@dpdk.org > > Signed-off-by: Gregory Etelson > Acked-by: Ori Kam > Acked-by: Ajit Khaparde > cc'ed Gregory & Ori.