From patchwork Wed Mar 11 09:05:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rahul Lakkireddy X-Patchwork-Id: 66529 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 136F1A0567; Wed, 11 Mar 2020 10:16:38 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 675C71BFF7; Wed, 11 Mar 2020 10:16:37 +0100 (CET) Received: from stargate.chelsio.com (stargate.chelsio.com [12.32.117.8]) by dpdk.org (Postfix) with ESMTP id E471F1BF94 for ; Wed, 11 Mar 2020 10:16:35 +0100 (CET) Received: from localhost (scalar.blr.asicdesigners.com [10.193.185.94]) by stargate.chelsio.com (8.13.8/8.13.8) with ESMTP id 02B9GXfn014321; Wed, 11 Mar 2020 02:16:34 -0700 From: Rahul Lakkireddy To: dev@dpdk.org Cc: nirranjan@chelsio.com, kaara.satwik@chelsio.com Date: Wed, 11 Mar 2020 14:35:42 +0530 Message-Id: X-Mailer: git-send-email 2.5.3 Subject: [dpdk-dev] [PATCH 0/9] net/cxgbe: updates for rte_flow support 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" From: Karra Satwik This series of patches contain rte_flow support for matching Q-in-Q VLAN, IP TOS, PF, and VF fields. Also, adds Destination MAC rewrite and Source MAC rewrite actions. Apart from the 4-tuple (IP src/dst addresses and TCP/UDP src/dst port addresses), there are only 40-bits available to match other fields in packet headers. Currently, the combination of packet header fields to match are configured via filterMode for LETCAM filters and filterMask for HASH filters in firmware config files (t5/t6-config.txt). Adapter needs to be reflashed with new firmware config file everytime the combinations need to be changed. To avoid this, a new firmware API is available to dynamically change the combination before completing full adapter initialization. So, 2 new devargs filtermode and filtermask are added to dynamically select the combinations during runtime. Patch 1 adds rte_flow support for matching Q-in-Q VLAN. Patch 2 adds rte_flow support for matching IP TOS. Patch 3 adds rte_flow support for matching all packets on PF. Patch 4 adds rte_flow support for matching all packets on VF. Patch 5 adds rte_flow support for overwriting destination MAC. Patch 6 adds Source MAC Table (SMT) support. Patch 7 adds rte_flow support for Source MAC Rewrite. Patch 8 adds new firmware API for validating filter spec. Patch 9 adds devargs to control filtermode and filtermask combinations. Thanks, Satwik Karra Satwik (9): net/cxgbe: add rte_flow support for matching Q-in-Q VLAN net/cxgbe: add rte_flow support for matching IP TOS net/cxgbe: add rte_flow support for matching all packets on PF net/cxgbe: add rte_flow support for matching all packets on VF net/cxgbe: add rte_flow support for overwriting destination MAC net/cxgbe: add Source MAC Table (SMT) support net/cxgbe: add rte_flow support for Source MAC Rewrite net/cxgbe: use firmware API for validating filter spec net/cxgbe: add devargs to control filtermode and filtermask values doc/guides/nics/cxgbe.rst | 219 +++++++++++++++++- drivers/net/cxgbe/Makefile | 1 + drivers/net/cxgbe/base/adapter.h | 9 + drivers/net/cxgbe/base/common.h | 8 +- drivers/net/cxgbe/base/t4_hw.c | 81 +++++-- drivers/net/cxgbe/base/t4_msg.h | 40 ++++ drivers/net/cxgbe/base/t4_regs.h | 4 + drivers/net/cxgbe/base/t4_tcb.h | 10 + drivers/net/cxgbe/base/t4fw_interface.h | 55 ++++- drivers/net/cxgbe/cxgbe.h | 23 ++ drivers/net/cxgbe/cxgbe_ethdev.c | 4 +- drivers/net/cxgbe/cxgbe_filter.c | 103 ++++++++- drivers/net/cxgbe/cxgbe_filter.h | 8 +- drivers/net/cxgbe/cxgbe_flow.c | 241 +++++++++++++++----- drivers/net/cxgbe/cxgbe_main.c | 291 +++++++++++++++++++++++- drivers/net/cxgbe/meson.build | 1 + drivers/net/cxgbe/smt.c | 230 +++++++++++++++++++ drivers/net/cxgbe/smt.h | 44 ++++ 18 files changed, 1275 insertions(+), 97 deletions(-) create mode 100644 drivers/net/cxgbe/smt.c create mode 100644 drivers/net/cxgbe/smt.h