get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 811354,
    "url": "http://patchwork.ozlabs.org/api/patches/811354/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/netdev/patch/20170908071156.5115-9-clabbe.montjoie@gmail.com/",
    "project": {
        "id": 7,
        "url": "http://patchwork.ozlabs.org/api/projects/7/?format=api",
        "name": "Linux network development",
        "link_name": "netdev",
        "list_id": "netdev.vger.kernel.org",
        "list_email": "netdev@vger.kernel.org",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170908071156.5115-9-clabbe.montjoie@gmail.com>",
    "list_archive_url": null,
    "date": "2017-09-08T07:11:54",
    "name": "[v5,08/10] net: stmmac: dwmac-sun8i: choose internal PHY via phy-is-integrated",
    "commit_ref": null,
    "pull_url": null,
    "state": "changes-requested",
    "archived": true,
    "hash": "e170bc5d3e3a33cce4f726ca2446ccb921e0ccf5",
    "submitter": {
        "id": 64152,
        "url": "http://patchwork.ozlabs.org/api/people/64152/?format=api",
        "name": "Corentin Labbe",
        "email": "clabbe.montjoie@gmail.com"
    },
    "delegate": {
        "id": 34,
        "url": "http://patchwork.ozlabs.org/api/users/34/?format=api",
        "username": "davem",
        "first_name": "David",
        "last_name": "Miller",
        "email": "davem@davemloft.net"
    },
    "mbox": "http://patchwork.ozlabs.org/project/netdev/patch/20170908071156.5115-9-clabbe.montjoie@gmail.com/mbox/",
    "series": [
        {
            "id": 2114,
            "url": "http://patchwork.ozlabs.org/api/series/2114/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/netdev/list/?series=2114",
            "date": "2017-09-08T07:11:56",
            "name": "net: stmmac: dwmac-sun8i: Handle integrated PHY",
            "version": 5,
            "mbox": "http://patchwork.ozlabs.org/series/2114/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/811354/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/811354/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<netdev-owner@vger.kernel.org>",
        "X-Original-To": "patchwork-incoming@ozlabs.org",
        "Delivered-To": "patchwork-incoming@ozlabs.org",
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=vger.kernel.org\n\t(client-ip=209.132.180.67; helo=vger.kernel.org;\n\tenvelope-from=netdev-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org; dkim=pass (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"Gx4ouKee\"; dkim-atps=neutral"
        ],
        "Received": [
            "from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 3xpTB14hzjz9s83\n\tfor <patchwork-incoming@ozlabs.org>;\n\tFri,  8 Sep 2017 17:15:37 +1000 (AEST)",
            "(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1755564AbdIHHPX (ORCPT <rfc822;patchwork-incoming@ozlabs.org>);\n\tFri, 8 Sep 2017 03:15:23 -0400",
            "from mail-wr0-f193.google.com ([209.85.128.193]:34824 \"EHLO\n\tmail-wr0-f193.google.com\" rhost-flags-OK-OK-OK-OK) by vger.kernel.org\n\twith ESMTP id S1755013AbdIHHOS (ORCPT\n\t<rfc822;netdev@vger.kernel.org>); Fri, 8 Sep 2017 03:14:18 -0400",
            "by mail-wr0-f193.google.com with SMTP id n64so827750wrb.2;\n\tFri, 08 Sep 2017 00:14:17 -0700 (PDT)",
            "from Red.local (LFbn-MAR-1-580-96.w90-118.abo.wanadoo.fr.\n\t[90.118.159.96]) by smtp.googlemail.com with ESMTPSA id\n\tl19sm684566wrl.47.2017.09.08.00.14.15\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128);\n\tFri, 08 Sep 2017 00:14:16 -0700 (PDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=gmail.com; s=20161025;\n\th=from:to:cc:subject:date:message-id:in-reply-to:references;\n\tbh=ZDRqn6oM7YLvC7qyulEsdiG4u/Ek3wP9CmcxSAqe5YU=;\n\tb=Gx4ouKee8qpfDta/NQS+KDkCr3DdnR0+9lBqzs1mdm3BIcpndYniu6+jzWsAjimDK2\n\tEyvd9B3c6pYir9Bse7MePflJgU5ZgiSzyrO3jEOtmXBFewx9kHEU1Ac2fn5XLT5VYHca\n\tk6HIu0WEJT3Sf9RaWsk8m3cNIAV1yzhisNcE3IrXBfJ5hx9SLZPB3vRsZagM5kBvX3dX\n\ty5PQiEI9ezTL5qn2QXjFc6kBFZ7j0huzVGVo/Vrlg2YLTWf/hsAFRu2WgLNYZAFbLcn6\n\t52l2LAZoDCRl1KoYdYY+QYXQ2visBB0CeFae8/+riZPF8g4Al4BazBfFvQZdGlcWCt5R\n\t9xZg==",
        "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;\n\tbh=ZDRqn6oM7YLvC7qyulEsdiG4u/Ek3wP9CmcxSAqe5YU=;\n\tb=rusEi4w0C+VQAHXHA3bkpm84RZu4VXj5Jg61Ozn3a0jn6frsZYXKdV8wr0JxS7W14v\n\tXcrgK54/oqWXYABf0vrYQFRvrya9ySGnrXexU7OKtaGoHYigfGCyNEExRWKlI8Kmb7LY\n\tplFQXAQjqPea4olnuhJ++bi8Op5ig7fOFRjWz10dKwixuM87qBI3RCq8Ho+szcs1InJM\n\txMVBP1i9BuVbBmikdHyPR85mBpgfPAf9qALV90ufAOz/H+bKcX8HeArbCf3j/QP3fLYW\n\te2ZAU5bAVkAZ8G1dXpFsHG763daoxrp/hOdWWBDpnDRQpktO1hK5G4hnd7gqc/ZKvD3t\n\tEEXA==",
        "X-Gm-Message-State": "AHPjjUgVAsVxznQd3pnduLIGb8QyTGqkauv2XCDPHClqdDjTvc92FCqA\n\tBZyp0cNFv6A0/A==",
        "X-Google-Smtp-Source": "ADKCNb4z3ywIzIXc17DTrY3eRhgS7GdHnwPgPow+b3AipK3o/03OM+48frHpnpawGXI+zweKmE+84Q==",
        "X-Received": "by 10.223.130.77 with SMTP id 71mr1178456wrb.247.1504854856643; \n\tFri, 08 Sep 2017 00:14:16 -0700 (PDT)",
        "From": "Corentin Labbe <clabbe.montjoie@gmail.com>",
        "To": "robh+dt@kernel.org, mark.rutland@arm.com,\n\tmaxime.ripard@free-electrons.com, wens@csie.org,\n\tlinux@armlinux.org.uk, catalin.marinas@arm.com,\n\twill.deacon@arm.com, peppe.cavallaro@st.com,\n\talexandre.torgue@st.com, andrew@lunn.ch, f.fainelli@gmail.com",
        "Cc": "netdev@vger.kernel.org, devicetree@vger.kernel.org,\n\tlinux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org,\n\tCorentin Labbe <clabbe.montjoie@gmail.com>",
        "Subject": "[PATCH v5 08/10] net: stmmac: dwmac-sun8i: choose internal PHY via\n\tphy-is-integrated",
        "Date": "Fri,  8 Sep 2017 09:11:54 +0200",
        "Message-Id": "<20170908071156.5115-9-clabbe.montjoie@gmail.com>",
        "X-Mailer": "git-send-email 2.13.5",
        "In-Reply-To": "<20170908071156.5115-1-clabbe.montjoie@gmail.com>",
        "References": "<20170908071156.5115-1-clabbe.montjoie@gmail.com>",
        "Sender": "netdev-owner@vger.kernel.org",
        "Precedence": "bulk",
        "List-ID": "<netdev.vger.kernel.org>",
        "X-Mailing-List": "netdev@vger.kernel.org"
    },
    "content": "The current way to find if the phy is internal is to compare DT phy-mode\nand emac_variant/internal_phy.\nBut it will negate a possible future SoC where an external PHY use the\nsame phy mode than the internal one.\n\nThis patch adds a new way to find if the PHY is internal, via\nthe phy-is-integrated property.\n\nSince the internal_phy variable does not need anymore to contain the xMII mode\nused by the internal PHY, it is still used for knowing the presence of an\ninternal PHY, so it is modified to a boolean soc_has_internal_phy.\n\nSigned-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>\nAcked-by: Chen-Yu Tsai <wens@csie.org>\nReviewed-by: Florian Fainelli <f.fainelli@gmail.com>\n---\n drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 16 ++++++++--------\n 1 file changed, 8 insertions(+), 8 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c\nindex fffd6d5fc907..672553b652bd 100644\n--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c\n+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c\n@@ -41,14 +41,14 @@\n  *\t\t\t\tThis value is used for disabling properly EMAC\n  *\t\t\t\tand used as a good starting value in case of the\n  *\t\t\t\tboot process(uboot) leave some stuff.\n- * @internal_phy:\t\tDoes the MAC embed an internal PHY\n+ * @soc_has_internal_phy:\tDoes the MAC embed an internal PHY\n  * @support_mii:\t\tDoes the MAC handle MII\n  * @support_rmii:\t\tDoes the MAC handle RMII\n  * @support_rgmii:\t\tDoes the MAC handle RGMII\n  */\n struct emac_variant {\n \tu32 default_syscon_value;\n-\tint internal_phy;\n+\tbool soc_has_internal_phy;\n \tbool support_mii;\n \tbool support_rmii;\n \tbool support_rgmii;\n@@ -75,7 +75,7 @@ struct sunxi_priv_data {\n \n static const struct emac_variant emac_variant_h3 = {\n \t.default_syscon_value = 0x58000,\n-\t.internal_phy = PHY_INTERFACE_MODE_MII,\n+\t.soc_has_internal_phy = true,\n \t.support_mii = true,\n \t.support_rmii = true,\n \t.support_rgmii = true\n@@ -83,20 +83,20 @@ static const struct emac_variant emac_variant_h3 = {\n \n static const struct emac_variant emac_variant_v3s = {\n \t.default_syscon_value = 0x38000,\n-\t.internal_phy = PHY_INTERFACE_MODE_MII,\n+\t.soc_has_internal_phy = true,\n \t.support_mii = true\n };\n \n static const struct emac_variant emac_variant_a83t = {\n \t.default_syscon_value = 0,\n-\t.internal_phy = 0,\n+\t.soc_has_internal_phy = false,\n \t.support_mii = true,\n \t.support_rgmii = true\n };\n \n static const struct emac_variant emac_variant_a64 = {\n \t.default_syscon_value = 0,\n-\t.internal_phy = 0,\n+\t.soc_has_internal_phy = false,\n \t.support_mii = true,\n \t.support_rmii = true,\n \t.support_rgmii = true\n@@ -648,7 +648,7 @@ static int sun8i_dwmac_set_syscon(struct stmmac_priv *priv)\n \t\t\t \"Current syscon value is not the default %x (expect %x)\\n\",\n \t\t\t val, reg);\n \n-\tif (gmac->variant->internal_phy) {\n+\tif (gmac->variant->soc_has_internal_phy) {\n \t\tif (!gmac->use_internal_phy) {\n \t\t\t/* switch to external PHY interface */\n \t\t\treg &= ~H3_EPHY_SELECT;\n@@ -932,7 +932,7 @@ static int sun8i_dwmac_probe(struct platform_device *pdev)\n \t}\n \n \tplat_dat->interface = of_get_phy_mode(dev->of_node);\n-\tif (plat_dat->interface == gmac->variant->internal_phy) {\n+\tif (of_property_read_bool(plat_dat->phy_node, \"phy-is-integrated\")) {\n \t\tdev_info(&pdev->dev, \"Will use internal PHY\\n\");\n \t\tgmac->use_internal_phy = true;\n \t\tgmac->ephy_clk = of_clk_get(plat_dat->phy_node, 0);\n",
    "prefixes": [
        "v5",
        "08/10"
    ]
}