From patchwork Mon Feb 3 13:32:09 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bing Zhao X-Patchwork-Id: 65485 Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 98B54A052E; Mon, 3 Feb 2020 14:32:33 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 721EC1BFB6; Mon, 3 Feb 2020 14:32:33 +0100 (CET) Received: from git-send-mailer.rdmz.labs.mlnx (unknown [37.142.13.130]) by dpdk.org (Postfix) with ESMTP id 1E8651BFB1 for ; Mon, 3 Feb 2020 14:32:32 +0100 (CET) From: Bing Zhao To: orika@mellanox.com, viacheslavo@mellanox.com, rasland@mellanox.com, matan@mellanox.com Cc: dev@dpdk.org Date: Mon, 3 Feb 2020 15:32:09 +0200 Message-Id: <1580736735-19472-1-git-send-email-bingz@mellanox.com> X-Mailer: git-send-email 1.8.3.1 Subject: [dpdk-dev] [PATCH 0/6] net/mlx5: move to non-cached mode for flow rules X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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" This patch set will remove the flow rules cache and move to the non-cached mode for DV mode. For Verbs mode flow rules, the behavior will remain the same. In the device closing stage, all the software resources for flows created will be freed and corresponding hardware resources will be released. Then the total cost of the memory will be reduced and the behavior of mlx5 PMD will comply fully with the ethdev API expectations. After closing a device, all the flow rules stored in application layer will no longer be valid anymore. Application should synchronize the database and do not try to destory any rule on this device. And after a device restarting, all the needed flow rules should be reinserted via the create routine in the rte_flow lib. Bing Zhao (6): net/mlx5: introduce non-cached flows tailq list net/mlx5: change operations of non-cached flows net/mlx5: flow type check before creating net/mlx5: introduce handle structure for DV flows net/mlx5: remove the DV support macro checking net/mlx5: do not save device flow matcher value drivers/net/mlx5/mlx5.c | 4 +- drivers/net/mlx5/mlx5.h | 5 +- drivers/net/mlx5/mlx5_flow.c | 246 ++++++++++++++++++++++-------- drivers/net/mlx5/mlx5_flow.h | 44 +++++- drivers/net/mlx5/mlx5_flow_dv.c | 328 ++++++++++++++++++++++------------------ drivers/net/mlx5/mlx5_trigger.c | 11 +- 6 files changed, 417 insertions(+), 221 deletions(-)