get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 128584,
    "url": "http://patches.dpdk.org/api/patches/128584/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20230613101404.1787790-6-zhirun.yan@intel.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": "<20230613101404.1787790-6-zhirun.yan@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20230613101404.1787790-6-zhirun.yan@intel.com",
    "date": "2023-06-13T10:13:53",
    "name": "[v13,05/16] graph: introduce graph node core affinity API",
    "commit_ref": null,
    "pull_url": null,
    "state": "changes-requested",
    "archived": true,
    "hash": "0737948c7cf94bfea97cefb6c5c5edadc96cf135",
    "submitter": {
        "id": 1154,
        "url": "http://patches.dpdk.org/api/people/1154/?format=api",
        "name": "Yan, Zhirun",
        "email": "zhirun.yan@intel.com"
    },
    "delegate": {
        "id": 1,
        "url": "http://patches.dpdk.org/api/users/1/?format=api",
        "username": "tmonjalo",
        "first_name": "Thomas",
        "last_name": "Monjalon",
        "email": "thomas@monjalon.net"
    },
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/20230613101404.1787790-6-zhirun.yan@intel.com/mbox/",
    "series": [
        {
            "id": 28481,
            "url": "http://patches.dpdk.org/api/series/28481/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=28481",
            "date": "2023-06-13T10:13:48",
            "name": "graph enhancement for multi-core dispatch",
            "version": 13,
            "mbox": "http://patches.dpdk.org/series/28481/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/128584/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/128584/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 884CA42CA8;\n\tTue, 13 Jun 2023 12:24:15 +0200 (CEST)",
            "from mails.dpdk.org (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id 1BF6E42D44;\n\tTue, 13 Jun 2023 12:24:15 +0200 (CEST)",
            "from mga14.intel.com (mga14.intel.com [192.55.52.115])\n by mails.dpdk.org (Postfix) with ESMTP id E8CB442D3C\n for <dev@dpdk.org>; Tue, 13 Jun 2023 12:24:12 +0200 (CEST)",
            "from orsmga008.jf.intel.com ([10.7.209.65])\n by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;\n 13 Jun 2023 03:21:28 -0700",
            "from dpdk-zhirun-lmm.sh.intel.com ([10.67.119.94])\n by orsmga008.jf.intel.com with ESMTP; 13 Jun 2023 03:21:25 -0700"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple;\n d=intel.com; i=@intel.com; q=dns/txt; s=Intel;\n t=1686651853; x=1718187853;\n h=from:to:cc:subject:date:message-id:in-reply-to:\n references:mime-version:content-transfer-encoding;\n bh=ertvvigeaxkq5v6BYVWYs3n7afGZQ/jGZqYWjQbZnag=;\n b=M+NcqG0oMTmPf7ZRbRTXqcXk4q4JvHloeCxmNGlsbCdBB/w8mHz9jgur\n woYbhQJRuE4A84XkRvGkecpTYSFG66x5ihw/WbPcRwACkRTx7IOV5lrfx\n H2fzSPOESCgRIVFW7ZjzpN8julB92VzpfnAF2NmAwN6Ipcg8U+HMkyh0K\n MkSoOzRS4Rmlq4JIhyf1jMu8vTfHS/uPCcB9QFSVjKgxytTLRhSwXFr4R\n 9CKN7HxcWItR+ws+mGBqus8IXaxNPiPkCi9dPaSSnbQNrfrSv/662b2bH\n rBSh23j5rCo85s70KVxJ8+lsjpE+8lf7m13KOhTsSDN5UXIv1846X7j9k g==;",
        "X-IronPort-AV": [
            "E=McAfee;i=\"6600,9927,10739\"; a=\"358289499\"",
            "E=Sophos;i=\"6.00,239,1681196400\"; d=\"scan'208\";a=\"358289499\"",
            "E=McAfee;i=\"6600,9927,10739\"; a=\"741375440\"",
            "E=Sophos;i=\"6.00,239,1681196400\"; d=\"scan'208\";a=\"741375440\""
        ],
        "X-ExtLoop1": "1",
        "From": "Zhirun Yan <zhirun.yan@intel.com>",
        "To": "dev@dpdk.org, jerinj@marvell.com, kirankumark@marvell.com,\n ndabilpuram@marvell.com, stephen@networkplumber.org,\n pbhagavatula@marvell.com, jerinjacobk@gmail.com, david.marchand@redhat.com",
        "Cc": "cunming.liang@intel.com, haiyue.wang@intel.com,\n mattias.ronnblom@ericsson.com, Zhirun Yan <zhirun.yan@intel.com>",
        "Subject": "[PATCH v13 05/16] graph: introduce graph node core affinity API",
        "Date": "Tue, 13 Jun 2023 18:13:53 +0800",
        "Message-Id": "<20230613101404.1787790-6-zhirun.yan@intel.com>",
        "X-Mailer": "git-send-email 2.37.2",
        "In-Reply-To": "<20230613101404.1787790-1-zhirun.yan@intel.com>",
        "References": "<20230609191245.252521-1-zhirun.yan@intel.com>\n <20230613101404.1787790-1-zhirun.yan@intel.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "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": "Add lcore_id for node to hold affinity core id and impl\nrte_graph_model_mcore_dispatch_lcore_affinity_set to set node affinity\nwith specific lcore.\n\nSigned-off-by: Haiyue Wang <haiyue.wang@intel.com>\nSigned-off-by: Cunming Liang <cunming.liang@intel.com>\nSigned-off-by: Zhirun Yan <zhirun.yan@intel.com>\nAcked-by: Jerin Jacob <jerinj@marvell.com>\n---\n lib/graph/graph_private.h                  |  2 +\n lib/graph/meson.build                      |  2 +\n lib/graph/node.c                           |  1 +\n lib/graph/rte_graph_model_mcore_dispatch.c | 30 +++++++++++++++\n lib/graph/rte_graph_model_mcore_dispatch.h | 45 ++++++++++++++++++++++\n lib/graph/version.map                      |  1 +\n 6 files changed, 81 insertions(+)\n create mode 100644 lib/graph/rte_graph_model_mcore_dispatch.c\n create mode 100644 lib/graph/rte_graph_model_mcore_dispatch.h",
    "diff": "diff --git a/lib/graph/graph_private.h b/lib/graph/graph_private.h\nindex eacdef45f0..ea4409448d 100644\n--- a/lib/graph/graph_private.h\n+++ b/lib/graph/graph_private.h\n@@ -51,6 +51,8 @@ struct node {\n \tSTAILQ_ENTRY(node) next;      /**< Next node in the list. */\n \tchar name[RTE_NODE_NAMESIZE]; /**< Name of the node. */\n \tuint64_t flags;\t\t      /**< Node configuration flag. */\n+\tunsigned int lcore_id;\n+\t/**< Node runs on the Lcore ID used for mcore dispatch model. */\n \trte_node_process_t process;   /**< Node process function. */\n \trte_node_init_t init;         /**< Node init function. */\n \trte_node_fini_t fini;\t      /**< Node fini function. */\ndiff --git a/lib/graph/meson.build b/lib/graph/meson.build\nindex 5661dd855b..8aef451f7b 100644\n--- a/lib/graph/meson.build\n+++ b/lib/graph/meson.build\n@@ -16,9 +16,11 @@ sources = files(\n         'graph_populate.c',\n         'graph_pcap.c',\n         'rte_graph_worker.c',\n+        'rte_graph_model_mcore_dispatch.c',\n )\n headers = files('rte_graph.h', 'rte_graph_worker.h')\n indirect_headers += files(\n+        'rte_graph_model_mcore_dispatch.h',\n         'rte_graph_model_rtc.h',\n         'rte_graph_worker_common.h',\n         )\ndiff --git a/lib/graph/node.c b/lib/graph/node.c\nindex 149414dcd9..339b4a0da5 100644\n--- a/lib/graph/node.c\n+++ b/lib/graph/node.c\n@@ -100,6 +100,7 @@ __rte_node_register(const struct rte_node_register *reg)\n \t\t\tgoto free;\n \t}\n \n+\tnode->lcore_id = RTE_MAX_LCORE;\n \tnode->id = node_id++;\n \n \t/* Add the node at tail */\ndiff --git a/lib/graph/rte_graph_model_mcore_dispatch.c b/lib/graph/rte_graph_model_mcore_dispatch.c\nnew file mode 100644\nindex 0000000000..9df2479a10\n--- /dev/null\n+++ b/lib/graph/rte_graph_model_mcore_dispatch.c\n@@ -0,0 +1,30 @@\n+/* SPDX-License-Identifier: BSD-3-Clause\n+ * Copyright(C) 2023 Intel Corporation\n+ */\n+\n+#include \"graph_private.h\"\n+#include \"rte_graph_model_mcore_dispatch.h\"\n+\n+int\n+rte_graph_model_mcore_dispatch_node_lcore_affinity_set(const char *name, unsigned int lcore_id)\n+{\n+\tstruct node *node;\n+\tint ret = -EINVAL;\n+\n+\tif (lcore_id >= RTE_MAX_LCORE)\n+\t\treturn ret;\n+\n+\tgraph_spinlock_lock();\n+\n+\tSTAILQ_FOREACH(node, node_list_head_get(), next) {\n+\t\tif (strncmp(node->name, name, RTE_NODE_NAMESIZE) == 0) {\n+\t\t\tnode->lcore_id = lcore_id;\n+\t\t\tret = 0;\n+\t\t\tbreak;\n+\t\t}\n+\t}\n+\n+\tgraph_spinlock_unlock();\n+\n+\treturn ret;\n+}\ndiff --git a/lib/graph/rte_graph_model_mcore_dispatch.h b/lib/graph/rte_graph_model_mcore_dispatch.h\nnew file mode 100644\nindex 0000000000..7da0483d13\n--- /dev/null\n+++ b/lib/graph/rte_graph_model_mcore_dispatch.h\n@@ -0,0 +1,45 @@\n+/* SPDX-License-Identifier: BSD-3-Clause\n+ * Copyright(C) 2023 Intel Corporation\n+ */\n+\n+#ifndef _RTE_GRAPH_MODEL_MCORE_DISPATCH_H_\n+#define _RTE_GRAPH_MODEL_MCORE_DISPATCH_H_\n+\n+/**\n+ * @file rte_graph_model_mcore_dispatch.h\n+ *\n+ * @warning\n+ * @b EXPERIMENTAL:\n+ * All functions in this file may be changed or removed without prior notice.\n+ *\n+ * These APIs allow to set core affinity with the node and only used for mcore\n+ * dispatch model.\n+ */\n+\n+#ifdef __cplusplus\n+extern \"C\" {\n+#endif\n+\n+#include \"rte_graph_worker_common.h\"\n+\n+/**\n+ * Set lcore affinity with the node used for mcore dispatch model.\n+ *\n+ * @param name\n+ *   Valid node name. In the case of the cloned node, the name will be\n+ * \"parent node name\" + \"-\" + name.\n+ * @param lcore_id\n+ *   The lcore ID value.\n+ *\n+ * @return\n+ *   0 on success, error otherwise.\n+ */\n+__rte_experimental\n+int rte_graph_model_mcore_dispatch_node_lcore_affinity_set(const char *name,\n+\t\t\t\t\t\t\t   unsigned int lcore_id);\n+\n+#ifdef __cplusplus\n+}\n+#endif\n+\n+#endif /* _RTE_GRAPH_MODEL_MCORE_DISPATCH_H_ */\ndiff --git a/lib/graph/version.map b/lib/graph/version.map\nindex e9a680a45e..6ae19b0d6e 100644\n--- a/lib/graph/version.map\n+++ b/lib/graph/version.map\n@@ -15,6 +15,7 @@ EXPERIMENTAL {\n \trte_graph_list_dump;\n \trte_graph_max_count;\n \trte_graph_model_is_valid;\n+\trte_graph_model_mcore_dispatch_node_lcore_affinity_set;\n \trte_graph_node_get;\n \trte_graph_node_get_by_name;\n \trte_graph_obj_dump;\n",
    "prefixes": [
        "v13",
        "05/16"
    ]
}