get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/patches/107860/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 107860,
    "url": "http://patches.dpdk.org/api/patches/107860/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20220220034409.2226860-3-akozyrev@nvidia.com/",
    "project": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/projects/1/?format=api",
        "name": "DPDK",
        "link_name": "dpdk",
        "list_id": "dev.dpdk.org",
        "list_email": "dev@dpdk.org",
        "web_url": "http://core.dpdk.org",
        "scm_url": "git://dpdk.org/dpdk",
        "webscm_url": "http://git.dpdk.org/dpdk",
        "list_archive_url": "https://inbox.dpdk.org/dev",
        "list_archive_url_format": "https://inbox.dpdk.org/dev/{}",
        "commit_url_format": ""
    },
    "msgid": "<20220220034409.2226860-3-akozyrev@nvidia.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20220220034409.2226860-3-akozyrev@nvidia.com",
    "date": "2022-02-20T03:44:00",
    "name": "[v8,02/11] ethdev: add flow item/action templates",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "760ee3d82a88ee29a86b71eaea0e677bf60ffef9",
    "submitter": {
        "id": 1873,
        "url": "http://patches.dpdk.org/api/people/1873/?format=api",
        "name": "Alexander Kozyrev",
        "email": "akozyrev@nvidia.com"
    },
    "delegate": {
        "id": 319,
        "url": "http://patches.dpdk.org/api/users/319/?format=api",
        "username": "fyigit",
        "first_name": "Ferruh",
        "last_name": "Yigit",
        "email": "ferruh.yigit@amd.com"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20220220034409.2226860-3-akozyrev@nvidia.com/mbox/",
    "series": [
        {
            "id": 21750,
            "url": "http://patches.dpdk.org/api/series/21750/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=21750",
            "date": "2022-02-20T03:43:58",
            "name": "ethdev: datapath-focused flow rules management",
            "version": 8,
            "mbox": "http://patches.dpdk.org/series/21750/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/107860/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/107860/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@inbox.dpdk.org",
        "Delivered-To": "patchwork@inbox.dpdk.org",
        "Received": [
            "from mails.dpdk.org (mails.dpdk.org [217.70.189.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id B9723A00C2;\n\tSun, 20 Feb 2022 04:44:58 +0100 (CET)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 783384115A;\n\tSun, 20 Feb 2022 04:44:51 +0100 (CET)",
            "from NAM12-DM6-obe.outbound.protection.outlook.com\n (mail-dm6nam12on2087.outbound.protection.outlook.com [40.107.243.87])\n by mails.dpdk.org (Postfix) with ESMTP id 9667640395\n for <dev@dpdk.org>; Sun, 20 Feb 2022 04:44:47 +0100 (CET)",
            "from MN2PR12MB4607.namprd12.prod.outlook.com (2603:10b6:208:a1::18)\n by MN2PR12MB4304.namprd12.prod.outlook.com (2603:10b6:208:1d0::12)\n with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Sun, 20 Feb\n 2022 03:44:43 +0000",
            "from DM6PR13CA0059.namprd13.prod.outlook.com (2603:10b6:5:134::36)\n by MN2PR12MB4607.namprd12.prod.outlook.com (2603:10b6:208:a1::18) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4995.16; Sun, 20 Feb\n 2022 03:44:37 +0000",
            "from DM6NAM11FT014.eop-nam11.prod.protection.outlook.com\n (2603:10b6:5:134:cafe::44) by DM6PR13CA0059.outlook.office365.com\n (2603:10b6:5:134::36) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5017.19 via Frontend\n Transport; Sun, 20 Feb 2022 03:44:37 +0000",
            "from mail.nvidia.com (12.22.5.236) by\n DM6NAM11FT014.mail.protection.outlook.com (10.13.173.132) with Microsoft SMTP\n Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id\n 15.20.4995.15 via Frontend Transport; Sun, 20 Feb 2022 03:44:37 +0000",
            "from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL109.nvidia.com\n (10.27.9.19) with Microsoft SMTP Server (TLS) id 15.0.1497.18;\n Sun, 20 Feb 2022 03:44:36 +0000",
            "from pegasus01.mtr.labs.mlnx (10.126.230.35) by\n rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server\n (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.9;\n Sat, 19 Feb 2022 19:44:33 -0800"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;\n b=KL1eUrWdaQtiggY1y9H6ppA58SATt65mX9okMfUA56lgD8poDHTWPSHnmzYO4G2vxidYntLXkOhvPxYXAaI04bualypz6REj+WiUzT318qveXKzmvI5DvVJoiWlz9wZj6rzf1gxhgL3wC12YRUWttXnOLtQFUVq2xwlqHY4hs2B9O0JuTZ71p87v9OpuG4MMFG8SM/bdFIImD1htrXxnhC9t0KNVma1JTj1Pu6qfUYkD4iWjZDX94JIsx3GMEzHiRirakW9gIgZ/e/SKHZnP5+NbChXW+TkY3bteQhZKKo3jJYAT9DxNv/MoakJLpiSQPT4epeROcuRa232e/BdPHQ==",
        "ARC-Message-Signature": "i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector9901;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=SQJ0GTC0hhunoR9sIH4YtqHXPqPKcRpFNtgUuX6zDX4=;\n b=Pr0e/lGiWj0jgFBs3Ds7/CbmaZj1wf3gtFC+ZSfaieQHvyNkFyfNUPVxWRxjDHUY0YSZFqTBp3evBqLvI6kX2Bg9c0JcHlBszTMb/iq3j3ab9C9aiezIpdEeiMeT/IbbdfSzVAeOw1gXkGBTEIz50TiTpP8lqJqs7+gvzvSxx/xeNDOBa+d/FSaoUihPPbjV/atm1Sxcfy7pnbg8EaLSjrnm0DgHynC6ennOvmOn9a0kYQj1YyUGyO8vse70zWYJSb5vKqZHw53eavtBxXT+Oit3J9UFFskLT+rSX1n/WSrmzcI12k/4NXsvkuCUJWFf+2eG2EQphqAXJmdomR1l0g==",
        "ARC-Authentication-Results": "i=1; mx.microsoft.com 1; spf=pass (sender ip is\n 12.22.5.236) smtp.rcpttodomain=intel.com smtp.mailfrom=nvidia.com; dmarc=pass\n (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none\n (message not signed); arc=none",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com;\n s=selector2;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=SQJ0GTC0hhunoR9sIH4YtqHXPqPKcRpFNtgUuX6zDX4=;\n b=K5xHO8ZdZJqExL5C09s5FtnJ0qdGmQeCfZqeksN76ZhuCV4+oPu2jM4x2QRDqDwEQf8EvYtYByNrPbSGti7cyMr1jp1HKp5G7u96DPxa8qBjM93wsO1yVCaMbKHLLuzlFdwCHJ+AoqF+oo+feL1YIkAEcZd/mZdXKSbqKFCaEn8BFkvOJDNIFasyvLfE5+Eqn5hlMTMJ8WeASul8+MP3o6rCcjiEagIacZeIq3ClFnJp3zPW7keoSULXyVyLJgwJyL7hWMx4txIc5jlLVD+DzaKbdpRJ3J+qnONvrUDisnBdyHNCUkNMbHkcu55W1rewFOStIVrphvO22h5dB0J2BQ==",
        "X-MS-Exchange-Authentication-Results": "spf=pass (sender IP is 12.22.5.236)\n smtp.mailfrom=nvidia.com; dkim=none (message not signed)\n header.d=none;dmarc=pass action=none header.from=nvidia.com;",
        "Received-SPF": "Pass (protection.outlook.com: domain of nvidia.com designates\n 12.22.5.236 as permitted sender) receiver=protection.outlook.com;\n client-ip=12.22.5.236; helo=mail.nvidia.com;",
        "From": "Alexander Kozyrev <akozyrev@nvidia.com>",
        "To": "<dev@dpdk.org>",
        "CC": "<orika@nvidia.com>, <thomas@monjalon.net>, <ivan.malov@oktetlabs.ru>,\n <andrew.rybchenko@oktetlabs.ru>, <ferruh.yigit@intel.com>,\n <mohammad.abdul.awal@intel.com>, <qi.z.zhang@intel.com>,\n <jerinj@marvell.com>, <ajit.khaparde@broadcom.com>,\n <bruce.richardson@intel.com>",
        "Subject": "[PATCH v8 02/11] ethdev: add flow item/action templates",
        "Date": "Sun, 20 Feb 2022 05:44:00 +0200",
        "Message-ID": "<20220220034409.2226860-3-akozyrev@nvidia.com>",
        "X-Mailer": "git-send-email 2.18.2",
        "In-Reply-To": "<20220220034409.2226860-1-akozyrev@nvidia.com>",
        "References": "<20220219041144.2145380-1-akozyrev@nvidia.com>\n <20220220034409.2226860-1-akozyrev@nvidia.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain",
        "X-Originating-IP": "[10.126.230.35]",
        "X-ClientProxiedBy": "rnnvmail202.nvidia.com (10.129.68.7) To\n rnnvmail201.nvidia.com (10.129.68.8)",
        "X-EOPAttributedMessage": "0",
        "X-MS-PublicTrafficType": "Email",
        "X-MS-Office365-Filtering-Correlation-Id": "606cba3d-5487-4ef4-0a0c-08d9f423513a",
        "X-MS-TrafficTypeDiagnostic": "MN2PR12MB4607:EE_|MN2PR12MB4304:EE_",
        "X-LD-Processed": "43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr,ExtAddr",
        "X-Microsoft-Antispam-PRVS": "\n <MN2PR12MB46072BC2733DC58A81BCD1D5AF399@MN2PR12MB4607.namprd12.prod.outlook.com>",
        "X-MS-Exchange-SenderADCheck": "1",
        "X-MS-Exchange-AntiSpam-Relay": "0",
        "X-Microsoft-Antispam": "BCL:0;",
        "X-Microsoft-Antispam-Message-Info": "\n f46mDhJoxZ+NFWNAwQMCPQovLSRGnto8lJEip315cS2sS/fgK4jaQemiXPN7uP+b9NYzsLsvfinHA4wjQ2lroE+xTdNTiz6ZjumDIgSWioWLdZ+/PcisOuCuan7jW4uA+dDTJpyUb+l9Lylo9c3rCDOXVQv2CCFhQ3FJP5bkVzpISVXZNcdHnhZLyx6wcmqjbwLvbZzb95x64kjSuRZClHnG22ixKSnjX4Q8VFB5GNQ6SUpHAt0w+miFN35skd0vAPiQo6ED24VBs4MIi/d6W6RXzauiC8/3A+xt9IoZAcqtkmT3JSiCKhe9H65rcvwp8EZj+VY9NKjlrSeByMWhI9ZYtkFOvcnRs39OXD1qbl/J9rwZmuqBu0TEIVwM2JWn1+ST2sKp2vjBC4IJotkBzdw7I08XvcSDFMyb6spsIK9sMwTma+vLbQSDauShjavaGh8WdjaAr+kdE3zlqbvG7//1rt+LiBzuUu5T87V+4Lvgxu686HgIArch/rBLPua0MUQrjdzVZEknqsr0A/PD1hEM5CXRKZ6K5AV98NuYadTLavmE1DwfMUVFi1idf6nPz3FrTBlYQRHtzoZwK7MHz+NPgqieM/OmsL3/ynj2s0S7PlA2t+VsovhrupECH3YisL+c+MXflW2LZ4VyBSgF0cwuhJSNCuCjK8y4ZhBI/D3ZQHH0hkuDndTF+nHMSQ5M8xq9m2WO9lttPtRXFFaPQA==",
        "X-Forefront-Antispam-Report": "CIP:12.22.5.236; CTRY:US; LANG:en; SCL:1; SRV:;\n IPV:CAL; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE;\n SFS:(13230001)(4636009)(40470700004)(46966006)(36840700001)(1076003)(336012)(426003)(36756003)(6916009)(316002)(16526019)(2616005)(40460700003)(508600001)(186003)(47076005)(26005)(36860700001)(8676002)(4326008)(70586007)(70206006)(8936002)(82310400004)(6666004)(30864003)(5660300002)(7416002)(54906003)(86362001)(356005)(81166007)(2906002)(83380400001)(36900700001);\n DIR:OUT; SFP:1101;",
        "X-OriginatorOrg": "Nvidia.com",
        "X-MS-Exchange-CrossTenant-OriginalArrivalTime": "20 Feb 2022 03:44:37.2176 (UTC)",
        "X-MS-Exchange-CrossTenant-Network-Message-Id": "\n 606cba3d-5487-4ef4-0a0c-08d9f423513a",
        "X-MS-Exchange-CrossTenant-Id": "43083d15-7273-40c1-b7db-39efd9ccc17a",
        "X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp": "\n TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.236];\n Helo=[mail.nvidia.com]",
        "X-MS-Exchange-CrossTenant-FromEntityHeader": "HybridOnPrem",
        "X-MS-Exchange-CrossTenant-AuthSource": "\n DM6NAM11FT014.eop-nam11.prod.protection.outlook.com",
        "X-MS-Exchange-CrossTenant-AuthAs": "Anonymous",
        "X-MS-Exchange-Transport-CrossTenantHeadersStamped": "MN2PR12MB4304",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.29",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<https://mails.dpdk.org/options/dev>,\n <mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://mails.dpdk.org/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<https://mails.dpdk.org/listinfo/dev>,\n <mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org"
    },
    "content": "Treating every single flow rule as a completely independent and separate\nentity negatively impacts the flow rules insertion rate. Oftentimes in an\napplication, many flow rules share a common structure (the same item mask\nand/or action list) so they can be grouped and classified together.\nThis knowledge may be used as a source of optimization by a PMD/HW.\n\nThe pattern template defines common matching fields (the item mask) without\nvalues. The actions template holds a list of action types that will be used\ntogether in the same rule. The specific values for items and actions will\nbe given only during the rule creation.\n\nA table combines pattern and actions templates along with shared flow rule\nattributes (group ID, priority and traffic direction). This way a PMD/HW\ncan prepare all the resources needed for efficient flow rules creation in\nthe datapath. To avoid any hiccups due to memory reallocation, the maximum\nnumber of flow rules is defined at the table creation time.\n\nThe flow rule creation is done by selecting a table, a pattern template\nand an actions template (which are bound to the table), and setting unique\nvalues for the items and actions.\n\nSigned-off-by: Alexander Kozyrev <akozyrev@nvidia.com>\nAcked-by: Ori Kam <orika@nvidia.com>\n---\n doc/guides/prog_guide/rte_flow.rst     | 135 ++++++++++++\n doc/guides/rel_notes/release_22_03.rst |   8 +\n lib/ethdev/rte_flow.c                  | 252 +++++++++++++++++++++++\n lib/ethdev/rte_flow.h                  | 274 +++++++++++++++++++++++++\n lib/ethdev/rte_flow_driver.h           |  37 ++++\n lib/ethdev/version.map                 |   6 +\n 6 files changed, 712 insertions(+)",
    "diff": "diff --git a/doc/guides/prog_guide/rte_flow.rst b/doc/guides/prog_guide/rte_flow.rst\nindex c89161faef..6cdfea09be 100644\n--- a/doc/guides/prog_guide/rte_flow.rst\n+++ b/doc/guides/prog_guide/rte_flow.rst\n@@ -3642,6 +3642,141 @@ Information about the number of available resources can be retrieved via\n                      struct rte_flow_port_info *port_info,\n                      struct rte_flow_error *error);\n \n+Flow templates\n+~~~~~~~~~~~~~~\n+\n+Oftentimes in an application, many flow rules share a common structure\n+(the same pattern and/or action list) so they can be grouped and classified\n+together. This knowledge may be used as a source of optimization by a PMD/HW.\n+The flow rule creation is done by selecting a table, a pattern template\n+and an actions template (which are bound to the table), and setting unique\n+values for the items and actions. This API is not thread-safe.\n+\n+Pattern templates\n+^^^^^^^^^^^^^^^^^\n+\n+The pattern template defines a common pattern (the item mask) without values.\n+The mask value is used to select a field to match on, spec/last are ignored.\n+The pattern template may be used by multiple tables and must not be destroyed\n+until all these tables are destroyed first.\n+\n+.. code-block:: c\n+\n+\tstruct rte_flow_pattern_template *\n+\trte_flow_pattern_template_create(uint16_t port_id,\n+\t\tconst struct rte_flow_pattern_template_attr *template_attr,\n+\t\tconst struct rte_flow_item pattern[],\n+\t\tstruct rte_flow_error *error);\n+\n+For example, to create a pattern template to match on the destination MAC:\n+\n+.. code-block:: c\n+\n+\tconst struct rte_flow_pattern_template_attr attr = {.ingress = 1};\n+\tstruct rte_flow_item_eth eth_m = {\n+\t\t.dst.addr_bytes = \"\\xff\\xff\\xff\\xff\\xff\\xff\";\n+\t};\n+\tstruct rte_flow_item pattern[] = {\n+\t\t[0] = {.type = RTE_FLOW_ITEM_TYPE_ETH,\n+\t\t       .mask = &eth_m},\n+\t\t[1] = {.type = RTE_FLOW_ITEM_TYPE_END,},\n+\t};\n+\tstruct rte_flow_error err;\n+\n+\tstruct rte_flow_pattern_template *pattern_template =\n+\t\trte_flow_pattern_template_create(port, &attr, &pattern, &err);\n+\n+The concrete value to match on will be provided at the rule creation.\n+\n+Actions templates\n+^^^^^^^^^^^^^^^^^\n+\n+The actions template holds a list of action types to be used in flow rules.\n+The mask parameter allows specifying a shared constant value for every rule.\n+The actions template may be used by multiple tables and must not be destroyed\n+until all these tables are destroyed first.\n+\n+.. code-block:: c\n+\n+\tstruct rte_flow_actions_template *\n+\trte_flow_actions_template_create(uint16_t port_id,\n+\t\tconst struct rte_flow_actions_template_attr *template_attr,\n+\t\tconst struct rte_flow_action actions[],\n+\t\tconst struct rte_flow_action masks[],\n+\t\tstruct rte_flow_error *error);\n+\n+For example, to create an actions template with the same Mark ID\n+but different Queue Index for every rule:\n+\n+.. code-block:: c\n+\n+\trte_flow_actions_template_attr attr = {.ingress = 1};\n+\tstruct rte_flow_action act[] = {\n+\t\t/* Mark ID is 4 for every rule, Queue Index is unique */\n+\t\t[0] = {.type = RTE_FLOW_ACTION_TYPE_MARK,\n+\t\t       .conf = &(struct rte_flow_action_mark){.id = 4}},\n+\t\t[1] = {.type = RTE_FLOW_ACTION_TYPE_QUEUE},\n+\t\t[2] = {.type = RTE_FLOW_ACTION_TYPE_END,},\n+\t};\n+\tstruct rte_flow_action msk[] = {\n+\t\t/* Assign to MARK mask any non-zero value to make it constant */\n+\t\t[0] = {.type = RTE_FLOW_ACTION_TYPE_MARK,\n+\t\t       .conf = &(struct rte_flow_action_mark){.id = 1}},\n+\t\t[1] = {.type = RTE_FLOW_ACTION_TYPE_QUEUE},\n+\t\t[2] = {.type = RTE_FLOW_ACTION_TYPE_END,},\n+\t};\n+\tstruct rte_flow_error err;\n+\n+\tstruct rte_flow_actions_template *actions_template =\n+\t\trte_flow_actions_template_create(port, &attr, &act, &msk, &err);\n+\n+The concrete value for Queue Index will be provided at the rule creation.\n+\n+Template table\n+^^^^^^^^^^^^^^\n+\n+A template table combines a number of pattern and actions templates along with\n+shared flow rule attributes (group ID, priority and traffic direction).\n+This way a PMD/HW can prepare all the resources needed for efficient flow rules\n+creation in the datapath. To avoid any hiccups due to memory reallocation,\n+the maximum number of flow rules is defined at table creation time.\n+Any flow rule creation beyond the maximum table size is rejected.\n+Application may create another table to accommodate more rules in this case.\n+\n+.. code-block:: c\n+\n+\tstruct rte_flow_template_table *\n+\trte_flow_template_table_create(uint16_t port_id,\n+\t\tconst struct rte_flow_template_table_attr *table_attr,\n+\t\tstruct rte_flow_pattern_template *pattern_templates[],\n+\t\tuint8_t nb_pattern_templates,\n+\t\tstruct rte_flow_actions_template *actions_templates[],\n+\t\tuint8_t nb_actions_templates,\n+\t\tstruct rte_flow_error *error);\n+\n+A table can be created only after the Flow Rules management is configured\n+and pattern and actions templates are created.\n+\n+.. code-block:: c\n+\n+\trte_flow_template_table_attr table_attr = {\n+\t\t.flow_attr.ingress = 1,\n+\t\t.nb_flows = 10000;\n+\t};\n+\tuint8_t nb_pattern_templ = 1;\n+\tstruct rte_flow_pattern_template *pattern_templates[nb_pattern_templ];\n+\tpattern_templates[0] = pattern_template;\n+\tuint8_t nb_actions_templ = 1;\n+\tstruct rte_flow_actions_template *actions_templates[nb_actions_templ];\n+\tactions_templates[0] = actions_template;\n+\tstruct rte_flow_error error;\n+\n+\tstruct rte_flow_template_table *table =\n+\t\trte_flow_template_table_create(port, &table_attr,\n+\t\t\t\t&pattern_templates, nb_pattern_templ,\n+\t\t\t\t&actions_templates, nb_actions_templ,\n+\t\t\t\t&error);\n+\n .. _flow_isolated_mode:\n \n Flow isolated mode\ndiff --git a/doc/guides/rel_notes/release_22_03.rst b/doc/guides/rel_notes/release_22_03.rst\nindex eceab07576..7150d06c87 100644\n--- a/doc/guides/rel_notes/release_22_03.rst\n+++ b/doc/guides/rel_notes/release_22_03.rst\n@@ -105,6 +105,14 @@ New Features\n     engine, allowing to pre-allocate some resources for better performance.\n     Added ``rte_flow_info_get`` API to retrieve available resources.\n \n+  * ethdev: Added ``rte_flow_template_table_create`` API to group flow rules\n+    with the same flow attributes and common matching patterns and actions\n+    defined by ``rte_flow_pattern_template_create`` and\n+    ``rte_flow_actions_template_create`` respectively.\n+    Corresponding functions to destroy these entities are:\n+    ``rte_flow_template_table_destroy``, ``rte_flow_pattern_template_destroy``\n+    and ``rte_flow_actions_template_destroy``.\n+\n * **Updated AF_XDP PMD**\n \n   * Added support for libxdp >=v1.2.2.\ndiff --git a/lib/ethdev/rte_flow.c b/lib/ethdev/rte_flow.c\nindex ffd48e40d5..e9f684eedb 100644\n--- a/lib/ethdev/rte_flow.c\n+++ b/lib/ethdev/rte_flow.c\n@@ -1461,3 +1461,255 @@ rte_flow_configure(uint16_t port_id,\n \t\t\t\t  RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n \t\t\t\t  NULL, rte_strerror(ENOTSUP));\n }\n+\n+struct rte_flow_pattern_template *\n+rte_flow_pattern_template_create(uint16_t port_id,\n+\t\tconst struct rte_flow_pattern_template_attr *template_attr,\n+\t\tconst struct rte_flow_item pattern[],\n+\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\tstruct rte_flow_pattern_template *template;\n+\n+\tif (template_attr == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" template attr is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (pattern == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" pattern is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (dev->data->flow_configured == 0) {\n+\t\tRTE_FLOW_LOG(INFO,\n+\t\t\t\"Flow engine on port_id=%\"PRIu16\" is not configured.\\n\",\n+\t\t\tport_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\tRTE_FLOW_ERROR_TYPE_STATE,\n+\t\t\t\tNULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (unlikely(!ops))\n+\t\treturn NULL;\n+\tif (likely(!!ops->pattern_template_create)) {\n+\t\ttemplate = ops->pattern_template_create(dev, template_attr,\n+\t\t\t\t\t\t\tpattern, error);\n+\t\tif (template == NULL)\n+\t\t\tflow_err(port_id, -rte_errno, error);\n+\t\treturn template;\n+\t}\n+\trte_flow_error_set(error, ENOTSUP,\n+\t\t\t   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t   NULL, rte_strerror(ENOTSUP));\n+\treturn NULL;\n+}\n+\n+int\n+rte_flow_pattern_template_destroy(uint16_t port_id,\n+\t\tstruct rte_flow_pattern_template *pattern_template,\n+\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\n+\tif (unlikely(pattern_template == NULL))\n+\t\treturn 0;\n+\tif (unlikely(!ops))\n+\t\treturn -rte_errno;\n+\tif (likely(!!ops->pattern_template_destroy)) {\n+\t\treturn flow_err(port_id,\n+\t\t\t\tops->pattern_template_destroy(dev,\n+\t\t\t\t\t\t\t      pattern_template,\n+\t\t\t\t\t\t\t      error),\n+\t\t\t\terror);\n+\t}\n+\treturn rte_flow_error_set(error, ENOTSUP,\n+\t\t\t\t  RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t\t  NULL, rte_strerror(ENOTSUP));\n+}\n+\n+struct rte_flow_actions_template *\n+rte_flow_actions_template_create(uint16_t port_id,\n+\t\t\tconst struct rte_flow_actions_template_attr *template_attr,\n+\t\t\tconst struct rte_flow_action actions[],\n+\t\t\tconst struct rte_flow_action masks[],\n+\t\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\tstruct rte_flow_actions_template *template;\n+\n+\tif (template_attr == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" template attr is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (actions == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" actions is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (masks == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" masks is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\n+\t}\n+\tif (dev->data->flow_configured == 0) {\n+\t\tRTE_FLOW_LOG(INFO,\n+\t\t\t\"Flow engine on port_id=%\"PRIu16\" is not configured.\\n\",\n+\t\t\tport_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_STATE,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (unlikely(!ops))\n+\t\treturn NULL;\n+\tif (likely(!!ops->actions_template_create)) {\n+\t\ttemplate = ops->actions_template_create(dev, template_attr,\n+\t\t\t\t\t\t\tactions, masks, error);\n+\t\tif (template == NULL)\n+\t\t\tflow_err(port_id, -rte_errno, error);\n+\t\treturn template;\n+\t}\n+\trte_flow_error_set(error, ENOTSUP,\n+\t\t\t   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t   NULL, rte_strerror(ENOTSUP));\n+\treturn NULL;\n+}\n+\n+int\n+rte_flow_actions_template_destroy(uint16_t port_id,\n+\t\t\tstruct rte_flow_actions_template *actions_template,\n+\t\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\n+\tif (unlikely(actions_template == NULL))\n+\t\treturn 0;\n+\tif (unlikely(!ops))\n+\t\treturn -rte_errno;\n+\tif (likely(!!ops->actions_template_destroy)) {\n+\t\treturn flow_err(port_id,\n+\t\t\t\tops->actions_template_destroy(dev,\n+\t\t\t\t\t\t\t      actions_template,\n+\t\t\t\t\t\t\t      error),\n+\t\t\t\terror);\n+\t}\n+\treturn rte_flow_error_set(error, ENOTSUP,\n+\t\t\t\t  RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t\t  NULL, rte_strerror(ENOTSUP));\n+}\n+\n+struct rte_flow_template_table *\n+rte_flow_template_table_create(uint16_t port_id,\n+\t\t\tconst struct rte_flow_template_table_attr *table_attr,\n+\t\t\tstruct rte_flow_pattern_template *pattern_templates[],\n+\t\t\tuint8_t nb_pattern_templates,\n+\t\t\tstruct rte_flow_actions_template *actions_templates[],\n+\t\t\tuint8_t nb_actions_templates,\n+\t\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\tstruct rte_flow_template_table *table;\n+\n+\tif (table_attr == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" table attr is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (pattern_templates == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" pattern templates is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (actions_templates == NULL) {\n+\t\tRTE_FLOW_LOG(ERR,\n+\t\t\t     \"Port %\"PRIu16\" actions templates is NULL.\\n\",\n+\t\t\t     port_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_ATTR,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (dev->data->flow_configured == 0) {\n+\t\tRTE_FLOW_LOG(INFO,\n+\t\t\t\"Flow engine on port_id=%\"PRIu16\" is not configured.\\n\",\n+\t\t\tport_id);\n+\t\trte_flow_error_set(error, EINVAL,\n+\t\t\t\t   RTE_FLOW_ERROR_TYPE_STATE,\n+\t\t\t\t   NULL, rte_strerror(EINVAL));\n+\t\treturn NULL;\n+\t}\n+\tif (unlikely(!ops))\n+\t\treturn NULL;\n+\tif (likely(!!ops->template_table_create)) {\n+\t\ttable = ops->template_table_create(dev, table_attr,\n+\t\t\t\t\tpattern_templates, nb_pattern_templates,\n+\t\t\t\t\tactions_templates, nb_actions_templates,\n+\t\t\t\t\terror);\n+\t\tif (table == NULL)\n+\t\t\tflow_err(port_id, -rte_errno, error);\n+\t\treturn table;\n+\t}\n+\trte_flow_error_set(error, ENOTSUP,\n+\t\t\t   RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t   NULL, rte_strerror(ENOTSUP));\n+\treturn NULL;\n+}\n+\n+int\n+rte_flow_template_table_destroy(uint16_t port_id,\n+\t\t\t\tstruct rte_flow_template_table *template_table,\n+\t\t\t\tstruct rte_flow_error *error)\n+{\n+\tstruct rte_eth_dev *dev = &rte_eth_devices[port_id];\n+\tconst struct rte_flow_ops *ops = rte_flow_ops_get(port_id, error);\n+\n+\tif (unlikely(template_table == NULL))\n+\t\treturn 0;\n+\tif (unlikely(!ops))\n+\t\treturn -rte_errno;\n+\tif (likely(!!ops->template_table_destroy)) {\n+\t\treturn flow_err(port_id,\n+\t\t\t\tops->template_table_destroy(dev,\n+\t\t\t\t\t\t\t    template_table,\n+\t\t\t\t\t\t\t    error),\n+\t\t\t\terror);\n+\t}\n+\treturn rte_flow_error_set(error, ENOTSUP,\n+\t\t\t\t  RTE_FLOW_ERROR_TYPE_UNSPECIFIED,\n+\t\t\t\t  NULL, rte_strerror(ENOTSUP));\n+}\ndiff --git a/lib/ethdev/rte_flow.h b/lib/ethdev/rte_flow.h\nindex cdb7b2be68..776e8ccc11 100644\n--- a/lib/ethdev/rte_flow.h\n+++ b/lib/ethdev/rte_flow.h\n@@ -4983,6 +4983,280 @@ rte_flow_configure(uint16_t port_id,\n \t\t   const struct rte_flow_port_attr *port_attr,\n \t\t   struct rte_flow_error *error);\n \n+/**\n+ * Opaque type returned after successful creation of pattern template.\n+ * This handle can be used to manage the created pattern template.\n+ */\n+struct rte_flow_pattern_template;\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Flow pattern template attributes.\n+ */\n+__extension__\n+struct rte_flow_pattern_template_attr {\n+\t/**\n+\t * Relaxed matching policy.\n+\t * - PMD may match only on items with mask member set and skip\n+\t * matching on protocol layers specified without any masks.\n+\t * - If not set, PMD will match on protocol layers\n+\t * specified without any masks as well.\n+\t * - Packet data must be stacked in the same order as the\n+\t * protocol layers to match inside packets, starting from the lowest.\n+\t */\n+\tuint32_t relaxed_matching:1;\n+\t/** Pattern valid for rules applied to ingress traffic. */\n+\tuint32_t ingress:1;\n+\t/** Pattern valid for rules applied to egress traffic. */\n+\tuint32_t egress:1;\n+\t/** Pattern valid for rules applied to transfer traffic. */\n+\tuint32_t transfer:1;\n+};\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Create flow pattern template.\n+ *\n+ * The pattern template defines common matching fields without values.\n+ * For example, matching on 5 tuple TCP flow, the template will be\n+ * eth(null) + IPv4(source + dest) + TCP(s_port + d_port),\n+ * while values for each rule will be set during the flow rule creation.\n+ * The number and order of items in the template must be the same\n+ * at the rule creation.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] template_attr\n+ *   Pattern template attributes.\n+ * @param[in] pattern\n+ *   Pattern specification (list terminated by the END pattern item).\n+ *   The spec member of an item is not used unless the end member is used.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   Handle on success, NULL otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+struct rte_flow_pattern_template *\n+rte_flow_pattern_template_create(uint16_t port_id,\n+\t\tconst struct rte_flow_pattern_template_attr *template_attr,\n+\t\tconst struct rte_flow_item pattern[],\n+\t\tstruct rte_flow_error *error);\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Destroy flow pattern template.\n+ *\n+ * This function may be called only when\n+ * there are no more tables referencing this template.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] pattern_template\n+ *   Handle of the template to be destroyed.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   0 on success, a negative errno value otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+int\n+rte_flow_pattern_template_destroy(uint16_t port_id,\n+\t\tstruct rte_flow_pattern_template *pattern_template,\n+\t\tstruct rte_flow_error *error);\n+\n+/**\n+ * Opaque type returned after successful creation of actions template.\n+ * This handle can be used to manage the created actions template.\n+ */\n+struct rte_flow_actions_template;\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Flow actions template attributes.\n+ */\n+__extension__\n+struct rte_flow_actions_template_attr {\n+\t/** Action valid for rules applied to ingress traffic. */\n+\tuint32_t ingress:1;\n+\t/** Action valid for rules applied to egress traffic. */\n+\tuint32_t egress:1;\n+\t/** Action valid for rules applied to transfer traffic. */\n+\tuint32_t transfer:1;\n+};\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Create flow actions template.\n+ *\n+ * The actions template holds a list of action types without values.\n+ * For example, the template to change TCP ports is TCP(s_port + d_port),\n+ * while values for each rule will be set during the flow rule creation.\n+ * The number and order of actions in the template must be the same\n+ * at the rule creation.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] template_attr\n+ *   Template attributes.\n+ * @param[in] actions\n+ *   Associated actions (list terminated by the END action).\n+ *   The spec member is only used if @p masks spec is non-zero.\n+ * @param[in] masks\n+ *   List of actions that marks which of the action's member is constant.\n+ *   A mask has the same format as the corresponding action.\n+ *   If the action field in @p masks is not 0,\n+ *   the corresponding value in an action from @p actions will be the part\n+ *   of the template and used in all flow rules.\n+ *   The order of actions in @p masks is the same as in @p actions.\n+ *   In case of indirect actions present in @p actions,\n+ *   the actual action type should be present in @p mask.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   Handle on success, NULL otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+struct rte_flow_actions_template *\n+rte_flow_actions_template_create(uint16_t port_id,\n+\t\tconst struct rte_flow_actions_template_attr *template_attr,\n+\t\tconst struct rte_flow_action actions[],\n+\t\tconst struct rte_flow_action masks[],\n+\t\tstruct rte_flow_error *error);\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Destroy flow actions template.\n+ *\n+ * This function may be called only when\n+ * there are no more tables referencing this template.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] actions_template\n+ *   Handle to the template to be destroyed.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   0 on success, a negative errno value otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+int\n+rte_flow_actions_template_destroy(uint16_t port_id,\n+\t\tstruct rte_flow_actions_template *actions_template,\n+\t\tstruct rte_flow_error *error);\n+\n+/**\n+ * Opaque type returned after successful creation of a template table.\n+ * This handle can be used to manage the created template table.\n+ */\n+struct rte_flow_template_table;\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Table attributes.\n+ */\n+struct rte_flow_template_table_attr {\n+\t/**\n+\t * Flow attributes to be used in each rule generated from this table.\n+\t */\n+\tstruct rte_flow_attr flow_attr;\n+\t/**\n+\t * Maximum number of flow rules that this table holds.\n+\t */\n+\tuint32_t nb_flows;\n+};\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Create flow template table.\n+ *\n+ * A template table consists of multiple pattern templates and actions\n+ * templates associated with a single set of rule attributes (group ID,\n+ * priority and traffic direction).\n+ *\n+ * Each rule is free to use any combination of pattern and actions templates\n+ * and specify particular values for items and actions it would like to change.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] table_attr\n+ *   Template table attributes.\n+ * @param[in] pattern_templates\n+ *   Array of pattern templates to be used in this table.\n+ * @param[in] nb_pattern_templates\n+ *   The number of pattern templates in the pattern_templates array.\n+ * @param[in] actions_templates\n+ *   Array of actions templates to be used in this table.\n+ * @param[in] nb_actions_templates\n+ *   The number of actions templates in the actions_templates array.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   Handle on success, NULL otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+struct rte_flow_template_table *\n+rte_flow_template_table_create(uint16_t port_id,\n+\t\tconst struct rte_flow_template_table_attr *table_attr,\n+\t\tstruct rte_flow_pattern_template *pattern_templates[],\n+\t\tuint8_t nb_pattern_templates,\n+\t\tstruct rte_flow_actions_template *actions_templates[],\n+\t\tuint8_t nb_actions_templates,\n+\t\tstruct rte_flow_error *error);\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Destroy flow template table.\n+ *\n+ * This function may be called only when\n+ * there are no more flow rules referencing this table.\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] template_table\n+ *   Handle to the table to be destroyed.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL.\n+ *   PMDs initialize this structure in case of error only.\n+ *\n+ * @return\n+ *   0 on success, a negative errno value otherwise and rte_errno is set.\n+ */\n+__rte_experimental\n+int\n+rte_flow_template_table_destroy(uint16_t port_id,\n+\t\tstruct rte_flow_template_table *template_table,\n+\t\tstruct rte_flow_error *error);\n+\n #ifdef __cplusplus\n }\n #endif\ndiff --git a/lib/ethdev/rte_flow_driver.h b/lib/ethdev/rte_flow_driver.h\nindex 7c29930d0f..2d96db1dc7 100644\n--- a/lib/ethdev/rte_flow_driver.h\n+++ b/lib/ethdev/rte_flow_driver.h\n@@ -162,6 +162,43 @@ struct rte_flow_ops {\n \t\t(struct rte_eth_dev *dev,\n \t\t const struct rte_flow_port_attr *port_attr,\n \t\t struct rte_flow_error *err);\n+\t/** See rte_flow_pattern_template_create() */\n+\tstruct rte_flow_pattern_template *(*pattern_template_create)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t const struct rte_flow_pattern_template_attr *template_attr,\n+\t\t const struct rte_flow_item pattern[],\n+\t\t struct rte_flow_error *err);\n+\t/** See rte_flow_pattern_template_destroy() */\n+\tint (*pattern_template_destroy)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t struct rte_flow_pattern_template *pattern_template,\n+\t\t struct rte_flow_error *err);\n+\t/** See rte_flow_actions_template_create() */\n+\tstruct rte_flow_actions_template *(*actions_template_create)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t const struct rte_flow_actions_template_attr *template_attr,\n+\t\t const struct rte_flow_action actions[],\n+\t\t const struct rte_flow_action masks[],\n+\t\t struct rte_flow_error *err);\n+\t/** See rte_flow_actions_template_destroy() */\n+\tint (*actions_template_destroy)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t struct rte_flow_actions_template *actions_template,\n+\t\t struct rte_flow_error *err);\n+\t/** See rte_flow_template_table_create() */\n+\tstruct rte_flow_template_table *(*template_table_create)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t const struct rte_flow_template_table_attr *table_attr,\n+\t\t struct rte_flow_pattern_template *pattern_templates[],\n+\t\t uint8_t nb_pattern_templates,\n+\t\t struct rte_flow_actions_template *actions_templates[],\n+\t\t uint8_t nb_actions_templates,\n+\t\t struct rte_flow_error *err);\n+\t/** See rte_flow_template_table_destroy() */\n+\tint (*template_table_destroy)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t struct rte_flow_template_table *template_table,\n+\t\t struct rte_flow_error *err);\n };\n \n /**\ndiff --git a/lib/ethdev/version.map b/lib/ethdev/version.map\nindex 0d849c153f..62ff791261 100644\n--- a/lib/ethdev/version.map\n+++ b/lib/ethdev/version.map\n@@ -266,6 +266,12 @@ EXPERIMENTAL {\n \trte_eth_ip_reassembly_conf_set;\n \trte_flow_info_get;\n \trte_flow_configure;\n+\trte_flow_pattern_template_create;\n+\trte_flow_pattern_template_destroy;\n+\trte_flow_actions_template_create;\n+\trte_flow_actions_template_destroy;\n+\trte_flow_template_table_create;\n+\trte_flow_template_table_destroy;\n };\n \n INTERNAL {\n",
    "prefixes": [
        "v8",
        "02/11"
    ]
}