get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 1132711,
    "url": "http://patchwork.ozlabs.org/api/patches/1132711/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20190716115745.12585-42-jagan@amarulasolutions.com/",
    "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": "<20190716115745.12585-42-jagan@amarulasolutions.com>",
    "list_archive_url": null,
    "date": "2019-07-16T11:57:29",
    "name": "[U-Boot,v3,41/57] ram: rk3399: Simplify data training first argument",
    "commit_ref": "e6ae37a007c2ddc5f070c8ce65349b472e625060",
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "266a531ac0858661e7a09e0a099c698bf5fa52c4",
    "submitter": {
        "id": 69820,
        "url": "http://patchwork.ozlabs.org/api/people/69820/?format=api",
        "name": "Jagan Teki",
        "email": "jagan@amarulasolutions.com"
    },
    "delegate": {
        "id": 93623,
        "url": "http://patchwork.ozlabs.org/api/users/93623/?format=api",
        "username": "kevery",
        "first_name": "Kever",
        "last_name": "Yang",
        "email": "ykai007@gmail.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20190716115745.12585-42-jagan@amarulasolutions.com/mbox/",
    "series": [
        {
            "id": 119754,
            "url": "http://patchwork.ozlabs.org/api/series/119754/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=119754",
            "date": "2019-07-16T11:56:48",
            "name": "ram: rk3399: Add LPDDR4 support",
            "version": 3,
            "mbox": "http://patchwork.ozlabs.org/series/119754/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/1132711/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/1132711/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; dmarc=none (p=none dis=none)\n\theader.from=amarulasolutions.com",
            "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=amarulasolutions.com\n\theader.i=@amarulasolutions.com header.b=\"HYCN8itO\"; \n\tdkim-atps=neutral"
        ],
        "Received": [
            "from lists.denx.de (dione.denx.de [81.169.180.215])\n\tby ozlabs.org (Postfix) with ESMTP id 45nzvC6Q78z9sNC\n\tfor <incoming@patchwork.ozlabs.org>;\n\tTue, 16 Jul 2019 22:18:15 +1000 (AEST)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 968FBC21E35; Tue, 16 Jul 2019 12:05:00 +0000 (UTC)",
            "from lists.denx.de (localhost [IPv6:::1])\n\tby lists.denx.de (Postfix) with ESMTP id 16011C21DA6;\n\tTue, 16 Jul 2019 12:02:31 +0000 (UTC)",
            "by lists.denx.de (Postfix, from userid 105)\n\tid 81BDCC21D8A; Tue, 16 Jul 2019 12:00:27 +0000 (UTC)",
            "from mail-pl1-f195.google.com (mail-pl1-f195.google.com\n\t[209.85.214.195])\n\tby lists.denx.de (Postfix) with ESMTPS id E960CC21E2B\n\tfor <u-boot@lists.denx.de>; Tue, 16 Jul 2019 12:00:23 +0000 (UTC)",
            "by mail-pl1-f195.google.com with SMTP id az7so9998418plb.5\n\tfor <u-boot@lists.denx.de>; Tue, 16 Jul 2019 05:00:23 -0700 (PDT)",
            "from localhost.localdomain ([49.206.201.107])\n\tby smtp.gmail.com with ESMTPSA id\n\tz24sm36269566pfr.51.2019.07.16.05.00.19\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tTue, 16 Jul 2019 05:00:21 -0700 (PDT)"
        ],
        "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_MSPIKE_H3,\n\tRCVD_IN_MSPIKE_WL,\n\tT_DKIM_INVALID autolearn=unavailable autolearn_force=no\n\tversion=3.4.0",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=amarulasolutions.com; s=google;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references\n\t:mime-version:content-transfer-encoding;\n\tbh=VvWydEF9oVgUS+CUD5vS0LDJwAA7MW8cQAg1qTdiTb4=;\n\tb=HYCN8itOIv4g4ZqFy+CHi2/qIuKtDYdinzn5QWJAWtg/84cUS4ns+RQBc7sKoC+h4D\n\th6GOlDKBclg4ina23Ig2rX+yPfMoqlfsvZ/ell0ABkGubvq6s/50Si36U7jzQpPAj6z/\n\tFERxDkCGs0N6jaUB5DoDVYoVEewqhMy0t/TvM=",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to\n\t:references:mime-version:content-transfer-encoding;\n\tbh=VvWydEF9oVgUS+CUD5vS0LDJwAA7MW8cQAg1qTdiTb4=;\n\tb=CryT4N+bV1Kl412ZJF1p0j9opwYa+z4VAFe+2+TWA4T+xkG1YLbamiPxgRw/SbycQf\n\tYnaP2KSKasu8E3UHC+6gHiqEV9DgvLAgGqs7AuYhvEiD/wzBfoDgYzkXRkHbKOmN9ire\n\teHXf/iE6F2CG/4jSp0M2gbrgTtEExWsUObjMKU+AeNFQlAWm7iW8X74iccmgIbY5cjZc\n\tlzhW+WnCx1iL6waU28+wrSNEj2P7j08Y57x06nIalmMhWQz1maLdhsUVx/bsboAIi/nZ\n\t38BBeN9BrT4ngBxqIRbtM5kJuOlKdF8BsOK8RatiznaKtztVjSmYbH8Gy9AjI2Zb0ugs\n\tsAFw==",
        "X-Gm-Message-State": "APjAAAWLULHd/+S4ZN1JQ/l7dFLaREayniXOFUd3yzUtvkGXFcGJn+uu\n\tkkrkc7PaqtHWScfDugpYf976GQ==",
        "X-Google-Smtp-Source": "APXvYqwnlxRushycrvcvoxZlJp2IYOh7SaZegth4FifzAIwpaxWcxL90s9IHU2JRlw1e7WNDFsOw9g==",
        "X-Received": "by 2002:a17:902:f46:: with SMTP id\n\t64mr35065008ply.235.1563278422580; \n\tTue, 16 Jul 2019 05:00:22 -0700 (PDT)",
        "From": "Jagan Teki <jagan@amarulasolutions.com>",
        "To": "Simon Glass <sjg@chromium.org>,\n\tPhilipp Tomsich <philipp.tomsich@theobroma-systems.com>,\n\tKever Yang <kever.yang@rock-chips.com>,\n\tYouMin Chen <cym@rock-chips.com>, u-boot@lists.denx.de",
        "Date": "Tue, 16 Jul 2019 17:27:29 +0530",
        "Message-Id": "<20190716115745.12585-42-jagan@amarulasolutions.com>",
        "X-Mailer": "git-send-email 2.18.0.321.gffc6fa0e3",
        "In-Reply-To": "<20190716115745.12585-1-jagan@amarulasolutions.com>",
        "References": "<20190716115745.12585-1-jagan@amarulasolutions.com>",
        "MIME-Version": "1.0",
        "Cc": "linux-rockchip@lists.infradead.org, gajjar04akash@gmail.com,\n\tlinux-amarula@amarulasolutions.com,\n\tManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>",
        "Subject": "[U-Boot] [PATCH v3 41/57] ram: rk3399: Simplify data training first\n\targument",
        "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>",
        "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": "data training is using chan_info as first argument with\nchannel number as second argument instead of that use\ndram_info as first argument so-that we can get the\nchan_info at data training definition.\n\nThis was the argument handling is meaningful, readable\nand it would help to add similar data training for\nlpddr4 in future.\n\nSigned-off-by: Jagan Teki <jagan@amarulasolutions.com>\n---\n drivers/ram/rockchip/sdram_rk3399.c | 9 ++++-----\n 1 file changed, 4 insertions(+), 5 deletions(-)",
    "diff": "diff --git a/drivers/ram/rockchip/sdram_rk3399.c b/drivers/ram/rockchip/sdram_rk3399.c\nindex e3f1abf7e7..1aaaeb5b88 100644\n--- a/drivers/ram/rockchip/sdram_rk3399.c\n+++ b/drivers/ram/rockchip/sdram_rk3399.c\n@@ -1286,10 +1286,11 @@ static int data_training_wdql(const struct chan_info *chan, u32 channel,\n \treturn 0;\n }\n \n-static int data_training(const struct chan_info *chan, u32 channel,\n+static int data_training(struct dram_info *dram, u32 channel,\n \t\t\t const struct rk3399_sdram_params *params,\n \t\t\t u32 training_flag)\n {\n+\tstruct chan_info *chan = &dram->chan[channel];\n \tu32 *denali_phy = chan->publ->denali_phy;\n \tint ret;\n \n@@ -1498,8 +1499,7 @@ static int switch_to_phy_index1(struct dram_info *dram,\n \tfor (channel = 0; channel < ch_count; channel++) {\n \t\tdenali_phy = dram->chan[channel].publ->denali_phy;\n \t\tclrsetbits_le32(&denali_phy[896], (0x3 << 8) | 1, 1 << 8);\n-\t\tret = data_training(&dram->chan[channel], channel,\n-\t\t\t\t    params, PI_FULL_TRAINING);\n+\t\tret = data_training(dram, channel, params, PI_FULL_TRAINING);\n \t\tif (ret < 0) {\n \t\t\tdebug(\"index1 training failed\\n\");\n \t\t\treturn ret;\n@@ -1662,8 +1662,7 @@ static int sdram_init(struct dram_info *dram,\n \t\t\tif (params->base.dramtype == LPDDR3)\n \t\t\t\ttraining_flag |= PI_CA_TRAINING;\n \n-\t\t\tif (!(data_training(&dram->chan[ch], ch,\n-\t\t\t\t\t    params, training_flag)))\n+\t\t\tif (!(data_training(dram, ch, params, training_flag)))\n \t\t\t\tbreak;\n \t\t}\n \t\t/* Computed rank with associated channel number */\n",
    "prefixes": [
        "U-Boot",
        "v3",
        "41/57"
    ]
}