get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 116469,
    "url": "https://patches.dpdk.org/api/patches/116469/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20220920071141.21769-1-suanmingm@nvidia.com/",
    "project": {
        "id": 1,
        "url": "https://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": "<20220920071141.21769-1-suanmingm@nvidia.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20220920071141.21769-1-suanmingm@nvidia.com",
    "date": "2022-09-20T07:11:41",
    "name": "[v1] ethdev: add indirect action async query",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "e411d9fbdafe88a3946349246beb234a7b791673",
    "submitter": {
        "id": 1887,
        "url": "https://patches.dpdk.org/api/people/1887/?format=api",
        "name": "Suanming Mou",
        "email": "suanmingm@nvidia.com"
    },
    "delegate": {
        "id": 3961,
        "url": "https://patches.dpdk.org/api/users/3961/?format=api",
        "username": "arybchenko",
        "first_name": "Andrew",
        "last_name": "Rybchenko",
        "email": "andrew.rybchenko@oktetlabs.ru"
    },
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20220920071141.21769-1-suanmingm@nvidia.com/mbox/",
    "series": [
        {
            "id": 24723,
            "url": "https://patches.dpdk.org/api/series/24723/?format=api",
            "web_url": "https://patches.dpdk.org/project/dpdk/list/?series=24723",
            "date": "2022-09-20T07:11:41",
            "name": "[v1] ethdev: add indirect action async query",
            "version": 1,
            "mbox": "https://patches.dpdk.org/series/24723/mbox/"
        }
    ],
    "comments": "https://patches.dpdk.org/api/patches/116469/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/116469/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 EB86CA00C3;\n\tTue, 20 Sep 2022 09:12:23 +0200 (CEST)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id D861740E0F;\n\tTue, 20 Sep 2022 09:12:23 +0200 (CEST)",
            "from NAM02-BN1-obe.outbound.protection.outlook.com\n (mail-bn1nam07on2079.outbound.protection.outlook.com [40.107.212.79])\n by mails.dpdk.org (Postfix) with ESMTP id D8ECA40DFB\n for <dev@dpdk.org>; Tue, 20 Sep 2022 09:12:21 +0200 (CEST)",
            "from BN1PR12CA0003.namprd12.prod.outlook.com (2603:10b6:408:e1::8)\n by DM6PR12MB4220.namprd12.prod.outlook.com (2603:10b6:5:21d::7) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5632.18; Tue, 20 Sep\n 2022 07:12:19 +0000",
            "from BN8NAM11FT088.eop-nam11.prod.protection.outlook.com\n (2603:10b6:408:e1:cafe::83) by BN1PR12CA0003.outlook.office365.com\n (2603:10b6:408:e1::8) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5632.21 via Frontend\n Transport; Tue, 20 Sep 2022 07:12:19 +0000",
            "from mail.nvidia.com (216.228.117.161) by\n BN8NAM11FT088.mail.protection.outlook.com (10.13.177.81) with Microsoft SMTP\n Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.20.5632.12 via Frontend Transport; Tue, 20 Sep 2022 07:12:19 +0000",
            "from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com\n (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.26; Tue, 20 Sep\n 2022 00:11:58 -0700",
            "from nvidia.com (10.126.230.35) by rnnvmail201.nvidia.com\n (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.29; Tue, 20 Sep\n 2022 00:11:55 -0700"
        ],
        "ARC-Seal": "i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;\n b=FjyLQm8FJe6nVV16CvxIrln/EQ5SWwGQh5DRa03DKxCBx5IYPBETWzgBkWrClpzx0uW8KTiGqQEVuVe4yvTX2nQMcJXPJPlA+3FeXJ24EsJq1Qe/hE6tCYIbERgeVLnPxuTcKVoXh17gSfIZi0p+395FsdYpJ2dLSw/gTieHqopITj5vzrsde2Ax9jLPzwxiSCVwpbpPX8PYUGB1rRHesFHqJG1VyLYRDW7H5GZpIzWCH13PvxxHNOiprMF/voFvUcUSH8zLn3suz2Z7mqlOyPHcNYTjPLEo4kXDF3DljTYM/sA5/Mp3WClt+AMsdo694p6ZjVQsTABjSGmDFiWhFg==",
        "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=QJAt43RfxoFoEziONwK6MmXyKBFbKD8Jg3tn7dwfq+c=;\n b=nagpdzYV1CdDwfxt0C/tVGEIsUjWJ7T3iCl1y1oFoee0HM/Zaa4A9lgGMCln06qQSFavgayX22rLmX00ktCBKQkOmTP0oZu3Fz9ja7rd9KjE6Nm2yDEBT7PxgAVRxXM+B5AscbCZ0NLlzo+EAIOJnDGeLcG13L8bWsmHKWUTCqBDNXFsl3Oqv+jUF83xQoGn9ADhr0HPGMJLE1YnVrAQgSJ8rSBrHhG9yaRgn+Ghn7SBIBc+th3noaDVE29IPaOkfRWHlQ+qvaMgHhC7dPsa1GJ7RhwOK58j7Zgli1NyyrCRrSD4u+dEeZjcn8fubteo5/fGEXgDYUDs3Kcmf0PZTQ==",
        "ARC-Authentication-Results": "i=1; mx.microsoft.com 1; spf=pass (sender ip is\n 216.228.117.161) smtp.rcpttodomain=intel.com smtp.mailfrom=nvidia.com;\n dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com;\n dkim=none (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=QJAt43RfxoFoEziONwK6MmXyKBFbKD8Jg3tn7dwfq+c=;\n b=WWjlsIvS6QDecDbLE6qj2suvuC/8vM+L1mn2Tm3bIofMaOnoTJq8qg8v8vcIEDuMO/IAyQFNTRBRDm1V4o88IgDpXiUnP95yIEYiqRon/m/2IWqDE6mvW/dLRo0bXFrq7ttsWmeB9Mt2R132rHQrZ3qQifzK/lBaxLsmyVFK5vazQTYAXDq4qds4V8cgrzT8+OEZ/C/hV8LrMsLFIkT43uCsDuqVMB7jMNIOzvI96qH8566XIKT9baygrX1iYtk+sznjDF3KsNoS8nKkPviEWQCvu3uqIghN0sEP/gREnTJMgjRZTTrh2pxNG2C8SIaajI2XfMZhspSkD84X5Kxd2w==",
        "X-MS-Exchange-Authentication-Results": "spf=pass (sender IP is 216.228.117.161)\n smtp.mailfrom=nvidia.com;\n 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 216.228.117.161 as permitted sender) receiver=protection.outlook.com;\n client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C",
        "From": "Suanming Mou <suanmingm@nvidia.com>",
        "To": "Ori Kam <orika@nvidia.com>, Aman Singh <aman.deep.singh@intel.com>,\n \"Yuying Zhang\" <yuying.zhang@intel.com>, Thomas Monjalon\n <thomas@monjalon.net>, \"Ferruh Yigit\" <ferruh.yigit@xilinx.com>, Andrew\n Rybchenko <andrew.rybchenko@oktetlabs.ru>, Ray Kinsella <mdr@ashroe.eu>",
        "CC": "<dev@dpdk.org>",
        "Subject": "[PATCH v1] ethdev: add indirect action async query",
        "Date": "Tue, 20 Sep 2022 10:11:41 +0300",
        "Message-ID": "<20220920071141.21769-1-suanmingm@nvidia.com>",
        "X-Mailer": "git-send-email 2.18.1",
        "In-Reply-To": "<20220809132824.25890-1-suanmingm@nvidia.com>",
        "References": "<20220809132824.25890-1-suanmingm@nvidia.com>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain",
        "X-Originating-IP": "[10.126.230.35]",
        "X-ClientProxiedBy": "rnnvmail203.nvidia.com (10.129.68.9) To\n rnnvmail201.nvidia.com (10.129.68.8)",
        "X-EOPAttributedMessage": "0",
        "X-MS-PublicTrafficType": "Email",
        "X-MS-TrafficTypeDiagnostic": "BN8NAM11FT088:EE_|DM6PR12MB4220:EE_",
        "X-MS-Office365-Filtering-Correlation-Id": "8bed70d4-6add-4a5c-dc2b-08da9ad774d1",
        "X-LD-Processed": "43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr",
        "X-MS-Exchange-SenderADCheck": "1",
        "X-MS-Exchange-AntiSpam-Relay": "0",
        "X-Microsoft-Antispam": "BCL:0;",
        "X-Microsoft-Antispam-Message-Info": "\n 3msrVCr/pVeZqsumGBZQ3x2Wgkj4RC1yR/qT3ZEWvQ4ko88oeEIg6DbJZuZmguGUK+J0ttFovhF1vxaTYjUhoBHggrKmAkXVZuHbNdEP9CiCM+T+ghQKG45kSr+ji4X/IfwlPT6VMOuaOO5cMS/7lawsO992M1WdzcbpRSqeTnrLJJKyibA1SOLq7cMZ7kS1eefK4LQcvUONGejO5hFSqkh1OpLPqkhuspk2OpYzvpEEvL9oQk7fMpjnu99yg95vOxqYvR3OTNxX8ghUKdhFnD23DryQrDWm0cDw1/OGLMQbMm790W/dcvGhpOVD0dfvLL/lRaz838NGrQpG6sXTcCkhieeZpCEMT9VwEnFLdmQvsbHx45PkBngJwXMQb7PEJpBQwi5oXyoQjjF6fRY2z1dTF+mtCL2a5QDClkxImWnZlf/gtBddHCrNglxU7ytl+dScgVCpwQCIW3TPbBot2sj+NCwYMLeRnsMc6mKrh3na+YH+FJHeyhK4Dd+BMkXB2N2zjaI5RBKn9JXGjGRh5ckwhPbVwGD+olTwXFw9niW3utBfsq0XQjLay9yH5iL7VQ5tSjaC585zLGCwRjfD0hcQPkUA6f0P3f2fE9gYDEBK9lLwKdXnJ5zW8xPhIKAaUZ4h7wPoXW6zvDzxB/OeEi8pKN67zJu5k0FiJtjFq1dBb1Jl2TosoI5NGeqNKehQM4Efql2vWC2QYtSdhCwZt8Ip/oIXbUuOVZg0DEY+kCsxBO/kNUHEIZNUXopckVsSQ39N/YFCnpkoWd9hnBG9VQ==",
        "X-Forefront-Antispam-Report": "CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1;\n SRV:;\n IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE;\n SFS:(13230022)(4636009)(346002)(39860400002)(376002)(396003)(136003)(451199015)(40470700004)(36840700001)(46966006)(8936002)(30864003)(82740400003)(82310400005)(83380400001)(86362001)(47076005)(478600001)(70206006)(110136005)(70586007)(1076003)(336012)(356005)(2616005)(55016003)(40480700001)(186003)(7636003)(426003)(4326008)(8676002)(5660300002)(36860700001)(316002)(7696005)(6666004)(6286002)(40460700003)(16526019)(36756003)(26005)(2906002)(41300700001);\n DIR:OUT; SFP:1101;",
        "X-OriginatorOrg": "Nvidia.com",
        "X-MS-Exchange-CrossTenant-OriginalArrivalTime": "20 Sep 2022 07:12:19.2871 (UTC)",
        "X-MS-Exchange-CrossTenant-Network-Message-Id": "\n 8bed70d4-6add-4a5c-dc2b-08da9ad774d1",
        "X-MS-Exchange-CrossTenant-Id": "43083d15-7273-40c1-b7db-39efd9ccc17a",
        "X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp": "\n TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161];\n Helo=[mail.nvidia.com]",
        "X-MS-Exchange-CrossTenant-AuthSource": "\n BN8NAM11FT088.eop-nam11.prod.protection.outlook.com",
        "X-MS-Exchange-CrossTenant-AuthAs": "Anonymous",
        "X-MS-Exchange-CrossTenant-FromEntityHeader": "HybridOnPrem",
        "X-MS-Exchange-Transport-CrossTenantHeadersStamped": "DM6PR12MB4220",
        "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": "As rte_flow_action_handle_create/destroy/update() have their own\nasynchronous rte_flow_async_action_handle_create/destroy/update()\nversion functions to accelerate the indirect action operations in\nqueue based flow engine. Currently, the asynchronous version query\nfunction for indirect action was missing.\n\nThis patch adds the rte_flow_async_action_handle_query() function\ncorresponds to rte_flow_action_handle_query(). The new asynchronous\nversion function enables enqueue the query to the hardware similar\nas asynchronous flow management does and returns immediately to free\nthe CPU for other tasks. Application can get the query results from\nrte_flow_pull() when the hardware completes its work.\n\nSigned-off-by: Suanming Mou <suanmingm@nvidia.com>\nAcked-by: Ori Kam <orika@nvidia.com>\n---\n app/test-pmd/cmdline_flow.c                 |  34 +++\n app/test-pmd/config.c                       | 240 ++++++++++++++------\n app/test-pmd/testpmd.h                      |  28 +++\n doc/guides/prog_guide/rte_flow.rst          |  16 ++\n doc/guides/rel_notes/release_22_11.rst      |   5 +\n doc/guides/testpmd_app_ug/testpmd_funcs.rst |  19 ++\n lib/ethdev/rte_flow.c                       |  18 ++\n lib/ethdev/rte_flow.h                       |  44 ++++\n lib/ethdev/rte_flow_driver.h                |   9 +\n lib/ethdev/version.map                      |   3 +\n 10 files changed, 345 insertions(+), 71 deletions(-)",
    "diff": "diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c\nindex 7f50028eb7..0223286c1a 100644\n--- a/app/test-pmd/cmdline_flow.c\n+++ b/app/test-pmd/cmdline_flow.c\n@@ -145,6 +145,7 @@ enum index {\n \tQUEUE_INDIRECT_ACTION_CREATE,\n \tQUEUE_INDIRECT_ACTION_UPDATE,\n \tQUEUE_INDIRECT_ACTION_DESTROY,\n+\tQUEUE_INDIRECT_ACTION_QUERY,\n \n \t/* Queue indirect action create arguments */\n \tQUEUE_INDIRECT_ACTION_CREATE_ID,\n@@ -161,6 +162,9 @@ enum index {\n \tQUEUE_INDIRECT_ACTION_DESTROY_ID,\n \tQUEUE_INDIRECT_ACTION_DESTROY_POSTPONE,\n \n+\t/* Queue indirect action query arguments */\n+\tQUEUE_INDIRECT_ACTION_QUERY_POSTPONE,\n+\n \t/* Push arguments. */\n \tPUSH_QUEUE,\n \n@@ -1171,6 +1175,7 @@ static const enum index next_qia_subcmd[] = {\n \tQUEUE_INDIRECT_ACTION_CREATE,\n \tQUEUE_INDIRECT_ACTION_UPDATE,\n \tQUEUE_INDIRECT_ACTION_DESTROY,\n+\tQUEUE_INDIRECT_ACTION_QUERY,\n \tZERO,\n };\n \n@@ -1197,6 +1202,12 @@ static const enum index next_qia_destroy_attr[] = {\n \tZERO,\n };\n \n+static const enum index next_qia_query_attr[] = {\n+\tQUEUE_INDIRECT_ACTION_QUERY_POSTPONE,\n+\tEND,\n+\tZERO,\n+};\n+\n static const enum index next_ia_create_attr[] = {\n \tINDIRECT_ACTION_CREATE_ID,\n \tINDIRECT_ACTION_INGRESS,\n@@ -3013,6 +3024,14 @@ static const struct token token_list[] = {\n \t\t.next = NEXT(next_qia_destroy_attr),\n \t\t.call = parse_qia_destroy,\n \t},\n+\t[QUEUE_INDIRECT_ACTION_QUERY] = {\n+\t\t.name = \"query\",\n+\t\t.help = \"query indirect action\",\n+\t\t.next = NEXT(next_qia_query_attr,\n+\t\t\t     NEXT_ENTRY(COMMON_INDIRECT_ACTION_ID)),\n+\t\t.args = ARGS(ARGS_ENTRY(struct buffer, args.vc.attr.group)),\n+\t\t.call = parse_qia,\n+\t},\n \t/* Indirect action destroy arguments. */\n \t[QUEUE_INDIRECT_ACTION_DESTROY_POSTPONE] = {\n \t\t.name = \"postpone\",\n@@ -3038,6 +3057,14 @@ static const struct token token_list[] = {\n \t\t\t     NEXT_ENTRY(COMMON_BOOLEAN)),\n \t\t.args = ARGS(ARGS_ENTRY(struct buffer, postpone)),\n \t},\n+\t/* Indirect action update arguments. */\n+\t[QUEUE_INDIRECT_ACTION_QUERY_POSTPONE] = {\n+\t\t.name = \"postpone\",\n+\t\t.help = \"postpone query operation\",\n+\t\t.next = NEXT(next_qia_query_attr,\n+\t\t\t     NEXT_ENTRY(COMMON_BOOLEAN)),\n+\t\t.args = ARGS(ARGS_ENTRY(struct buffer, postpone)),\n+\t},\n \t/* Indirect action create arguments. */\n \t[QUEUE_INDIRECT_ACTION_CREATE_ID] = {\n \t\t.name = \"action_id\",\n@@ -6682,6 +6709,8 @@ parse_qia(struct context *ctx, const struct token *token,\n \t\t\t(void *)RTE_ALIGN_CEIL((uintptr_t)(out + 1),\n \t\t\t\t\t       sizeof(double));\n \t\tout->args.vc.attr.group = UINT32_MAX;\n+\t\t/* fallthrough */\n+\tcase QUEUE_INDIRECT_ACTION_QUERY:\n \t\tout->command = ctx->curr;\n \t\tctx->objdata = 0;\n \t\tctx->object = out;\n@@ -10509,6 +10538,11 @@ cmd_flow_parsed(const struct buffer *in)\n \t\t\t\t\t\tin->args.vc.attr.group,\n \t\t\t\t\t\tin->args.vc.actions);\n \t\tbreak;\n+\tcase QUEUE_INDIRECT_ACTION_QUERY:\n+\t\tport_queue_action_handle_query(in->port,\n+\t\t\t\t\t       in->queue, in->postpone,\n+\t\t\t\t\t       in->args.vc.attr.group);\n+\t\tbreak;\n \tcase INDIRECT_ACTION_CREATE:\n \t\tport_action_handle_create(\n \t\t\t\tin->port, in->args.vc.attr.group,\ndiff --git a/app/test-pmd/config.c b/app/test-pmd/config.c\nindex a2939867c4..4c51ed03a8 100644\n--- a/app/test-pmd/config.c\n+++ b/app/test-pmd/config.c\n@@ -2080,44 +2080,18 @@ port_action_handle_update(portid_t port_id, uint32_t id,\n \treturn 0;\n }\n \n-int\n-port_action_handle_query(portid_t port_id, uint32_t id)\n+static void\n+port_action_handle_query_dump(uint32_t type, union port_action_query *query)\n {\n-\tstruct rte_flow_error error;\n-\tstruct port_indirect_action *pia;\n-\tunion {\n-\t\tstruct rte_flow_query_count count;\n-\t\tstruct rte_flow_query_age age;\n-\t\tstruct rte_flow_action_conntrack ct;\n-\t} query;\n-\n-\tpia = action_get_by_id(port_id, id);\n-\tif (!pia)\n-\t\treturn -EINVAL;\n-\tswitch (pia->type) {\n-\tcase RTE_FLOW_ACTION_TYPE_AGE:\n-\tcase RTE_FLOW_ACTION_TYPE_COUNT:\n-\t\tbreak;\n-\tdefault:\n-\t\tfprintf(stderr,\n-\t\t\t\"Indirect action %u (type: %d) on port %u doesn't support query\\n\",\n-\t\t\tid, pia->type, port_id);\n-\t\treturn -ENOTSUP;\n-\t}\n-\t/* Poisoning to make sure PMDs update it in case of error. */\n-\tmemset(&error, 0x55, sizeof(error));\n-\tmemset(&query, 0, sizeof(query));\n-\tif (rte_flow_action_handle_query(port_id, pia->handle, &query, &error))\n-\t\treturn port_flow_complain(&error);\n-\tswitch (pia->type) {\n+\tswitch (type) {\n \tcase RTE_FLOW_ACTION_TYPE_AGE:\n \t\tprintf(\"Indirect AGE action:\\n\"\n \t\t       \" aged: %u\\n\"\n \t\t       \" sec_since_last_hit_valid: %u\\n\"\n \t\t       \" sec_since_last_hit: %\" PRIu32 \"\\n\",\n-\t\t       query.age.aged,\n-\t\t       query.age.sec_since_last_hit_valid,\n-\t\t       query.age.sec_since_last_hit);\n+\t\t       query->age.aged,\n+\t\t       query->age.sec_since_last_hit_valid,\n+\t\t       query->age.sec_since_last_hit);\n \t\tbreak;\n \tcase RTE_FLOW_ACTION_TYPE_COUNT:\n \t\tprintf(\"Indirect COUNT action:\\n\"\n@@ -2125,10 +2099,10 @@ port_action_handle_query(portid_t port_id, uint32_t id)\n \t\t       \" bytes_set: %u\\n\"\n \t\t       \" hits: %\" PRIu64 \"\\n\"\n \t\t       \" bytes: %\" PRIu64 \"\\n\",\n-\t\t       query.count.hits_set,\n-\t\t       query.count.bytes_set,\n-\t\t       query.count.hits,\n-\t\t       query.count.bytes);\n+\t\t       query->count.hits_set,\n+\t\t       query->count.bytes_set,\n+\t\t       query->count.hits,\n+\t\t       query->count.bytes);\n \t\tbreak;\n \tcase RTE_FLOW_ACTION_TYPE_CONNTRACK:\n \t\tprintf(\"Conntrack Context:\\n\"\n@@ -2138,47 +2112,76 @@ port_action_handle_query(portid_t port_id, uint32_t id)\n \t\t       \"  Factor: %u, Retrans: %u, TCP flags: %u\\n\"\n \t\t       \"  Last Seq: %u, Last ACK: %u\\n\"\n \t\t       \"  Last Win: %u, Last End: %u\\n\",\n-\t\t       query.ct.peer_port,\n-\t\t       query.ct.is_original_dir ? \"Original\" : \"Reply\",\n-\t\t       query.ct.enable, query.ct.live_connection,\n-\t\t       query.ct.selective_ack, query.ct.challenge_ack_passed,\n-\t\t       query.ct.last_direction ? \"Original\" : \"Reply\",\n-\t\t       query.ct.liberal_mode, query.ct.state,\n-\t\t       query.ct.max_ack_window, query.ct.retransmission_limit,\n-\t\t       query.ct.last_index, query.ct.last_seq,\n-\t\t       query.ct.last_ack, query.ct.last_window,\n-\t\t       query.ct.last_end);\n+\t\t       query->ct.peer_port,\n+\t\t       query->ct.is_original_dir ? \"Original\" : \"Reply\",\n+\t\t       query->ct.enable, query->ct.live_connection,\n+\t\t       query->ct.selective_ack, query->ct.challenge_ack_passed,\n+\t\t       query->ct.last_direction ? \"Original\" : \"Reply\",\n+\t\t       query->ct.liberal_mode, query->ct.state,\n+\t\t       query->ct.max_ack_window, query->ct.retransmission_limit,\n+\t\t       query->ct.last_index, query->ct.last_seq,\n+\t\t       query->ct.last_ack, query->ct.last_window,\n+\t\t       query->ct.last_end);\n \t\tprintf(\"  Original Dir:\\n\"\n \t\t       \"    scale: %u, fin: %u, ack seen: %u\\n\"\n \t\t       \" unacked data: %u\\n    Sent end: %u,\"\n \t\t       \"    Reply end: %u, Max win: %u, Max ACK: %u\\n\",\n-\t\t       query.ct.original_dir.scale,\n-\t\t       query.ct.original_dir.close_initiated,\n-\t\t       query.ct.original_dir.last_ack_seen,\n-\t\t       query.ct.original_dir.data_unacked,\n-\t\t       query.ct.original_dir.sent_end,\n-\t\t       query.ct.original_dir.reply_end,\n-\t\t       query.ct.original_dir.max_win,\n-\t\t       query.ct.original_dir.max_ack);\n+\t\t       query->ct.original_dir.scale,\n+\t\t       query->ct.original_dir.close_initiated,\n+\t\t       query->ct.original_dir.last_ack_seen,\n+\t\t       query->ct.original_dir.data_unacked,\n+\t\t       query->ct.original_dir.sent_end,\n+\t\t       query->ct.original_dir.reply_end,\n+\t\t       query->ct.original_dir.max_win,\n+\t\t       query->ct.original_dir.max_ack);\n \t\tprintf(\"  Reply Dir:\\n\"\n \t\t       \"    scale: %u, fin: %u, ack seen: %u\\n\"\n \t\t       \" unacked data: %u\\n    Sent end: %u,\"\n \t\t       \"    Reply end: %u, Max win: %u, Max ACK: %u\\n\",\n-\t\t       query.ct.reply_dir.scale,\n-\t\t       query.ct.reply_dir.close_initiated,\n-\t\t       query.ct.reply_dir.last_ack_seen,\n-\t\t       query.ct.reply_dir.data_unacked,\n-\t\t       query.ct.reply_dir.sent_end,\n-\t\t       query.ct.reply_dir.reply_end,\n-\t\t       query.ct.reply_dir.max_win,\n-\t\t       query.ct.reply_dir.max_ack);\n+\t\t       query->ct.reply_dir.scale,\n+\t\t       query->ct.reply_dir.close_initiated,\n+\t\t       query->ct.reply_dir.last_ack_seen,\n+\t\t       query->ct.reply_dir.data_unacked,\n+\t\t       query->ct.reply_dir.sent_end,\n+\t\t       query->ct.reply_dir.reply_end,\n+\t\t       query->ct.reply_dir.max_win,\n+\t\t       query->ct.reply_dir.max_ack);\n+\t\tbreak;\n+\tdefault:\n+\t\tfprintf(stderr,\n+\t\t\t\"Indirect action (type: %d) doesn't support query\\n\",\n+\t\t\ttype);\n+\t\tbreak;\n+\t}\n+\n+}\n+\n+int\n+port_action_handle_query(portid_t port_id, uint32_t id)\n+{\n+\tstruct rte_flow_error error;\n+\tstruct port_indirect_action *pia;\n+\tunion port_action_query query;\n+\n+\tpia = action_get_by_id(port_id, id);\n+\tif (!pia)\n+\t\treturn -EINVAL;\n+\tswitch (pia->type) {\n+\tcase RTE_FLOW_ACTION_TYPE_AGE:\n+\tcase RTE_FLOW_ACTION_TYPE_COUNT:\n \t\tbreak;\n \tdefault:\n \t\tfprintf(stderr,\n \t\t\t\"Indirect action %u (type: %d) on port %u doesn't support query\\n\",\n \t\t\tid, pia->type, port_id);\n-\t\tbreak;\n+\t\treturn -ENOTSUP;\n \t}\n+\t/* Poisoning to make sure PMDs update it in case of error. */\n+\tmemset(&error, 0x55, sizeof(error));\n+\tmemset(&query, 0, sizeof(query));\n+\tif (rte_flow_action_handle_query(port_id, pia->handle, &query, &error))\n+\t\treturn port_flow_complain(&error);\n+\tport_action_handle_query_dump(pia->type, &query);\n \treturn 0;\n }\n \n@@ -2670,6 +2673,7 @@ port_queue_flow_create(portid_t port_id, queueid_t queue_id,\n \tbool found;\n \tstruct rte_flow_error error = { RTE_FLOW_ERROR_TYPE_NONE, NULL, NULL };\n \tstruct rte_flow_action_age *age = age_action_get(actions);\n+\tstruct queue_job *job;\n \n \tport = &ports[port_id];\n \tif (port->flow_list) {\n@@ -2713,9 +2717,18 @@ port_queue_flow_create(portid_t port_id, queueid_t queue_id,\n \t\treturn -EINVAL;\n \t}\n \n+\tjob = calloc(1, sizeof(*job));\n+\tif (!job) {\n+\t\tprintf(\"Queue flow create job allocate failed\\n\");\n+\t\treturn -ENOMEM;\n+\t}\n+\tjob->type = QUEUE_JOB_TYPE_FLOW_CREATE;\n+\n \tpf = port_flow_new(NULL, pattern, actions, &error);\n-\tif (!pf)\n+\tif (!pf) {\n+\t\tfree(job);\n \t\treturn port_flow_complain(&error);\n+\t}\n \tif (age) {\n \t\tpf->age_type = ACTION_AGE_CONTEXT_TYPE_FLOW;\n \t\tage->context = &pf->age_type;\n@@ -2723,16 +2736,18 @@ port_queue_flow_create(portid_t port_id, queueid_t queue_id,\n \t/* Poisoning to make sure PMDs update it in case of error. */\n \tmemset(&error, 0x11, sizeof(error));\n \tflow = rte_flow_async_create(port_id, queue_id, &op_attr, pt->table,\n-\t\tpattern, pattern_idx, actions, actions_idx, NULL, &error);\n+\t\tpattern, pattern_idx, actions, actions_idx, job, &error);\n \tif (!flow) {\n \t\tuint32_t flow_id = pf->id;\n \t\tport_queue_flow_destroy(port_id, queue_id, true, 1, &flow_id);\n+\t\tfree(job);\n \t\treturn port_flow_complain(&error);\n \t}\n \n \tpf->next = port->flow_list;\n \tpf->id = id;\n \tpf->flow = flow;\n+\tjob->pf = pf;\n \tport->flow_list = pf;\n \tprintf(\"Flow rule #%u creation enqueued\\n\", pf->id);\n \treturn 0;\n@@ -2748,6 +2763,7 @@ port_queue_flow_destroy(portid_t port_id, queueid_t queue_id,\n \tstruct port_flow **tmp;\n \tuint32_t c = 0;\n \tint ret = 0;\n+\tstruct queue_job *job;\n \n \tif (port_id_is_invalid(port_id, ENABLED_WARN) ||\n \t    port_id == (portid_t)RTE_PORT_ALL)\n@@ -2774,14 +2790,22 @@ port_queue_flow_destroy(portid_t port_id, queueid_t queue_id,\n \t\t\t * update it in case of error.\n \t\t\t */\n \t\t\tmemset(&error, 0x33, sizeof(error));\n+\t\t\tjob = calloc(1, sizeof(*job));\n+\t\t\tif (!job) {\n+\t\t\t\tprintf(\"Queue flow destroy job allocate failed\\n\");\n+\t\t\t\treturn -ENOMEM;\n+\t\t\t}\n+\t\t\tjob->type = QUEUE_JOB_TYPE_FLOW_DESTROY;\n+\t\t\tjob->pf = pf;\n+\n \t\t\tif (rte_flow_async_destroy(port_id, queue_id, &op_attr,\n-\t\t\t\t\t\t   pf->flow, NULL, &error)) {\n+\t\t\t\t\t\t   pf->flow, job, &error)) {\n+\t\t\t\tfree(job);\n \t\t\t\tret = port_flow_complain(&error);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\tprintf(\"Flow rule #%u destruction enqueued\\n\", pf->id);\n \t\t\t*tmp = pf->next;\n-\t\t\tfree(pf);\n \t\t\tbreak;\n \t\t}\n \t\tif (i == n)\n@@ -2803,6 +2827,7 @@ port_queue_action_handle_create(portid_t port_id, uint32_t queue_id,\n \tstruct port_indirect_action *pia;\n \tint ret;\n \tstruct rte_flow_error error;\n+\tstruct queue_job *job;\n \n \tret = action_alloc(port_id, id, &pia);\n \tif (ret)\n@@ -2813,6 +2838,13 @@ port_queue_action_handle_create(portid_t port_id, uint32_t queue_id,\n \t\tprintf(\"Queue #%u is invalid\\n\", queue_id);\n \t\treturn -EINVAL;\n \t}\n+\tjob = calloc(1, sizeof(*job));\n+\tif (!job) {\n+\t\tprintf(\"Queue action create job allocate failed\\n\");\n+\t\treturn -ENOMEM;\n+\t}\n+\tjob->type = QUEUE_JOB_TYPE_ACTION_CREATE;\n+\tjob->pia = pia;\n \n \tif (action->type == RTE_FLOW_ACTION_TYPE_AGE) {\n \t\tstruct rte_flow_action_age *age =\n@@ -2824,11 +2856,12 @@ port_queue_action_handle_create(portid_t port_id, uint32_t queue_id,\n \t/* Poisoning to make sure PMDs update it in case of error. */\n \tmemset(&error, 0x88, sizeof(error));\n \tpia->handle = rte_flow_async_action_handle_create(port_id, queue_id,\n-\t\t\t\t\t&attr, conf, action, NULL, &error);\n+\t\t\t\t\t&attr, conf, action, job, &error);\n \tif (!pia->handle) {\n \t\tuint32_t destroy_id = pia->id;\n \t\tport_queue_action_handle_destroy(port_id, queue_id,\n \t\t\t\t\t\t postpone, 1, &destroy_id);\n+\t\tfree(job);\n \t\treturn port_flow_complain(&error);\n \t}\n \tpia->type = action->type;\n@@ -2847,6 +2880,7 @@ port_queue_action_handle_destroy(portid_t port_id,\n \tstruct port_indirect_action **tmp;\n \tuint32_t c = 0;\n \tint ret = 0;\n+\tstruct queue_job *job;\n \n \tif (port_id_is_invalid(port_id, ENABLED_WARN) ||\n \t    port_id == (portid_t)RTE_PORT_ALL)\n@@ -2873,17 +2907,23 @@ port_queue_action_handle_destroy(portid_t port_id,\n \t\t\t * of error.\n \t\t\t */\n \t\t\tmemset(&error, 0x99, sizeof(error));\n+\t\t\tjob = calloc(1, sizeof(*job));\n+\t\t\tif (!job) {\n+\t\t\t\tprintf(\"Queue action destroy job allocate failed\\n\");\n+\t\t\t\treturn -ENOMEM;\n+\t\t\t}\n+\t\t\tjob->type = QUEUE_JOB_TYPE_ACTION_DESTROY;\n+\t\t\tjob->pia = pia;\n \n \t\t\tif (pia->handle &&\n \t\t\t    rte_flow_async_action_handle_destroy(port_id,\n-\t\t\t\tqueue_id, &attr, pia->handle, NULL, &error)) {\n+\t\t\t\tqueue_id, &attr, pia->handle, job, &error)) {\n \t\t\t\tret = port_flow_complain(&error);\n \t\t\t\tcontinue;\n \t\t\t}\n \t\t\t*tmp = pia->next;\n \t\t\tprintf(\"Indirect action #%u destruction queued\\n\",\n \t\t\t       pia->id);\n-\t\t\tfree(pia);\n \t\t\tbreak;\n \t\t}\n \t\tif (i == n)\n@@ -2903,6 +2943,7 @@ port_queue_action_handle_update(portid_t port_id,\n \tstruct rte_port *port;\n \tstruct rte_flow_error error;\n \tstruct rte_flow_action_handle *action_handle;\n+\tstruct queue_job *job;\n \n \taction_handle = port_action_handle_get_by_id(port_id, id);\n \tif (!action_handle)\n@@ -2914,8 +2955,56 @@ port_queue_action_handle_update(portid_t port_id,\n \t\treturn -EINVAL;\n \t}\n \n+\tjob = calloc(1, sizeof(*job));\n+\tif (!job) {\n+\t\tprintf(\"Queue action update job allocate failed\\n\");\n+\t\treturn -ENOMEM;\n+\t}\n+\tjob->type = QUEUE_JOB_TYPE_ACTION_UPDATE;\n+\n \tif (rte_flow_async_action_handle_update(port_id, queue_id, &attr,\n-\t\t\t\t    action_handle, action, NULL, &error)) {\n+\t\t\t\t    action_handle, action, job, &error)) {\n+\t\tfree(job);\n+\t\treturn port_flow_complain(&error);\n+\t}\n+\tprintf(\"Indirect action #%u update queued\\n\", id);\n+\treturn 0;\n+}\n+\n+/** Enqueue indirect action query operation. */\n+int\n+port_queue_action_handle_query(portid_t port_id,\n+\t\t\t       uint32_t queue_id, bool postpone, uint32_t id)\n+{\n+\tconst struct rte_flow_op_attr attr = { .postpone = postpone};\n+\tstruct rte_port *port;\n+\tstruct rte_flow_error error;\n+\tstruct rte_flow_action_handle *action_handle;\n+\tstruct port_indirect_action *pia;\n+\tstruct queue_job *job;\n+\n+\tpia = action_get_by_id(port_id, id);\n+\taction_handle = pia ? pia->handle : NULL;\n+\tif (!action_handle)\n+\t\treturn -EINVAL;\n+\n+\tport = &ports[port_id];\n+\tif (queue_id >= port->queue_nb) {\n+\t\tprintf(\"Queue #%u is invalid\\n\", queue_id);\n+\t\treturn -EINVAL;\n+\t}\n+\n+\tjob = calloc(1, sizeof(*job));\n+\tif (!job) {\n+\t\tprintf(\"Queue action update job allocate failed\\n\");\n+\t\treturn -ENOMEM;\n+\t}\n+\tjob->type = QUEUE_JOB_TYPE_ACTION_QUERY;\n+\tjob->pia = pia;\n+\n+\tif (rte_flow_async_action_handle_query(port_id, queue_id, &attr,\n+\t\t\t\t    action_handle, &job->query, job, &error)) {\n+\t\tfree(job);\n \t\treturn port_flow_complain(&error);\n \t}\n \tprintf(\"Indirect action #%u update queued\\n\", id);\n@@ -2960,6 +3049,7 @@ port_queue_flow_pull(portid_t port_id, queueid_t queue_id)\n \tint ret = 0;\n \tint success = 0;\n \tint i;\n+\tstruct queue_job *job;\n \n \tif (port_id_is_invalid(port_id, ENABLED_WARN) ||\n \t    port_id == (portid_t)RTE_PORT_ALL)\n@@ -2989,6 +3079,14 @@ port_queue_flow_pull(portid_t port_id, queueid_t queue_id)\n \tfor (i = 0; i < ret; i++) {\n \t\tif (res[i].status == RTE_FLOW_OP_SUCCESS)\n \t\t\tsuccess++;\n+\t\tjob = (struct queue_job *)res[i].user_data;\n+\t\tif (job->type == QUEUE_JOB_TYPE_FLOW_DESTROY)\n+\t\t\tfree(job->pf);\n+\t\telse if (job->type == QUEUE_JOB_TYPE_ACTION_DESTROY)\n+\t\t\tfree(job->pia);\n+\t\telse if (job->type == QUEUE_JOB_TYPE_ACTION_QUERY)\n+\t\t\tport_action_handle_query_dump(job->pia->type, &job->query);\n+\t\tfree(job);\n \t}\n \tprintf(\"Queue #%u pulled %u operations (%u failed, %u succeeded)\\n\",\n \t       queue_id, ret, ret - success, success);\ndiff --git a/app/test-pmd/testpmd.h b/app/test-pmd/testpmd.h\nindex fb2f5195d3..c7a96d062c 100644\n--- a/app/test-pmd/testpmd.h\n+++ b/app/test-pmd/testpmd.h\n@@ -105,6 +105,15 @@ enum {\n \t/**< allocate mempool natively, use rte_pktmbuf_pool_create_extbuf */\n };\n \n+enum {\n+\tQUEUE_JOB_TYPE_FLOW_CREATE,\n+\tQUEUE_JOB_TYPE_FLOW_DESTROY,\n+\tQUEUE_JOB_TYPE_ACTION_CREATE,\n+\tQUEUE_JOB_TYPE_ACTION_DESTROY,\n+\tQUEUE_JOB_TYPE_ACTION_UPDATE,\n+\tQUEUE_JOB_TYPE_ACTION_QUERY,\n+};\n+\n /**\n  * The data structure associated with RX and TX packet burst statistics\n  * that are recorded for each forwarding stream.\n@@ -220,6 +229,23 @@ struct port_indirect_action {\n \tenum age_action_context_type age_type; /**< Age action context type. */\n };\n \n+/* Descriptor for action query data. */\n+union port_action_query {\n+\tstruct rte_flow_query_count count;\n+\tstruct rte_flow_query_age age;\n+\tstruct rte_flow_action_conntrack ct;\n+};\n+\n+/* Descriptor for queue job. */\n+struct queue_job {\n+\tuint32_t type; /**< Job type. */\n+\tunion {\n+\t\tstruct port_flow *pf;\n+\t\tstruct port_indirect_action *pia;\n+\t};\n+\tunion port_action_query query;\n+};\n+\n struct port_flow_tunnel {\n \tLIST_ENTRY(port_flow_tunnel) chain;\n \tstruct rte_flow_action *pmd_actions;\n@@ -980,6 +1006,8 @@ int port_queue_action_handle_destroy(portid_t port_id,\n int port_queue_action_handle_update(portid_t port_id, uint32_t queue_id,\n \t\t\t\t    bool postpone, uint32_t id,\n \t\t\t\t    const struct rte_flow_action *action);\n+int port_queue_action_handle_query(portid_t port_id, uint32_t queue_id,\n+\t\t\t\t   bool postpone, uint32_t id);\n int port_queue_flow_push(portid_t port_id, queueid_t queue_id);\n int port_queue_flow_pull(portid_t port_id, queueid_t queue_id);\n int port_flow_validate(portid_t port_id,\ndiff --git a/doc/guides/prog_guide/rte_flow.rst b/doc/guides/prog_guide/rte_flow.rst\nindex 588914b231..9e6aadf954 100644\n--- a/doc/guides/prog_guide/rte_flow.rst\n+++ b/doc/guides/prog_guide/rte_flow.rst\n@@ -3911,6 +3911,22 @@ Asynchronous version of indirect action update API.\n            void *user_data,\n            struct rte_flow_error *error);\n \n+Enqueue indirect action query operation\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+Asynchronous version of indirect action query API.\n+\n+.. code-block:: c\n+\n+   int\n+   rte_flow_async_action_handle_query(uint16_t port_id,\n+           uint32_t queue_id,\n+           const struct rte_flow_op_attr *q_ops_attr,\n+           struct rte_flow_action_handle *action_handle,\n+           void *data,\n+           void *user_data,\n+           struct rte_flow_error *error);\n+\n Push enqueued operations\n ~~~~~~~~~~~~~~~~~~~~~~~~\n \ndiff --git a/doc/guides/rel_notes/release_22_11.rst b/doc/guides/rel_notes/release_22_11.rst\nindex 8c021cf050..597b28ede1 100644\n--- a/doc/guides/rel_notes/release_22_11.rst\n+++ b/doc/guides/rel_notes/release_22_11.rst\n@@ -55,6 +55,11 @@ New Features\n      Also, make sure to start the actual text at the margin.\n      =======================================================\n \n+* **Added support for queue based async query in rte_flow.**\n+\n+  Added new API ``rte_flow_async_action_handle_query()``, to query the\n+  action asynchronously.\n+\n \n Removed Items\n -------------\ndiff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst\nindex 330e34427d..d2c6e385db 100644\n--- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst\n+++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst\n@@ -4676,6 +4676,25 @@ Query indirect action having id 100::\n \n    testpmd> flow indirect_action 0 query 100\n \n+Enqueueing query of indirect actions\n+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\n+\n+``flow queue indirect_action query`` adds query operation for an indirect\n+action to a queue. It is bound to ``rte_flow_async_action_handle_query()``::\n+\n+   flow queue {port_id} indirect_action {queue_id} query\n+      {indirect_action_id} [postpone {boolean}]\n+\n+If successful, it will show::\n+\n+   Indirect action #[...] query queued\n+\n+Otherwise it will show an error message of the form::\n+\n+   Caught error type [...] ([...]): [...]\n+\n+``flow queue pull`` must be called to retrieve the operation status.\n+\n Sample QinQ flow rules\n ~~~~~~~~~~~~~~~~~~~~~~\n \ndiff --git a/lib/ethdev/rte_flow.c b/lib/ethdev/rte_flow.c\nindex 501be9d602..eb6a6b737e 100644\n--- a/lib/ethdev/rte_flow.c\n+++ b/lib/ethdev/rte_flow.c\n@@ -1844,3 +1844,21 @@ rte_flow_async_action_handle_update(uint16_t port_id,\n \t\t\t\t\t  action_handle, update, user_data, error);\n \treturn flow_err(port_id, ret, error);\n }\n+\n+int\n+rte_flow_async_action_handle_query(uint16_t port_id,\n+\t\tuint32_t queue_id,\n+\t\tconst struct rte_flow_op_attr *op_attr,\n+\t\tconst struct rte_flow_action_handle *action_handle,\n+\t\tvoid *data,\n+\t\tvoid *user_data,\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+\tint ret;\n+\n+\tret = ops->async_action_handle_query(dev, queue_id, op_attr,\n+\t\t\t\t\t  action_handle, data, user_data, error);\n+\treturn flow_err(port_id, ret, error);\n+}\ndiff --git a/lib/ethdev/rte_flow.h b/lib/ethdev/rte_flow.h\nindex a79f1e7ef0..7554c46e72 100644\n--- a/lib/ethdev/rte_flow.h\n+++ b/lib/ethdev/rte_flow.h\n@@ -5612,6 +5612,50 @@ rte_flow_async_action_handle_update(uint16_t port_id,\n \t\tconst void *update,\n \t\tvoid *user_data,\n \t\tstruct rte_flow_error *error);\n+\n+/**\n+ * @warning\n+ * @b EXPERIMENTAL: this API may change without prior notice.\n+ *\n+ * Enqueue indirect action query operation.\n+ *\n+ * Retrieve action-specific data such as counters.\n+ * Data is gathered by special action which may be present/referenced in\n+ * more than one flow rule definition.\n+ * Data will be available only when completion event returns.\n+ *\n+ * @see rte_flow_async_action_handle_query\n+ *\n+ * @param port_id\n+ *   Port identifier of Ethernet device.\n+ * @param[in] queue_id\n+ *   Flow queue which is used to query the action.\n+ * @param[in] op_attr\n+ *   Indirect action update operation attributes.\n+ * @param[in] action_handle\n+ *   Handle for the action object to query.\n+ * @param[in, out] data\n+ *   Pointer to storage for the associated query data type.\n+ *   The out data will be available only when completion event returns\n+ *   from rte_flow_pull.\n+ * @param[in] user_data\n+ *   The user data that will be returned on the completion events.\n+ * @param[out] error\n+ *   Perform verbose error reporting if not NULL. PMDs initialize this\n+ *   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_async_action_handle_query(uint16_t port_id,\n+\t\tuint32_t queue_id,\n+\t\tconst struct rte_flow_op_attr *op_attr,\n+\t\tconst struct rte_flow_action_handle *action_handle,\n+\t\tvoid *data,\n+\t\tvoid *user_data,\n+\t\tstruct rte_flow_error *error);\n #ifdef __cplusplus\n }\n #endif\ndiff --git a/lib/ethdev/rte_flow_driver.h b/lib/ethdev/rte_flow_driver.h\nindex 2bff732d6a..7289deb538 100644\n--- a/lib/ethdev/rte_flow_driver.h\n+++ b/lib/ethdev/rte_flow_driver.h\n@@ -260,6 +260,15 @@ struct rte_flow_ops {\n \t\t const void *update,\n \t\t void *user_data,\n \t\t struct rte_flow_error *error);\n+\t/** See rte_flow_async_action_handle_query() */\n+\tint (*async_action_handle_query)\n+\t\t(struct rte_eth_dev *dev,\n+\t\t uint32_t queue_id,\n+\t\t const struct rte_flow_op_attr *op_attr,\n+\t\t const struct rte_flow_action_handle *action_handle,\n+\t\t void *data,\n+\t\t void *user_data,\n+\t\t struct rte_flow_error *error);\n };\n \n /**\ndiff --git a/lib/ethdev/version.map b/lib/ethdev/version.map\nindex 03f52fee91..722081a8c7 100644\n--- a/lib/ethdev/version.map\n+++ b/lib/ethdev/version.map\n@@ -285,6 +285,9 @@ EXPERIMENTAL {\n \trte_mtr_color_in_protocol_priority_get;\n \trte_mtr_color_in_protocol_set;\n \trte_mtr_meter_vlan_table_update;\n+\n+\t# added in 22.11\n+\trte_flow_async_action_handle_query;\n };\n \n INTERNAL {\n",
    "prefixes": [
        "v1"
    ]
}