get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 76153,
    "url": "http://patches.dpdk.org/api/patches/76153/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20200830111544.4190-4-wisamm@mellanox.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": "<20200830111544.4190-4-wisamm@mellanox.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20200830111544.4190-4-wisamm@mellanox.com",
    "date": "2020-08-30T11:15:34",
    "name": "[03/13] app/flow-perf: start supporting user order",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "20a31f6ed439aed0a55fdb5b7374f400840c1b7d",
    "submitter": {
        "id": 938,
        "url": "http://patches.dpdk.org/api/people/938/?format=api",
        "name": "Wisam Jaddo",
        "email": "wisamm@mellanox.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/20200830111544.4190-4-wisamm@mellanox.com/mbox/",
    "series": [
        {
            "id": 11848,
            "url": "http://patches.dpdk.org/api/series/11848/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=11848",
            "date": "2020-08-30T11:15:31",
            "name": "app/flow-perf: add support for new items/actions",
            "version": 1,
            "mbox": "http://patches.dpdk.org/series/11848/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/76153/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/76153/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 dpdk.org (dpdk.org [92.243.14.124])\n\tby inbox.dpdk.org (Postfix) with ESMTP id 30E8BA04AB;\n\tSun, 30 Aug 2020 13:19:03 +0200 (CEST)",
            "from [92.243.14.124] (localhost [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id C74231C0B6;\n\tSun, 30 Aug 2020 13:16:28 +0200 (CEST)",
            "from EUR02-AM5-obe.outbound.protection.outlook.com\n (mail-eopbgr00052.outbound.protection.outlook.com [40.107.0.52])\n by dpdk.org (Postfix) with ESMTP id 8E1311C0AD\n for <dev@dpdk.org>; Sun, 30 Aug 2020 13:16:26 +0200 (CEST)",
            "from AM0PR05MB6610.eurprd05.prod.outlook.com (2603:10a6:208:12f::18)\n by AM0PR0502MB3762.eurprd05.prod.outlook.com (2603:10a6:208:1b::31)\n with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3326.21; Sun, 30 Aug\n 2020 11:16:25 +0000",
            "from AM0PR05MB6610.eurprd05.prod.outlook.com\n ([fe80::4c8a:9848:2e2a:3598]) by AM0PR05MB6610.eurprd05.prod.outlook.com\n ([fe80::4c8a:9848:2e2a:3598%6]) with mapi id 15.20.3326.025; Sun, 30 Aug 2020\n 11:16:24 +0000",
            "from mellanox.com (37.142.13.130) by\n AM4PR05CA0008.eurprd05.prod.outlook.com (2603:10a6:205::21) with Microsoft\n SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.20.3326.19 via Frontend Transport; Sun, 30 Aug 2020 11:16:23 +0000"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;\n b=a6/LitInftCZPpvQ70AMHCu818tqv4Tz43w86qtJ5Nl36whsC4rp05Le63BkX0dzKGfdNTGPZO+eVbwu5KokKl5pkL6kjnIC8fzjSg9T8oXtIwGSe5JZkJr6ktM8MrmDqKmC5p7yF8wFgTUQKxZq6BUQFoC2MH3MTqFPzHXzsTYsSXSy97I60faqxd2n0Ka0Wa4ccWEtG9KFsE2dXGGIReAoNiU28RI1h4PsPcn4WHkJKDq8M3PBGOCcojYLOvGKbWsfty/DFcUz938T8Dc3K7ku822drarZyQD0h5ooBcOXq2qmFq8UNRUD5jZ0pFDmBuDoFVn/k2Ji/n8AAXaOSA==",
        "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-SenderADCheck;\n bh=5DtqIX8ywqdiB9eSVLrFi1FyZkoErflAXwcdutTKrB8=;\n b=EkhGPOXo1wmnvPFM6wo970nkN7LsGSfGhJkbC+2PBi3W9X4vTiGyZiFtnUb+SimaAGlezG9oiG9L1vXdKMwImOInQlHzI2Ca6AJnrLBLDwPyCsVX5ZvMg0cjM9BpDp9s2JJh1hbcZzbSXcnOAcXpsJ6XWJyx1UKUl1oKeLlDMf77phSM4IrUPsTSsdheyXT4kxzE9BwXWYTHIxfzqJZ0gPytmi7IzmH0uQgGrRME7QEg2L2wUVym5Yg9FjEjrOPJUwXfNoh+mHPHnitWeSiLVy5m0hNywwlbpdiF9tuiN1lEc8rgfls4xXOxe/fEe5pRGl/ZJED7Edhwwm+wmstOUw==",
        "ARC-Authentication-Results": "i=1; mx.microsoft.com 1; spf=pass\n smtp.mailfrom=mellanox.com; dmarc=pass action=none header.from=mellanox.com;\n dkim=pass header.d=mellanox.com; arc=none",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=Mellanox.com;\n s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=5DtqIX8ywqdiB9eSVLrFi1FyZkoErflAXwcdutTKrB8=;\n b=C+DKef43hubQhey0tHDLe+Xo/kw5Xv2Dsz/j1ExJuLmWcf5wfBZ55kIjCdpbzVBDgyT5ZCBxulwRQRuKKaZ3tMBOaHS/lFxfpolENaYz/1eP5smhVTTwXs177Z7KHwe2acTlxlOG4Bqcjbn2pAeupgrNVWIPgMJ+vAIAZG0dZd8=",
        "Authentication-Results": "dpdk.org; dkim=none (message not signed)\n header.d=none;dpdk.org; dmarc=none action=none header.from=mellanox.com;",
        "From": "Wisam Jaddo <wisamm@mellanox.com>",
        "To": "dev@dpdk.org, thomas@monjalon.net, asafp@mellanox.com,\n akozyrev@nvidia.com,\n akozyrev@mellanox.com, arybchenko@solarflare.com, jackmin@mellanox.com",
        "Date": "Sun, 30 Aug 2020 11:15:34 +0000",
        "Message-Id": "<20200830111544.4190-4-wisamm@mellanox.com>",
        "X-Mailer": [
            "git-send-email 2.17.1",
            "git-send-email 2.17.1"
        ],
        "In-Reply-To": "<20200830111544.4190-1-wisamm@mellanox.com>",
        "References": "<20200830111544.4190-1-wisamm@mellanox.com>",
        "Content-Type": "text/plain",
        "X-ClientProxiedBy": "AM4PR05CA0008.eurprd05.prod.outlook.com (2603:10a6:205::21)\n To AM0PR05MB6610.eurprd05.prod.outlook.com\n (2603:10a6:208:12f::18)",
        "MIME-Version": "1.0",
        "X-MS-Exchange-MessageSentRepresentingType": "1",
        "X-Originating-IP": "[37.142.13.130]",
        "X-MS-PublicTrafficType": "Email",
        "X-MS-Office365-Filtering-HT": "Tenant",
        "X-MS-Office365-Filtering-Correlation-Id": "b6d660ca-7e85-4627-f237-08d84cd621bd",
        "X-MS-TrafficTypeDiagnostic": "AM0PR0502MB3762:",
        "X-LD-Processed": "a652971c-7d2e-4d9b-a6a4-d149256f461b,ExtFwd,ExtAddr",
        "X-MS-Exchange-Transport-Forked": "True",
        "X-Microsoft-Antispam-PRVS": "\n <AM0PR0502MB3762E266CF90C5344FD94F5CA9500@AM0PR0502MB3762.eurprd05.prod.outlook.com>",
        "X-MS-Oob-TLC-OOBClassifiers": "OLM:7691;",
        "X-MS-Exchange-SenderADCheck": "1",
        "X-Microsoft-Antispam": "BCL:0;",
        "X-Microsoft-Antispam-Message-Info": "\n KGdz5eQW/A2c3CMNaA0VYO5vSQ5ZghoaYQ+eZa8IoUfz7qDAv2gLMh6DBPeEAjLBmIqrl1XV5IlLyKsInTsOyKPz9QbQNM5dL6HKy/t9m+gRPrA0KWi0ck7lR1bacs2mEqFKR+Muu4aNx/bX0e4JtXltkWzgak6ap7UnHLNIg8SG2P7UgTMRJDcEfdYtOxSBdtUL8RNKkOHTySu8hTYXNFoSjh/5u8lfjJl9K1PKioFgIy3iAi1SSEoRNaf04ToYn8KSTkFsOxvjbTriVhZbO4SyIMyEOYZ7pL1heNwxORXOHTZpoCKYH8q91X7C3yBK",
        "X-Forefront-Antispam-Report": "CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;\n IPV:NLI; SFV:NSPM; H:AM0PR05MB6610.eurprd05.prod.outlook.com; PTR:; CAT:NONE;\n SFS:(4636009)(366004)(396003)(136003)(39860400002)(376002)(346002)(478600001)(316002)(5660300002)(8886007)(30864003)(2906002)(6636002)(86362001)(36756003)(6666004)(1076003)(55016002)(8936002)(26005)(2616005)(7696005)(66946007)(66556008)(52116002)(83380400001)(16526019)(8676002)(186003)(956004)(66476007);\n DIR:OUT; SFP:1101;",
        "X-MS-Exchange-AntiSpam-MessageData": "\n ZmzI59WyJPaZ3n0HO5/P/hh56B4dvah7le8nXEnbyNH8/n8yZ8S8ksE63cO6zZwU2Mb6Cwv5I7uJyzAPPXABFJETyppT5Nt4j5kDu8jf4ZS23i4mPJMzYW0/UVPNWPzJXDE0m3KRZZsn2sOfvf1iL5qRyXyGfsHwz1V61RjiTepaUQJQsitC/j6K1azPzDkE/ycQz0UZmOa17FB3Yrlud2Bwp7TDfHSvUFjgT6WyhIwQ4TD/t7yOBlz5I1AXVAeehsjd7CrAg5pJwWtWhgGCwy+QFMeXEW3z/2j6Zw0NUgt90ox+p8hfEGKFKQUIPHdXDjLtzmgAECWpY6w17PRfl3u1a+Ym0v+PzkpYtVqzuCjhpPmmtJCGHMOQ8pMPU6BW8RUrZsWJ9T/klZYqglFJGKgY5KGw1NAKGpWivv9Gou970wfIUKiQb0OoVHNZfQ7OpXrAc5Z+7MI4tLhKZdilOlBX9CxooG4rMk37pGuyH6uD3auO2af5S81fZfyV8FrQWQ0Ck+nF1ciVKs7a7ms6GNZ3gHtoZcExOuhEEO65S97DJXoE3pwP4r8AkTa3xBeaaObLxOgs3g4UnrBak0VULyea+CwKyk0k0FmiBiRcym19JaWoDun2JeTL3sOvLc8Wo9loQjdODK4wyUz1uZcx2A==",
        "X-OriginatorOrg": "Mellanox.com",
        "X-MS-Exchange-CrossTenant-Network-Message-Id": "\n b6d660ca-7e85-4627-f237-08d84cd621bd",
        "X-MS-Exchange-CrossTenant-AuthSource": "AM0PR05MB6610.eurprd05.prod.outlook.com",
        "X-MS-Exchange-CrossTenant-AuthAs": "Internal",
        "X-MS-Exchange-CrossTenant-OriginalArrivalTime": "30 Aug 2020 11:16:24.8492 (UTC)",
        "X-MS-Exchange-CrossTenant-FromEntityHeader": "Hosted",
        "X-MS-Exchange-CrossTenant-Id": "a652971c-7d2e-4d9b-a6a4-d149256f461b",
        "X-MS-Exchange-CrossTenant-MailboxType": "HOSTED",
        "X-MS-Exchange-CrossTenant-UserPrincipalName": "\n mAbGKG2ydzaVGaEukvYCOpXZqyJYJaFgJ6HAoWqifG2hByB0C8GdRHk2bOLPI6CU3eJMwg5n/FYvzGJ8r5ydvQ==",
        "X-MS-Exchange-Transport-CrossTenantHeadersStamped": "AM0PR0502MB3762",
        "Subject": "[dpdk-dev] [PATCH 03/13] app/flow-perf: start supporting user order",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "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",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "The old design was using the bit mask to identify\nitems, action and attributes.\n\nSo it was all based on the order of the code itself,\nto place the order of the actions, items & attributes\ninside the flows. Such design will lead into many failures\nwhen some PMD support order different than other PMD,\nin the end the rules will fail to create. Also sometimes\nthe user needs to have one action before other actions\nand vice versa, so using new design of arrays that\ntake user order into consideration make more sense.\n\nAfter this patch, we start supporting inner items\nand more than one instance of same action.\n\nSigned-off-by: Wisam Jaddo <wisamm@mellanox.com>\nAcked-by: Alexander Kozyrev <akozyrev@nvidia.com>\n---\n app/test-flow-perf/actions_gen.c       |  26 +++---\n app/test-flow-perf/actions_gen.h       |   2 +-\n app/test-flow-perf/config.h            |   1 +\n app/test-flow-perf/flow_gen.c          |  25 +++---\n app/test-flow-perf/flow_gen.h          |   6 +-\n app/test-flow-perf/items_gen.c         |  26 +++---\n app/test-flow-perf/items_gen.h         |   2 +-\n app/test-flow-perf/main.c              | 106 ++++++++++++++++---------\n doc/guides/rel_notes/release_20_08.rst |   8 ++\n doc/guides/tools/flow-perf.rst         |  12 ++-\n 10 files changed, 135 insertions(+), 79 deletions(-)",
    "diff": "diff --git a/app/test-flow-perf/actions_gen.c b/app/test-flow-perf/actions_gen.c\nindex cb9316f1df..d115cdd723 100644\n--- a/app/test-flow-perf/actions_gen.c\n+++ b/app/test-flow-perf/actions_gen.c\n@@ -182,14 +182,14 @@ add_count(struct rte_flow_action *actions,\n }\n \n void\n-fill_actions(struct rte_flow_action *actions, uint64_t flow_actions,\n+fill_actions(struct rte_flow_action *actions, uint64_t *flow_actions,\n \tuint32_t counter, uint16_t next_table, uint16_t hairpinq)\n {\n \tstruct additional_para additional_para_data;\n \tuint8_t actions_counter = 0;\n \tuint16_t hairpin_queues[hairpinq];\n \tuint16_t queues[RXQ_NUM];\n-\tuint16_t i;\n+\tuint16_t i, j;\n \n \tfor (i = 0; i < RXQ_NUM; i++)\n \t\tqueues[i] = i;\n@@ -217,7 +217,7 @@ fill_actions(struct rte_flow_action *actions, uint64_t flow_actions,\n \t\t\tuint8_t actions_counter,\n \t\t\tstruct additional_para para\n \t\t\t);\n-\t} flows_actions[] = {\n+\t} actions_list[] = {\n \t\t{\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_MARK),\n \t\t\t.funct = add_mark,\n@@ -264,13 +264,19 @@ fill_actions(struct rte_flow_action *actions, uint64_t flow_actions,\n \t\t},\n \t};\n \n-\tfor (i = 0; i < RTE_DIM(flows_actions); i++) {\n-\t\tif ((flow_actions & flows_actions[i].mask) == 0)\n-\t\t\tcontinue;\n-\t\tflows_actions[i].funct(\n-\t\t\tactions, actions_counter++,\n-\t\t\tadditional_para_data\n-\t\t);\n+\tfor (j = 0; j < MAX_ACTIONS_NUM; j++) {\n+\t\tif (flow_actions[j] == 0)\n+\t\t\tbreak;\n+\t\tfor (i = 0; i < RTE_DIM(actions_list); i++) {\n+\t\t\tif ((flow_actions[j] &\n+\t\t\t\tactions_list[i].mask) == 0)\n+\t\t\t\tcontinue;\n+\t\t\tactions_list[i].funct(\n+\t\t\t\tactions, actions_counter++,\n+\t\t\t\tadditional_para_data\n+\t\t\t);\n+\t\t\tbreak;\n+\t\t}\n \t}\n \tactions[actions_counter].type = RTE_FLOW_ACTION_TYPE_END;\n }\ndiff --git a/app/test-flow-perf/actions_gen.h b/app/test-flow-perf/actions_gen.h\nindex 0defa7c97c..d6918a53a6 100644\n--- a/app/test-flow-perf/actions_gen.h\n+++ b/app/test-flow-perf/actions_gen.h\n@@ -12,7 +12,7 @@\n \n #include \"config.h\"\n \n-void fill_actions(struct rte_flow_action *actions, uint64_t actions_selector,\n+void fill_actions(struct rte_flow_action *actions, uint64_t *flow_actions,\n \tuint32_t counter, uint16_t next_table, uint16_t hairpinq);\n \n #endif /* FLOW_PERF_ACTION_GEN */\ndiff --git a/app/test-flow-perf/config.h b/app/test-flow-perf/config.h\nindex e47d788572..439f3264b4 100644\n--- a/app/test-flow-perf/config.h\n+++ b/app/test-flow-perf/config.h\n@@ -29,3 +29,4 @@\n /* Flow items/acctions max size */\n #define MAX_ITEMS_NUM 32\n #define MAX_ACTIONS_NUM 32\n+#define MAX_ATTRS_NUM 16\ndiff --git a/app/test-flow-perf/flow_gen.c b/app/test-flow-perf/flow_gen.c\nindex e87276bd14..b2c828c7df 100644\n--- a/app/test-flow-perf/flow_gen.c\n+++ b/app/test-flow-perf/flow_gen.c\n@@ -18,23 +18,28 @@\n \n static void\n fill_attributes(struct rte_flow_attr *attr,\n-\tuint64_t flow_attrs, uint16_t group)\n+\tuint64_t *flow_attrs, uint16_t group)\n {\n-\tif (flow_attrs & INGRESS)\n-\t\tattr->ingress = 1;\n-\tif (flow_attrs & EGRESS)\n-\t\tattr->egress = 1;\n-\tif (flow_attrs & TRANSFER)\n-\t\tattr->transfer = 1;\n+\tuint8_t i;\n+\tfor (i = 0; i < MAX_ATTRS_NUM; i++) {\n+\t\tif (flow_attrs[i] == 0)\n+\t\t\tbreak;\n+\t\tif (flow_attrs[i] & INGRESS)\n+\t\t\tattr->ingress = 1;\n+\t\telse if (flow_attrs[i] & EGRESS)\n+\t\t\tattr->egress = 1;\n+\t\telse if (flow_attrs[i] & TRANSFER)\n+\t\t\tattr->transfer = 1;\n+\t}\n \tattr->group = group;\n }\n \n struct rte_flow *\n generate_flow(uint16_t port_id,\n \tuint16_t group,\n-\tuint64_t flow_attrs,\n-\tuint64_t flow_items,\n-\tuint64_t flow_actions,\n+\tuint64_t *flow_attrs,\n+\tuint64_t *flow_items,\n+\tuint64_t *flow_actions,\n \tuint16_t next_table,\n \tuint32_t outer_ip_src,\n \tuint16_t hairpinq,\ndiff --git a/app/test-flow-perf/flow_gen.h b/app/test-flow-perf/flow_gen.h\nindex 848331e229..53469c659f 100644\n--- a/app/test-flow-perf/flow_gen.h\n+++ b/app/test-flow-perf/flow_gen.h\n@@ -26,9 +26,9 @@\n struct rte_flow *\n generate_flow(uint16_t port_id,\n \tuint16_t group,\n-\tuint64_t flow_attrs,\n-\tuint64_t flow_items,\n-\tuint64_t flow_actions,\n+\tuint64_t *flow_attrs,\n+\tuint64_t *flow_items,\n+\tuint64_t *flow_actions,\n \tuint16_t next_table,\n \tuint32_t outer_ip_src,\n \tuint16_t hairpinq,\ndiff --git a/app/test-flow-perf/items_gen.c b/app/test-flow-perf/items_gen.c\nindex 6a8915100c..cc031f24a5 100644\n--- a/app/test-flow-perf/items_gen.c\n+++ b/app/test-flow-perf/items_gen.c\n@@ -312,10 +312,10 @@ add_meta_tag(struct rte_flow_item *items,\n \n void\n fill_items(struct rte_flow_item *items,\n-\tuint64_t flow_items, uint32_t outer_ip_src)\n+\tuint64_t *flow_items, uint32_t outer_ip_src)\n {\n \tuint8_t items_counter = 0;\n-\tuint8_t i;\n+\tuint8_t i, j;\n \tstruct additional_para additional_para_data = {\n \t\t.src_ip = outer_ip_src,\n \t};\n@@ -328,7 +328,7 @@ fill_items(struct rte_flow_item *items,\n \t\t\tuint8_t items_counter,\n \t\t\tstruct additional_para para\n \t\t\t);\n-\t} flows_items[] = {\n+\t} items_list[] = {\n \t\t{\n \t\t\t.mask = RTE_FLOW_ITEM_TYPE_META,\n \t\t\t.funct = add_meta_data,\n@@ -384,13 +384,19 @@ fill_items(struct rte_flow_item *items,\n \n \t};\n \n-\tfor (i = 0; i < RTE_DIM(flows_items); i++) {\n-\t\tif ((flow_items & FLOW_ITEM_MASK(flows_items[i].mask)) == 0)\n-\t\t\tcontinue;\n-\t\tflows_items[i].funct(\n-\t\t\titems, items_counter++,\n-\t\t\tadditional_para_data\n-\t\t);\n+\tfor (j = 0; j < MAX_ITEMS_NUM; j++) {\n+\t\tif (flow_items[j] == 0)\n+\t\t\tbreak;\n+\t\tfor (i = 0; i < RTE_DIM(items_list); i++) {\n+\t\t\tif ((flow_items[j] &\n+\t\t\t\tFLOW_ITEM_MASK(items_list[i].mask)) == 0)\n+\t\t\t\tcontinue;\n+\t\t\titems_list[i].funct(\n+\t\t\t\titems, items_counter++,\n+\t\t\t\tadditional_para_data\n+\t\t\t);\n+\t\t\tbreak;\n+\t\t}\n \t}\n \n \titems[items_counter].type = RTE_FLOW_ITEM_TYPE_END;\ndiff --git a/app/test-flow-perf/items_gen.h b/app/test-flow-perf/items_gen.h\nindex 9509d0f11c..d68958e4d3 100644\n--- a/app/test-flow-perf/items_gen.h\n+++ b/app/test-flow-perf/items_gen.h\n@@ -12,7 +12,7 @@\n \n #include \"config.h\"\n \n-void fill_items(struct rte_flow_item *items, uint64_t flow_items,\n+void fill_items(struct rte_flow_item *items, uint64_t *flow_items,\n \tuint32_t outer_ip_src);\n \n #endif /* FLOW_PERF_ITEMS_GEN */\ndiff --git a/app/test-flow-perf/main.c b/app/test-flow-perf/main.c\nindex 3589b316f9..0ff8080aa0 100644\n--- a/app/test-flow-perf/main.c\n+++ b/app/test-flow-perf/main.c\n@@ -45,9 +45,10 @@\n struct rte_flow *flow;\n static uint8_t flow_group;\n \n-static uint64_t flow_items;\n-static uint64_t flow_actions;\n-static uint64_t flow_attrs;\n+static uint64_t flow_items[MAX_ITEMS_NUM];\n+static uint64_t flow_actions[MAX_ACTIONS_NUM];\n+static uint64_t flow_attrs[MAX_ATTRS_NUM];\n+static uint8_t items_idx, actions_idx, attrs_idx;\n \n static volatile bool force_quit;\n static bool dump_iterations;\n@@ -150,132 +151,159 @@ args_parse(int argc, char **argv)\n \tstatic const struct option_dict {\n \t\tconst char *str;\n \t\tconst uint64_t mask;\n-\t\tuint64_t *bitmap;\n+\t\tuint64_t *map;\n+\t\tuint8_t *map_idx;\n+\n \t} flow_options[] = {\n \t\t{\n \t\t\t.str = \"ether\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_ETH),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"ipv4\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_IPV4),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"ipv6\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_IPV6),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"vlan\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_VLAN),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"tcp\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_TCP),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"udp\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_UDP),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"vxlan\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_VXLAN),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"vxlan-gpe\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_VXLAN_GPE),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"gre\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_GRE),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"geneve\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_GENEVE),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"gtp\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_GTP),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"meta\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_META),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"tag\",\n \t\t\t.mask = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_TAG),\n-\t\t\t.bitmap = &flow_items\n+\t\t\t.map = &flow_items[0],\n+\t\t\t.map_idx = &items_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"ingress\",\n \t\t\t.mask = INGRESS,\n-\t\t\t.bitmap = &flow_attrs\n+\t\t\t.map = &flow_attrs[0],\n+\t\t\t.map_idx = &attrs_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"egress\",\n \t\t\t.mask = EGRESS,\n-\t\t\t.bitmap = &flow_attrs\n+\t\t\t.map = &flow_attrs[0],\n+\t\t\t.map_idx = &attrs_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"transfer\",\n \t\t\t.mask = TRANSFER,\n-\t\t\t.bitmap = &flow_attrs\n+\t\t\t.map = &flow_attrs[0],\n+\t\t\t.map_idx = &attrs_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"port-id\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_PORT_ID),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"rss\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_RSS),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"queue\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_QUEUE),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"jump\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_JUMP),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"mark\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_MARK),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"count\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_COUNT),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"set-meta\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_SET_META),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"set-tag\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_SET_TAG),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t},\n \t\t{\n \t\t\t.str = \"drop\",\n \t\t\t.mask = FLOW_ACTION_MASK(RTE_FLOW_ACTION_TYPE_DROP),\n-\t\t\t.bitmap = &flow_actions\n+\t\t\t.map = &flow_actions[0],\n+\t\t\t.map_idx = &actions_idx\n \t\t}\n \t};\n \n@@ -320,9 +348,6 @@ args_parse(int argc, char **argv)\n \t\t{ \"hairpin-rss\",                1, 0, 0 },\n \t};\n \n-\tflow_items = 0;\n-\tflow_actions = 0;\n-\tflow_attrs = 0;\n \thairpin_queues_num = 0;\n \targvopt = argv;\n \n@@ -349,7 +374,8 @@ args_parse(int argc, char **argv)\n \t\t\tfor (i = 0; i < RTE_DIM(flow_options); i++)\n \t\t\t\tif (strcmp(lgopts[opt_idx].name,\n \t\t\t\t\t\tflow_options[i].str) == 0) {\n-\t\t\t\t\t*flow_options[i].bitmap |=\n+\t\t\t\t\tflow_options[i].map[\n+\t\t\t\t\t(*flow_options[i].map_idx)++] =\n \t\t\t\t\t\tflow_options[i].mask;\n \t\t\t\t\tprintf(\"%s / \", flow_options[i].str);\n \t\t\t\t}\n@@ -363,7 +389,8 @@ args_parse(int argc, char **argv)\n \t\t\t\t\trte_exit(EXIT_SUCCESS,\n \t\t\t\t\t\t\"Hairpin queues should be > 0\\n\");\n \n-\t\t\t\tflow_actions |= HAIRPIN_RSS_ACTION;\n+\t\t\t\tflow_actions[actions_idx++] =\n+\t\t\t\t\tHAIRPIN_RSS_ACTION;\n \t\t\t\tprintf(\"hairpin-rss / \");\n \t\t\t}\n \t\t\tif (strcmp(lgopts[opt_idx].name,\n@@ -375,7 +402,8 @@ args_parse(int argc, char **argv)\n \t\t\t\t\trte_exit(EXIT_SUCCESS,\n \t\t\t\t\t\t\"Hairpin queues should be > 0\\n\");\n \n-\t\t\t\tflow_actions |= HAIRPIN_QUEUE_ACTION;\n+\t\t\t\tflow_actions[actions_idx++] =\n+\t\t\t\t\tHAIRPIN_QUEUE_ACTION;\n \t\t\t\tprintf(\"hairpin-queue / \");\n \t\t\t}\n \n@@ -558,6 +586,11 @@ flows_handler(void)\n \tint port_id;\n \tint iter_id;\n \tuint32_t flow_index;\n+\tuint64_t global_items[MAX_ITEMS_NUM] = { 0 };\n+\tuint64_t global_actions[MAX_ACTIONS_NUM] = { 0 };\n+\n+\tglobal_items[0] = FLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_ETH);\n+\tglobal_actions[0] = FLOW_ITEM_MASK(RTE_FLOW_ACTION_TYPE_JUMP);\n \n \tnr_ports = rte_eth_dev_count_avail();\n \n@@ -587,8 +620,7 @@ flows_handler(void)\n \t\t\t *\n \t\t\t */\n \t\t\tflow = generate_flow(port_id, 0, flow_attrs,\n-\t\t\t\tFLOW_ITEM_MASK(RTE_FLOW_ITEM_TYPE_ETH),\n-\t\t\t\tFLOW_ITEM_MASK(RTE_FLOW_ACTION_TYPE_JUMP),\n+\t\t\t\tglobal_items, global_actions,\n \t\t\t\tflow_group, 0, 0, &error);\n \n \t\t\tif (flow == NULL) {\ndiff --git a/doc/guides/rel_notes/release_20_08.rst b/doc/guides/rel_notes/release_20_08.rst\nindex a19ec6db2b..d3ba4cd1d0 100644\n--- a/doc/guides/rel_notes/release_20_08.rst\n+++ b/doc/guides/rel_notes/release_20_08.rst\n@@ -272,6 +272,14 @@ New Features\n   of ingress packets to specific NIC queues.\n   See the :doc:`../sample_app_ug/ipsec_secgw` for more details.\n \n+* **Add more support for flow-perf application.**\n+\n+  * Start supporting user order instead of bit mask:\n+    Now the user can create any structure of rte_flow\n+    using flow performance application with any order,\n+    moreover the app also now starts to support inner\n+    items matching as well.\n+\n \n Removed Items\n -------------\ndiff --git a/doc/guides/tools/flow-perf.rst b/doc/guides/tools/flow-perf.rst\nindex ca551aee6e..6941155fee 100644\n--- a/doc/guides/tools/flow-perf.rst\n+++ b/doc/guides/tools/flow-perf.rst\n@@ -16,20 +16,18 @@ After that the application will start producing rules with same pattern\n but increasing the outer IP source address by 1 each time, thus it will\n give different flow each time, and all other items will have open masks.\n \n+The application also provide the ability to measure rte flow deletion rate,\n+in addition to memory consumption before and after the flows creation.\n+\n+The app supports single and multi core performance measurements.\n+\n \n Known Limitations\n -----------------\n \n The current version has limitations which can be removed in future:\n \n-* Support outer items up to tunnel layer only.\n * Single core insertion only.\n-* Only one instance of same action can be added in one rule.\n-\n-The application also provide the ability to measure rte flow deletion rate,\n-in addition to memory consumption before and after the flows creation.\n-\n-The app supports single and multi core performance measurements.\n \n \n Compiling the Application\n",
    "prefixes": [
        "03/13"
    ]
}