get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 89544,
    "url": "http://patches.dpdk.org/api/patches/89544/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/20210319072628.10000-3-jiawenwu@trustnetic.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": "<20210319072628.10000-3-jiawenwu@trustnetic.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/20210319072628.10000-3-jiawenwu@trustnetic.com",
    "date": "2021-03-19T07:26:24",
    "name": "[v2,2/6] net/ngbe: add device IDs",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "9f8c5a025838076c130732efd7e14f8e2c4c2120",
    "submitter": {
        "id": 1932,
        "url": "http://patches.dpdk.org/api/people/1932/?format=api",
        "name": "Jiawen Wu",
        "email": "jiawenwu@trustnetic.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/20210319072628.10000-3-jiawenwu@trustnetic.com/mbox/",
    "series": [
        {
            "id": 15788,
            "url": "http://patches.dpdk.org/api/series/15788/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=15788",
            "date": "2021-03-19T07:26:22",
            "name": "net: ngbe PMD",
            "version": 2,
            "mbox": "http://patches.dpdk.org/series/15788/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/89544/comments/",
    "check": "success",
    "checks": "http://patches.dpdk.org/api/patches/89544/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 36AF9A0562;\n\tFri, 19 Mar 2021 08:27:16 +0100 (CET)",
            "from [217.70.189.124] (localhost [127.0.0.1])\n\tby mails.dpdk.org (Postfix) with ESMTP id D589A140F21;\n\tFri, 19 Mar 2021 08:26:49 +0100 (CET)",
            "from smtpbg506.qq.com (smtpbg506.qq.com [203.205.250.33])\n by mails.dpdk.org (Postfix) with ESMTP id 791EE40143\n for <dev@dpdk.org>; Fri, 19 Mar 2021 08:26:40 +0100 (CET)",
            "from jiawenwu.trustnetic.com (unknown [183.129.236.74])\n by esmtp6.qq.com (ESMTP) with\n id ; Fri, 19 Mar 2021 15:26:33 +0800 (CST)"
        ],
        "X-QQ-mid": "bizesmtp29t1616138794tsk4jw7r",
        "X-QQ-SSF": "01400000002000C0E000B00A0000000",
        "X-QQ-FEAT": "BloGqNXZ5V/nKv1VFAQ2RADNqDySRra+UO9y9HUuNI7YA25IWWeaiIXfJnjKq\n mbVH5y4TPSLahOIRDAzOu7mUZ646i5+clXVsyrfP7qMfTMs5ScMakrm1+mf2XvCiG+ePEJv\n a+tfxqhJ9nPLdmx3iiXRVukqQhRDaQNOVXGrTAUkaiLmwMB41S5KRPiKh0VgEEAUbWPEVVi\n ywBVerXQDOx/Q43R2AiG9R6CYCt3iKPI5HJpK9xcHv37Bx6uzNtJuTkn0gj9tQej2PMwmQC\n o15YsN69GxmtBM1pkvOMtrWSAq89dKXScxVh+W7tlINsgP1x4cU3KOOTJNcdLXRUFMlaLb+\n jV+p3oddQerAtcvFQUqwLyOEGVlenTdCt2d5gz+",
        "X-QQ-GoodBg": "2",
        "From": "Jiawen Wu <jiawenwu@trustnetic.com>",
        "To": "dev@dpdk.org",
        "Cc": "Jiawen Wu <jiawenwu@trustnetic.com>",
        "Date": "Fri, 19 Mar 2021 15:26:24 +0800",
        "Message-Id": "<20210319072628.10000-3-jiawenwu@trustnetic.com>",
        "X-Mailer": "git-send-email 2.21.0.windows.1",
        "In-Reply-To": "<20210319072628.10000-1-jiawenwu@trustnetic.com>",
        "References": "<20210319072628.10000-1-jiawenwu@trustnetic.com>",
        "MIME-Version": "1.0",
        "Content-Transfer-Encoding": "8bit",
        "X-QQ-SENDSIZE": "520",
        "Feedback-ID": "bizesmtp:trustnetic.com:qybgforeign:qybgforeign6",
        "X-QQ-Bgrelay": "1",
        "Subject": "[dpdk-dev] [PATCH v2 2/6] net/ngbe: add device IDs",
        "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",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "Add device IDs for Wangxun 1Gb NICs, and register rte_ngbe_pmd.\n\nSigned-off-by: Jiawen Wu <jiawenwu@trustnetic.com>\n---\n drivers/net/ngbe/base/meson.build   | 18 +++++++\n drivers/net/ngbe/base/ngbe_devids.h | 83 +++++++++++++++++++++++++++++\n drivers/net/ngbe/meson.build        |  6 +++\n drivers/net/ngbe/ngbe_ethdev.c      | 33 ++++++++++++\n 4 files changed, 140 insertions(+)\n create mode 100644 drivers/net/ngbe/base/meson.build\n create mode 100644 drivers/net/ngbe/base/ngbe_devids.h",
    "diff": "diff --git a/drivers/net/ngbe/base/meson.build b/drivers/net/ngbe/base/meson.build\nnew file mode 100644\nindex 000000000..b4fc6a53b\n--- /dev/null\n+++ b/drivers/net/ngbe/base/meson.build\n@@ -0,0 +1,18 @@\n+# SPDX-License-Identifier: BSD-3-Clause\n+# Copyright(c) 2018-2020\n+\n+sources = []\n+\n+error_cflags = []\n+\n+c_args = cflags\n+foreach flag: error_cflags\n+\tif cc.has_argument(flag)\n+\t\tc_args += flag\n+\tendif\n+endforeach\n+\n+base_lib = static_library('ngbe_base', sources,\n+\tdependencies: [static_rte_eal, static_rte_ethdev, static_rte_bus_pci],\n+\tc_args: c_args)\n+base_objs = base_lib.extract_all_objects()\ndiff --git a/drivers/net/ngbe/base/ngbe_devids.h b/drivers/net/ngbe/base/ngbe_devids.h\nnew file mode 100644\nindex 000000000..79967b9fe\n--- /dev/null\n+++ b/drivers/net/ngbe/base/ngbe_devids.h\n@@ -0,0 +1,83 @@\n+/* SPDX-License-Identifier: BSD-3-Clause\n+ * Copyright(c) 2018-2020\n+ */\n+\n+#ifndef _NGBE_DEVIDS_H_\n+#define _NGBE_DEVIDS_H_\n+\n+/*\n+ * Vendor ID\n+ */\n+#ifndef PCI_VENDOR_ID_WANGXUN\n+#define PCI_VENDOR_ID_WANGXUN                   0x8088\n+#endif\n+\n+/*\n+ * Device IDs\n+ */\n+#define NGBE_DEV_ID_EM_VF\t\t\t0x0110\n+#define   NGBE_SUB_DEV_ID_EM_VF\t\t\t0x0110\n+#define NGBE_DEV_ID_EM\t\t\t\t0x0100\n+#define   NGBE_SUB_DEV_ID_EM_MVL_RGMII\t\t0x0200\n+#define   NGBE_SUB_DEV_ID_EM_MVL_SFP\t\t0x0403\n+#define   NGBE_SUB_DEV_ID_EM_RTL_SGMII\t\t0x0410\n+#define   NGBE_SUB_DEV_ID_EM_YT8521S_SFP\t0x0460\n+\n+#define NGBE_DEV_ID_EM_WX1860AL_W\t\t0x0100\n+#define NGBE_DEV_ID_EM_WX1860AL_W_VF\t\t0x0110\n+#define NGBE_DEV_ID_EM_WX1860A2\t\t\t0x0101\n+#define NGBE_DEV_ID_EM_WX1860A2_VF\t\t0x0111\n+#define NGBE_DEV_ID_EM_WX1860A2S\t\t0x0102\n+#define NGBE_DEV_ID_EM_WX1860A2S_VF\t\t0x0112\n+#define NGBE_DEV_ID_EM_WX1860A4\t\t\t0x0103\n+#define NGBE_DEV_ID_EM_WX1860A4_VF\t\t0x0113\n+#define NGBE_DEV_ID_EM_WX1860A4S\t\t0x0104\n+#define NGBE_DEV_ID_EM_WX1860A4S_VF\t\t0x0114\n+#define NGBE_DEV_ID_EM_WX1860AL2\t\t0x0105\n+#define NGBE_DEV_ID_EM_WX1860AL2_VF\t\t0x0115\n+#define NGBE_DEV_ID_EM_WX1860AL2S\t\t0x0106\n+#define NGBE_DEV_ID_EM_WX1860AL2S_VF\t\t0x0116\n+#define NGBE_DEV_ID_EM_WX1860AL4\t\t0x0107\n+#define NGBE_DEV_ID_EM_WX1860AL4_VF\t\t0x0117\n+#define NGBE_DEV_ID_EM_WX1860AL4S\t\t0x0108\n+#define NGBE_DEV_ID_EM_WX1860AL4S_VF\t\t0x0118\n+#define NGBE_DEV_ID_EM_WX1860NCSI\t\t0x0109\n+#define NGBE_DEV_ID_EM_WX1860NCSI_VF\t\t0x0119\n+#define NGBE_DEV_ID_EM_WX1860A1\t\t\t0x010A\n+#define NGBE_DEV_ID_EM_WX1860A1_VF\t\t0x011A\n+#define NGBE_DEV_ID_EM_WX1860A1L\t\t0x010B\n+#define NGBE_DEV_ID_EM_WX1860A1L_VF\t\t0x011B\n+#define   NGBE_SUB_DEV_ID_EM_ZTE5201_RJ45\t0x0100\n+#define   NGBE_SUB_DEV_ID_EM_SF100F_LP\t\t0x0103\n+#define   NGBE_SUB_DEV_ID_EM_M88E1512_RJ45\t0x0200\n+#define   NGBE_SUB_DEV_ID_EM_SF100HT\t\t0x0102\n+#define   NGBE_SUB_DEV_ID_EM_SF200T\t\t0x0201\n+#define   NGBE_SUB_DEV_ID_EM_SF200HT\t\t0x0202\n+#define   NGBE_SUB_DEV_ID_EM_SF200T_S\t\t0x0210\n+#define   NGBE_SUB_DEV_ID_EM_SF200HT_S\t\t0x0220\n+#define   NGBE_SUB_DEV_ID_EM_SF200HXT\t\t0x0230\n+#define   NGBE_SUB_DEV_ID_EM_SF400T\t\t0x0401\n+#define   NGBE_SUB_DEV_ID_EM_SF400HT\t\t0x0402\n+#define   NGBE_SUB_DEV_ID_EM_M88E1512_SFP\t0x0403\n+#define   NGBE_SUB_DEV_ID_EM_SF400T_S\t\t0x0410\n+#define   NGBE_SUB_DEV_ID_EM_SF400HT_S\t\t0x0420\n+#define   NGBE_SUB_DEV_ID_EM_SF400HXT\t\t0x0430\n+#define   NGBE_SUB_DEV_ID_EM_SF400_OCP\t\t0x0440\n+#define   NGBE_SUB_DEV_ID_EM_SF400_LY\t\t0x0450\n+#define   NGBE_SUB_DEV_ID_EM_SF400_LY_YT\t0x0470\n+\n+/* Assign excessive id with masks */\n+#define NGBE_INTERNAL_MASK\t\t\t0x000F\n+#define NGBE_OEM_MASK\t\t\t\t0x00F0\n+#define NGBE_WOL_SUP_MASK\t\t\t0x4000\n+#define NGBE_NCSI_SUP_MASK\t\t\t0x8000\n+\n+#define NGBE_INTERNAL_SFP\t\t\t0x0003\n+#define NGBE_OCP_CARD\t\t\t\t0x0040\n+#define NGBE_LY_M88E1512_SFP\t\t\t0x0050\n+#define NGBE_YT8521S_SFP\t\t\t0x0060\n+#define NGBE_LY_YT8521S_SFP\t\t\t0x0070\n+#define NGBE_WOL_SUP\t\t\t\t0x4000\n+#define NGBE_NCSI_SUP\t\t\t\t0x8000\n+\n+#endif /* _NGBE_DEVIDS_H_ */\ndiff --git a/drivers/net/ngbe/meson.build b/drivers/net/ngbe/meson.build\nindex d6388d061..0bd457c14 100644\n--- a/drivers/net/ngbe/meson.build\n+++ b/drivers/net/ngbe/meson.build\n@@ -7,6 +7,12 @@ if is_windows\n \tsubdir_done()\n endif\n \n+subdir('base')\n+objs = [base_objs]\n+\n sources = files(\n \t'ngbe_ethdev.c',\n )\n+\n+includes += include_directories('base')\n+\ndiff --git a/drivers/net/ngbe/ngbe_ethdev.c b/drivers/net/ngbe/ngbe_ethdev.c\nindex e2756315a..da951b6ef 100644\n--- a/drivers/net/ngbe/ngbe_ethdev.c\n+++ b/drivers/net/ngbe/ngbe_ethdev.c\n@@ -2,3 +2,36 @@\n   * Copyright(c) 2018-2020\n   */\n \n+#include <ethdev_pci.h>\n+\n+#include <base/ngbe_devids.h>\n+\n+/*\n+ * The set of PCI devices this driver supports\n+ */\n+static const struct rte_pci_id pci_id_ngbe_map[] = {\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A2) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A2S) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A4) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A4S) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860AL2) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860AL2S) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860AL4) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860AL4S) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860NCSI) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A1) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860A1L) },\n+\t{ RTE_PCI_DEVICE(PCI_VENDOR_ID_WANGXUN, NGBE_DEV_ID_EM_WX1860AL_W) },\n+\t{ .vendor_id = 0, /* sentinel */ },\n+};\n+\n+static struct rte_pci_driver rte_ngbe_pmd = {\n+\t.id_table = pci_id_ngbe_map,\n+\t.drv_flags = RTE_PCI_DRV_NEED_MAPPING |\n+\t\t     RTE_PCI_DRV_INTR_LSC,\n+};\n+\n+RTE_PMD_REGISTER_PCI(net_ngbe, rte_ngbe_pmd);\n+RTE_PMD_REGISTER_PCI_TABLE(net_ngbe, pci_id_ngbe_map);\n+RTE_PMD_REGISTER_KMOD_DEP(net_ngbe, \"* igb_uio | uio_pci_generic | vfio-pci\");\n+\n",
    "prefixes": [
        "v2",
        "2/6"
    ]
}