get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 26122,
    "url": "https://patches.dpdk.org/api/patches/26122/?format=api",
    "web_url": "https://patches.dpdk.org/project/dpdk/patch/20170630165140.59594-11-ferruh.yigit@intel.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": "<20170630165140.59594-11-ferruh.yigit@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20170630165140.59594-11-ferruh.yigit@intel.com",
    "date": "2017-06-30T16:51:30",
    "name": "[dpdk-dev,v9,10/20] unci: init netlink",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "01b6cc0a6f13e54cd2ac2ecdc454dc1bd037a83b",
    "submitter": {
        "id": 324,
        "url": "https://patches.dpdk.org/api/people/324/?format=api",
        "name": "Ferruh Yigit",
        "email": "ferruh.yigit@intel.com"
    },
    "delegate": null,
    "mbox": "https://patches.dpdk.org/project/dpdk/patch/20170630165140.59594-11-ferruh.yigit@intel.com/mbox/",
    "series": [],
    "comments": "https://patches.dpdk.org/api/patches/26122/comments/",
    "check": "success",
    "checks": "https://patches.dpdk.org/api/patches/26122/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<dev-bounces@dpdk.org>",
        "X-Original-To": "patchwork@dpdk.org",
        "Delivered-To": "patchwork@dpdk.org",
        "Received": [
            "from [92.243.14.124] (localhost [IPv6:::1])\n\tby dpdk.org (Postfix) with ESMTP id A5C817CC3;\n\tFri, 30 Jun 2017 18:52:30 +0200 (CEST)",
            "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n\tby dpdk.org (Postfix) with ESMTP id 7022958CE\n\tfor <dev@dpdk.org>; Fri, 30 Jun 2017 18:52:04 +0200 (CEST)",
            "from orsmga004.jf.intel.com ([10.7.209.38])\n\tby orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t30 Jun 2017 09:51:59 -0700",
            "from silpixa00372839.ir.intel.com (HELO\n\tsilpixa00372839.ger.corp.intel.com) ([10.237.222.154])\n\tby orsmga004.jf.intel.com with ESMTP; 30 Jun 2017 09:51:57 -0700"
        ],
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.40,287,1496127600\"; d=\"scan'208\";a=\"103233223\"",
        "From": "Ferruh Yigit <ferruh.yigit@intel.com>",
        "To": "dev@dpdk.org",
        "Cc": "Ferruh Yigit <ferruh.yigit@intel.com>,\n\tStephen Hemminger <stephen@networkplumber.org>,\n\tBruce Richardson <bruce.richardson@intel.com>,\n\tAnatoly Burakov <anatoly.burakov@intel.com>",
        "Date": "Fri, 30 Jun 2017 17:51:30 +0100",
        "Message-Id": "<20170630165140.59594-11-ferruh.yigit@intel.com>",
        "X-Mailer": "git-send-email 2.13.0",
        "In-Reply-To": "<20170630165140.59594-1-ferruh.yigit@intel.com>",
        "References": "<20170621110651.75299-1-ferruh.yigit@intel.com>\n\t<20170630165140.59594-1-ferruh.yigit@intel.com>",
        "Subject": "[dpdk-dev] [PATCH v9 10/20] unci: init netlink",
        "X-BeenThere": "dev@dpdk.org",
        "X-Mailman-Version": "2.1.15",
        "Precedence": "list",
        "List-Id": "DPDK patches and discussions <dev.dpdk.org>",
        "List-Unsubscribe": "<http://dpdk.org/ml/options/dev>,\n\t<mailto:dev-request@dpdk.org?subject=unsubscribe>",
        "List-Archive": "<http://dpdk.org/ml/archives/dev/>",
        "List-Post": "<mailto:dev@dpdk.org>",
        "List-Help": "<mailto:dev-request@dpdk.org?subject=help>",
        "List-Subscribe": "<http://dpdk.org/ml/listinfo/dev>,\n\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Initialize netlink socket.\n\nUserspace application will connect to the socket for data transfer.\n\nSigned-off-by: Ferruh Yigit <ferruh.yigit@intel.com>\n---\n .../eal/include/exec-env/rte_unci_common.h         | 14 ++++++\n lib/librte_eal/linuxapp/unci/Makefile              |  1 +\n lib/librte_eal/linuxapp/unci/unci_dev.h            |  3 ++\n lib/librte_eal/linuxapp/unci/unci_net.c            |  2 +\n lib/librte_eal/linuxapp/unci/unci_nl.c             | 55 ++++++++++++++++++++++\n 5 files changed, 75 insertions(+)\n create mode 100644 lib/librte_eal/linuxapp/unci/unci_nl.c",
    "diff": "diff --git a/lib/librte_eal/linuxapp/eal/include/exec-env/rte_unci_common.h b/lib/librte_eal/linuxapp/eal/include/exec-env/rte_unci_common.h\nindex d90423a07..a14c463a0 100644\n--- a/lib/librte_eal/linuxapp/eal/include/exec-env/rte_unci_common.h\n+++ b/lib/librte_eal/linuxapp/eal/include/exec-env/rte_unci_common.h\n@@ -60,6 +60,20 @@\n \n #define UNCI_DEVICE \"unci\"\n \n+#define UNCI_NL_GRP 31\n+\n+#define UNCI_NL_MSG_LEN 500\n+struct unci_nl_msg {\n+\tuint32_t cmd_id;\n+\tuint8_t port_id;\n+\tuint32_t flag;\n+\tuint8_t input_buffer[UNCI_NL_MSG_LEN];\n+\tuint8_t output_buffer[UNCI_NL_MSG_LEN];\n+\tsize_t input_buffer_len;\n+\tsize_t output_buffer_len;\n+\tint err;\n+};\n+\n enum {\n \tIFLA_UNCI_UNSPEC,\n \tIFLA_UNCI_PORTID,\ndiff --git a/lib/librte_eal/linuxapp/unci/Makefile b/lib/librte_eal/linuxapp/unci/Makefile\nindex 02e354814..c2a81be7d 100644\n--- a/lib/librte_eal/linuxapp/unci/Makefile\n+++ b/lib/librte_eal/linuxapp/unci/Makefile\n@@ -48,5 +48,6 @@ MODULE_CFLAGS += -Wall -Werror\n # all source are stored in SRCS-y\n #\n SRCS-$(CONFIG_RTE_UNCI_KMOD) := unci_net.c\n+SRCS-$(CONFIG_RTE_UNCI_KMOD) += unci_nl.c\n \n include $(RTE_SDK)/mk/rte.module.mk\ndiff --git a/lib/librte_eal/linuxapp/unci/unci_dev.h b/lib/librte_eal/linuxapp/unci/unci_dev.h\nindex b0a215f1b..668574167 100644\n--- a/lib/librte_eal/linuxapp/unci/unci_dev.h\n+++ b/lib/librte_eal/linuxapp/unci/unci_dev.h\n@@ -38,4 +38,7 @@ struct unci_dev {\n \tu32 pid;\n };\n \n+void unci_nl_init(void);\n+void unci_nl_release(void);\n+\n #endif /* _UNCI_DEV_H_ */\ndiff --git a/lib/librte_eal/linuxapp/unci/unci_net.c b/lib/librte_eal/linuxapp/unci/unci_net.c\nindex ee23b0e4d..131769c37 100644\n--- a/lib/librte_eal/linuxapp/unci/unci_net.c\n+++ b/lib/librte_eal/linuxapp/unci/unci_net.c\n@@ -63,6 +63,7 @@ static struct rtnl_link_ops unci_link_ops __read_mostly = {\n \n static int __init unci_init(void)\n {\n+\tunci_nl_init();\n \treturn rtnl_link_register(&unci_link_ops);\n }\n module_init(unci_init);\n@@ -70,6 +71,7 @@ module_init(unci_init);\n static void __exit unci_exit(void)\n {\n \trtnl_link_unregister(&unci_link_ops);\n+\tunci_nl_release();\n }\n module_exit(unci_exit);\n \ndiff --git a/lib/librte_eal/linuxapp/unci/unci_nl.c b/lib/librte_eal/linuxapp/unci/unci_nl.c\nnew file mode 100644\nindex 000000000..9d07e9822\n--- /dev/null\n+++ b/lib/librte_eal/linuxapp/unci/unci_nl.c\n@@ -0,0 +1,55 @@\n+/*-\n+ * GPL LICENSE SUMMARY\n+ *\n+ *   Copyright(c) 2017 Intel Corporation. All rights reserved.\n+ *\n+ *   This program is free software; you can redistribute it and/or modify\n+ *   it under the terms of version 2 of the GNU General Public License as\n+ *   published by the Free Software Foundation.\n+ *\n+ *   This program is distributed in the hope that it will be useful, but\n+ *   WITHOUT ANY WARRANTY; without even the implied warranty of\n+ *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU\n+ *   General Public License for more details.\n+ *\n+ *   You should have received a copy of the GNU General Public License\n+ *   along with this program;\n+ *   The full GNU General Public License is included in this distribution\n+ *   in the file called LICENSE.GPL.\n+ *\n+ *   Contact Information:\n+ *   Intel Corporation\n+ */\n+\n+#include <net/sock.h>\n+\n+#include \"unci_dev.h\"\n+\n+static struct sock *nl_sock;\n+static struct mutex sync_lock;\n+\n+static void nl_recv(struct sk_buff *skb)\n+{\n+\tstruct nlmsghdr *nlh;\n+\tstruct unci_nl_msg nl_msg;\n+\n+\tnlh = (struct nlmsghdr *)skb->data;\n+\n+\tmemcpy(&nl_msg, NLMSG_DATA(nlh), sizeof(struct unci_nl_msg));\n+\tpr_debug(\"CMD: %u\\n\", nl_msg.cmd_id);\n+}\n+\n+static struct netlink_kernel_cfg cfg = {\n+\t.input = nl_recv,\n+};\n+\n+void unci_nl_init(void)\n+{\n+\tnl_sock = netlink_kernel_create(&init_net, UNCI_NL_GRP, &cfg);\n+\tmutex_init(&sync_lock);\n+}\n+\n+void unci_nl_release(void)\n+{\n+\tnetlink_kernel_release(nl_sock);\n+}\n",
    "prefixes": [
        "dpdk-dev",
        "v9",
        "10/20"
    ]
}