get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 807281,
    "url": "http://patchwork.ozlabs.org/api/patches/807281/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20170829201601.64312-9-sjg@chromium.org/",
    "project": {
        "id": 18,
        "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api",
        "name": "U-Boot",
        "link_name": "uboot",
        "list_id": "u-boot.lists.denx.de",
        "list_email": "u-boot@lists.denx.de",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170829201601.64312-9-sjg@chromium.org>",
    "list_archive_url": null,
    "date": "2017-08-29T20:15:53",
    "name": "[U-Boot,v2,08/16] dtoc: Use the Fdt's class's phandle map",
    "commit_ref": "72ab7c5e384f415b66dc9bef41db928cfc11c310",
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "ce66e6e7685db6d613834a16dc22202a45581169",
    "submitter": {
        "id": 6170,
        "url": "http://patchwork.ozlabs.org/api/people/6170/?format=api",
        "name": "Simon Glass",
        "email": "sjg@chromium.org"
    },
    "delegate": {
        "id": 3184,
        "url": "http://patchwork.ozlabs.org/api/users/3184/?format=api",
        "username": "sjg",
        "first_name": "Simon",
        "last_name": "Glass",
        "email": "sjg@chromium.org"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20170829201601.64312-9-sjg@chromium.org/mbox/",
    "series": [
        {
            "id": 462,
            "url": "http://patchwork.ozlabs.org/api/series/462/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=462",
            "date": "2017-08-29T20:15:45",
            "name": "dtoc: Add support for 64-bit addresses",
            "version": 2,
            "mbox": "http://patchwork.ozlabs.org/series/462/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/807281/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/807281/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<u-boot-bounces@lists.denx.de>",
        "X-Original-To": "incoming@patchwork.ozlabs.org",
        "Delivered-To": "patchwork-incoming@bilbo.ozlabs.org",
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=lists.denx.de\n\t(client-ip=81.169.180.215; helo=lists.denx.de;\n\tenvelope-from=u-boot-bounces@lists.denx.de;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=google.com header.i=@google.com\n\theader.b=\"BmPa6x0Z\"; dkim-atps=neutral"
        ],
        "Received": [
            "from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 3xhgCf4g2gz9sQl\n\tfor <incoming@patchwork.ozlabs.org>;\n\tWed, 30 Aug 2017 06:26:54 +1000 (AEST)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 610FEC22345; Tue, 29 Aug 2017 20:24:26 +0000 (UTC)",
            "from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 0D0F5C22670;\n\tTue, 29 Aug 2017 20:18:32 +0000 (UTC)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 1C385C2266A; Tue, 29 Aug 2017 20:16:22 +0000 (UTC)",
            "from mail-oi0-f44.google.com (mail-oi0-f44.google.com\n\t[209.85.218.44])\n\tby lists.denx.de (Postfix) with ESMTPS id DBC3FC225CA\n\tfor <u-boot@lists.denx.de>; Tue, 29 Aug 2017 20:16:18 +0000 (UTC)",
            "by mail-oi0-f44.google.com with SMTP id r203so36447696oih.0\n\tfor <u-boot@lists.denx.de>; Tue, 29 Aug 2017 13:16:18 -0700 (PDT)",
            "from kiwi.bld.corp.google.com ([100.101.164.89])\n\tby smtp.gmail.com with ESMTPSA id\n\th125sm4017700oic.54.2017.08.29.13.16.15\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tTue, 29 Aug 2017 13:16:15 -0700 (PDT)",
            "by kiwi.bld.corp.google.com (Postfix, from userid 121222)\n\tid 16B5B13FAB7; Tue, 29 Aug 2017 14:16:15 -0600 (MDT)"
        ],
        "X-Spam-Checker-Version": "SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de",
        "X-Spam-Level": "",
        "X-Spam-Status": "No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,\n\tRCVD_IN_MSPIKE_H2,\n\tT_DKIM_INVALID autolearn=unavailable autolearn_force=no\n\tversion=3.4.0",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;\n\ts=20161025; \n\th=sender:from:to:cc:subject:date:message-id:in-reply-to:references;\n\tbh=9PBlIwbZW+Prc5/Mqx6QaTRerlUoEeSwM8TxV02K3ek=;\n\tb=BmPa6x0ZtvP5RqASMStgmv09fdJILmjPYvVU4BsqA7vVVdI90RI5BUnJTaQWVxSwzM\n\tu15dqsS9hmAvSjw/O7UIzK/aXRrMHsIgDjgPBTExtddk0kXCT+IFSGJJx96ZXLdFgXyj\n\tki0blj0Mod7aLIQlX3bSSdcxQ1deLCahJz7YRfGJQooxi3Xabtm7G5z6XZ7bE2B5Qhhg\n\tI6TRkYiO+yG/z8gfaxDM500hUjxiF52tukD8oVCtw1A1ro/SAG7+8MQIA1juAuZ89SJ2\n\tpuIj+JejQPhq+i6QpVtU6+DkSu5kQXb0q4d7rQRHCQ21bqRKEF/FfZSWxh9ld1F1VlMd\n\tcjfA==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:sender:from:to:cc:subject:date:message-id\n\t:in-reply-to:references;\n\tbh=9PBlIwbZW+Prc5/Mqx6QaTRerlUoEeSwM8TxV02K3ek=;\n\tb=DMkDaXMUvbno/fkzxouiQHGWwuLK1KQimnsbmUqon4m6C5MfjTLNW6FQ+gSsecu0Og\n\thicZ7SjL4Mp0Gibh4sBtA62aoMVCqQoPyVn0mfkaLSoDda0lBnfbYsaC2jqzvkdi9zee\n\tligloTG0pKqqFDcz9KRVLcUj2uy49uEhrvv5gXs3gjKzSpZIq+Uc931iP9FSpJti7TSH\n\t7ABW/gRDejr49AuS3oQCJGgX01+tU6ka07ZNsMCxv7ToEV0LL03zZ/00Nv9GRs79Xxzf\n\talbVIkwRthF1cpy4qXJUoLFxbdrJPL/rEsRcc85DjnjyetQUlKPEOHFVgM3E4iNJi1ym\n\tM43g==",
        "X-Gm-Message-State": "AHYfb5hK2E2mzdO32ltU5h16m8CHTtI2QrXuAvjIP6sMmcsgGXJjVRv8\n\tvAa7bnuelAOVi4EiwVGCGQ==",
        "X-Google-Smtp-Source": "ADKCNb5AqDZfeuqJoqIgI7jVYSMlwOm7PJNDibT64WwLqxponsSoxsiJ5OtpPgdlQF4SYpMRaQnpDA==",
        "X-Received": "by 10.202.181.195 with SMTP id\n\te186mr1294940oif.280.1504037777199; \n\tTue, 29 Aug 2017 13:16:17 -0700 (PDT)",
        "From": "Simon Glass <sjg@chromium.org>",
        "To": "U-Boot Mailing List <u-boot@lists.denx.de>",
        "Date": "Tue, 29 Aug 2017 14:15:53 -0600",
        "Message-Id": "<20170829201601.64312-9-sjg@chromium.org>",
        "X-Mailer": "git-send-email 2.14.1.342.g6490525c54-goog",
        "In-Reply-To": "<20170829201601.64312-1-sjg@chromium.org>",
        "References": "<20170829201601.64312-1-sjg@chromium.org>",
        "Cc": "Tom Rini <trini@konsulko.com>",
        "Subject": "[U-Boot] [PATCH v2 08/16] dtoc: Use the Fdt's class's phandle map",
        "X-BeenThere": "u-boot@lists.denx.de",
        "X-Mailman-Version": "2.1.18",
        "Precedence": "list",
        "List-Id": "U-Boot discussion <u-boot.lists.denx.de>",
        "List-Unsubscribe": "<https://lists.denx.de/options/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=unsubscribe>",
        "List-Archive": "<http://lists.denx.de/pipermail/u-boot/>",
        "List-Post": "<mailto:u-boot@lists.denx.de>",
        "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>",
        "List-Subscribe": "<https://lists.denx.de/listinfo/u-boot>,\n\t<mailto:u-boot-request@lists.denx.de?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"utf-8\"",
        "Content-Transfer-Encoding": "base64",
        "Errors-To": "u-boot-bounces@lists.denx.de",
        "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>"
    },
    "content": "Now that the Fdt class can map phandles to the associated nodes, use that\ninstead of a separate implementation.\n\nSigned-off-by: Simon Glass <sjg@chromium.org>\n---\n\nChanges in v2: None\n\n tools/dtoc/dtb_platdata.py | 16 +++-------------\n 1 file changed, 3 insertions(+), 13 deletions(-)",
    "diff": "diff --git a/tools/dtoc/dtb_platdata.py b/tools/dtoc/dtb_platdata.py\nindex 0c719310b1..705ab27c86 100644\n--- a/tools/dtoc/dtb_platdata.py\n+++ b/tools/dtoc/dtb_platdata.py\n@@ -144,17 +144,14 @@ class DtbPlatdata(object):\n         _dtb_fname: Filename of the input device tree binary file\n         _valid_nodes: A list of Node object with compatible strings\n         _include_disabled: true to include nodes marked status = \"disabled\"\n-        _phandle_nodes: A dict of nodes indexed by phandle number (1, 2...)\n         _outfile: The current output file (sys.stdout or a real file)\n         _lines: Stashed list of output lines for outputting in the future\n-        _phandle_nodes: A dict of Nodes indexed by phandle (an integer)\n     \"\"\"\n     def __init__(self, dtb_fname, include_disabled):\n         self._fdt = None\n         self._dtb_fname = dtb_fname\n         self._valid_nodes = None\n         self._include_disabled = include_disabled\n-        self._phandle_nodes = {}\n         self._outfile = None\n         self._lines = []\n         self._aliases = {}\n@@ -210,8 +207,7 @@ class DtbPlatdata(object):\n     def scan_node(self, root):\n         \"\"\"Scan a node and subnodes to build a tree of node and phandle info\n \n-        This adds each node to self._valid_nodes and each phandle to\n-        self._phandle_nodes.\n+        This adds each node to self._valid_nodes.\n \n         Args:\n             root: Root node for scan\n@@ -222,10 +218,6 @@ class DtbPlatdata(object):\n                 if (not self._include_disabled and not status or\n                         status.value != 'disabled'):\n                     self._valid_nodes.append(node)\n-                    phandle_prop = node.props.get('phandle')\n-                    if phandle_prop:\n-                        phandle = phandle_prop.GetPhandle()\n-                        self._phandle_nodes[phandle] = node\n \n             # recurse to handle any subnodes\n             self.scan_node(node)\n@@ -234,11 +226,9 @@ class DtbPlatdata(object):\n         \"\"\"Scan the device tree for useful information\n \n         This fills in the following properties:\n-            _phandle_nodes: A dict of Nodes indexed by phandle (an integer)\n             _valid_nodes: A list of nodes we wish to consider include in the\n                 platform data\n         \"\"\"\n-        self._phandle_nodes = {}\n         self._valid_nodes = []\n         return self.scan_node(self._fdt.GetRoot())\n \n@@ -374,7 +364,7 @@ class DtbPlatdata(object):\n                         value_it = iter(prop.value)\n                         for phandle_cell, _ in zip(value_it, value_it):\n                             phandle = fdt_util.fdt32_to_cpu(phandle_cell)\n-                            target_node = self._phandle_nodes[phandle]\n+                            target_node = self._fdt.phandle_to_node[phandle]\n                             node.phandles.add(target_node)\n \n \n@@ -439,7 +429,7 @@ class DtbPlatdata(object):\n                     for phandle_cell, id_cell in zip(value_it, value_it):\n                         phandle = fdt_util.fdt32_to_cpu(phandle_cell)\n                         id_num = fdt_util.fdt32_to_cpu(id_cell)\n-                        target_node = self._phandle_nodes[phandle]\n+                        target_node = self._fdt.phandle_to_node[phandle]\n                         name = conv_name_to_c(target_node.name)\n                         vals.append('{&%s%s, %d}' % (VAL_PREFIX, name, id_num))\n                 else:\n",
    "prefixes": [
        "U-Boot",
        "v2",
        "08/16"
    ]
}