get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 41939,
    "url": "http://patches.dpdk.org/api/patches/41939/?format=api",
    "web_url": "http://patches.dpdk.org/project/dpdk/patch/1530267871-7161-2-git-send-email-jia.guo@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": "<1530267871-7161-2-git-send-email-jia.guo@intel.com>",
    "list_archive_url": "https://inbox.dpdk.org/dev/1530267871-7161-2-git-send-email-jia.guo@intel.com",
    "date": "2018-06-29T10:24:23",
    "name": "[V4,1/9] bus: introduce hotplug failure handler",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": true,
    "hash": "2be970f77d1162874ee94972edf00e6592eb97d9",
    "submitter": {
        "id": 507,
        "url": "http://patches.dpdk.org/api/people/507/?format=api",
        "name": "Guo, Jia",
        "email": "jia.guo@intel.com"
    },
    "delegate": null,
    "mbox": "http://patches.dpdk.org/project/dpdk/patch/1530267871-7161-2-git-send-email-jia.guo@intel.com/mbox/",
    "series": [
        {
            "id": 314,
            "url": "http://patches.dpdk.org/api/series/314/?format=api",
            "web_url": "http://patches.dpdk.org/project/dpdk/list/?series=314",
            "date": "2018-06-29T10:24:22",
            "name": "hot plug failure handle mechanism",
            "version": 4,
            "mbox": "http://patches.dpdk.org/series/314/mbox/"
        }
    ],
    "comments": "http://patches.dpdk.org/api/patches/41939/comments/",
    "check": "fail",
    "checks": "http://patches.dpdk.org/api/patches/41939/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 [127.0.0.1])\n\tby dpdk.org (Postfix) with ESMTP id 569111B4F7;\n\tFri, 29 Jun 2018 12:26:57 +0200 (CEST)",
            "from mga03.intel.com (mga03.intel.com [134.134.136.65])\n\tby dpdk.org (Postfix) with ESMTP id 6743C1B4EF\n\tfor <dev@dpdk.org>; Fri, 29 Jun 2018 12:26:55 +0200 (CEST)",
            "from fmsmga005.fm.intel.com ([10.253.24.32])\n\tby orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t29 Jun 2018 03:26:55 -0700",
            "from jeffguo-z170x-ud5.sh.intel.com (HELO localhost.localdomain)\n\t([10.67.104.10])\n\tby fmsmga005.fm.intel.com with ESMTP; 29 Jun 2018 03:26:51 -0700"
        ],
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.51,285,1526367600\"; d=\"scan'208\";a=\"241324416\"",
        "From": "Jeff Guo <jia.guo@intel.com>",
        "To": "stephen@networkplumber.org, bruce.richardson@intel.com,\n\tferruh.yigit@intel.com, konstantin.ananyev@intel.com,\n\tgaetan.rivet@6wind.com, jingjing.wu@intel.com, thomas@monjalon.net,\n\tmotih@mellanox.com, matan@mellanox.com, harry.van.haaren@intel.com,\n\tqi.z.zhang@intel.com, shaopeng.he@intel.com, bernard.iremonger@intel.com",
        "Cc": "jblunck@infradead.org, shreyansh.jain@nxp.com, dev@dpdk.org,\n\tjia.guo@intel.com, helin.zhang@intel.com",
        "Date": "Fri, 29 Jun 2018 18:24:23 +0800",
        "Message-Id": "<1530267871-7161-2-git-send-email-jia.guo@intel.com>",
        "X-Mailer": "git-send-email 2.7.4",
        "In-Reply-To": "<1530267871-7161-1-git-send-email-jia.guo@intel.com>",
        "References": "<1530267871-7161-1-git-send-email-jia.guo@intel.com>",
        "Subject": "[dpdk-dev] [PATCH V4 1/9] bus: introduce hotplug failure handler",
        "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\t<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\t<mailto:dev-request@dpdk.org?subject=subscribe>",
        "Errors-To": "dev-bounces@dpdk.org",
        "Sender": "\"dev\" <dev-bounces@dpdk.org>"
    },
    "content": "When a hardware device is removed physically or the software disables\nit, the hotplug occur. App need to call ether dev API to detach the device,\nto unplug the device at the bus level and make access to the device\ninvalid. But the removal of the device from the software lists is not going\nto be instantaneous, at this time if the data path still read/write the\ndevice, it will cause MMIO error and result of the app crash out. So a\nhotplug failure handle mechanism need to be used to guaranty app will not\ncrash out when hot unplug device.\n\nTo handle device hot plug failure is a bus-specific behavior, this patch\nintroduces a bus ops so that each kind of bus can implement its own logic.\n\nSigned-off-by: Jeff Guo <jia.guo@intel.com>\n---\nv4->v3:\nsplit patches to be small and clear.\n---\n lib/librte_eal/common/include/rte_bus.h | 15 +++++++++++++++\n 1 file changed, 15 insertions(+)",
    "diff": "diff --git a/lib/librte_eal/common/include/rte_bus.h b/lib/librte_eal/common/include/rte_bus.h\nindex eb9eded..3642aeb 100644\n--- a/lib/librte_eal/common/include/rte_bus.h\n+++ b/lib/librte_eal/common/include/rte_bus.h\n@@ -168,6 +168,19 @@ typedef int (*rte_bus_unplug_t)(struct rte_device *dev);\n typedef int (*rte_bus_parse_t)(const char *name, void *addr);\n \n /**\n+ * Implementation a specific hot plug handler, which is responsible\n+ * for handle the failure when hot remove the device, guaranty the system\n+ * would not crash in the case.\n+ * @param dev\n+ *\tPointer of the device structure.\n+ *\n+ * @return\n+ *\t0 on success.\n+ *\t!0 on error.\n+ */\n+typedef int (*rte_bus_hotplug_handler_t)(struct rte_device *dev);\n+\n+/**\n  * Bus scan policies\n  */\n enum rte_bus_scan_mode {\n@@ -211,6 +224,8 @@ struct rte_bus {\n \trte_bus_parse_t parse;       /**< Parse a device name */\n \tstruct rte_bus_conf conf;    /**< Bus configuration */\n \trte_bus_get_iommu_class_t get_iommu_class; /**< Get iommu class */\n+\trte_bus_hotplug_handler_t hotplug_handler;\n+\t\t\t\t\t\t/**< handle hot plug on bus */\n };\n \n /**\n",
    "prefixes": [
        "V4",
        "1/9"
    ]
}