get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 711994,
    "url": "http://patchwork.ozlabs.org/api/patches/711994/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20170106161119.2030.32664.stgit@localhost.localdomain/",
    "project": {
        "id": 46,
        "url": "http://patchwork.ozlabs.org/api/projects/46/?format=api",
        "name": "Intel Wired Ethernet development",
        "link_name": "intel-wired-lan",
        "list_id": "intel-wired-lan.osuosl.org",
        "list_email": "intel-wired-lan@osuosl.org",
        "web_url": "",
        "scm_url": "",
        "webscm_url": "",
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170106161119.2030.32664.stgit@localhost.localdomain>",
    "list_archive_url": null,
    "date": "2017-01-06T16:11:19",
    "name": "[next,7/9] igb: Add support for ethtool private flag to allow use of legacy Rx",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "d3e51d72ee8da6a569855da69bc4ed1af25e0ad9",
    "submitter": {
        "id": 252,
        "url": "http://patchwork.ozlabs.org/api/people/252/?format=api",
        "name": "Alexander Duyck",
        "email": "alexander.duyck@gmail.com"
    },
    "delegate": {
        "id": 68,
        "url": "http://patchwork.ozlabs.org/api/users/68/?format=api",
        "username": "jtkirshe",
        "first_name": "Jeff",
        "last_name": "Kirsher",
        "email": "jeffrey.t.kirsher@intel.com"
    },
    "mbox": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20170106161119.2030.32664.stgit@localhost.localdomain/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/711994/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/711994/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<intel-wired-lan-bounces@lists.osuosl.org>",
        "X-Original-To": [
            "incoming@patchwork.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Delivered-To": [
            "patchwork-incoming@bilbo.ozlabs.org",
            "intel-wired-lan@lists.osuosl.org"
        ],
        "Received": [
            "from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby ozlabs.org (Postfix) with ESMTPS id 3tw8gK0hq0z9sXx\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat,  7 Jan 2017 03:11:25 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id A097887070;\n\tFri,  6 Jan 2017 16:11:23 +0000 (UTC)",
            "from whitealder.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id hEExjcdyKc-B; Fri,  6 Jan 2017 16:11:22 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id A2686820CE;\n\tFri,  6 Jan 2017 16:11:22 +0000 (UTC)",
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n\tby ash.osuosl.org (Postfix) with ESMTP id 72E2E1BFA57\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  6 Jan 2017 16:11:21 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 6E7B02A0DE\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  6 Jan 2017 16:11:21 +0000 (UTC)",
            "from silver.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id bv8TBX3jrzb7 for <intel-wired-lan@lists.osuosl.org>;\n\tFri,  6 Jan 2017 16:11:20 +0000 (UTC)",
            "from mail-pf0-f196.google.com (mail-pf0-f196.google.com\n\t[209.85.192.196])\n\tby silver.osuosl.org (Postfix) with ESMTPS id A356F27329\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri,  6 Jan 2017 16:11:20 +0000 (UTC)",
            "by mail-pf0-f196.google.com with SMTP id 127so20185479pfg.0\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 06 Jan 2017 08:11:20 -0800 (PST)",
            "from localhost.localdomain ([2001:470:b:9c3:9e5c:8eff:fe4f:f2d0])\n\tby smtp.gmail.com with ESMTPSA id\n\tz9sm162544785pge.44.2017.01.06.08.11.19\n\t(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);\n\tFri, 06 Jan 2017 08:11:19 -0800 (PST)"
        ],
        "Authentication-Results": "ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n\tunprotected) header.d=gmail.com header.i=@gmail.com\n\theader.b=\"CUg3EW7S\"; dkim-atps=neutral",
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;\n\th=subject:from:to:date:message-id:in-reply-to:references:user-agent\n\t:mime-version:content-transfer-encoding;\n\tbh=G3wFZU+8wY/9rdlLwnCtmhiTAUV9a3KmNOWIEFVKwa8=;\n\tb=CUg3EW7S2q7TXr3U9K5rTALMJ42Zrr9n7N5BpOvRZMNRooa9J4mzO6MCGCCQCjZMyo\n\t78IM5gj/pEz1VuQmDcbxDGfUsT2rK26ziFRHXO2NoJUUDD1DNclW+Z/IAc64rORrzW5a\n\tudmb9tbdaCT81jnuErRk/FAN9ef1OQQqrSyGjsVNscVrqbjF6/c4wlv0OLUujEFerS7Q\n\tpmVBw7fHVyjVjZJ39nv52IHGDkHyYp1sG1d3gQLtzsxSQWfGr9w3zCgfQC2ONrLtLrNc\n\tojvccTMVS5z/2AjgqPK5udIleQMlf3rrD000xWxDdIh7IcPFng4VInguAeLSuAy7v2cD\n\tJCMg==",
        "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20161025;\n\th=x-gm-message-state:subject:from:to:date:message-id:in-reply-to\n\t:references:user-agent:mime-version:content-transfer-encoding;\n\tbh=G3wFZU+8wY/9rdlLwnCtmhiTAUV9a3KmNOWIEFVKwa8=;\n\tb=umYkhEt86Rrv8/oB0fMiMgQ73WFWTasp6WQiaMLW3reRzRc+vKDz/igaFZEufpLk4m\n\tRyGO8e2lFCa/T5QtzbtCMRAbWnKn9DVJ1cRqKfEX03SpumP1F0N9r45K1k4O1FQoPprC\n\tNyFBqNpZjGEcJy6RapC/TNLopTnvtQxFvhLDTuwsWmStN3c5tc3fHSTXTNvFMPHrf2YX\n\tSayhrXRvLh+jKuD0Pxjf3I6tleOnxh0ac5RZ43dR4batDTCjagO3r0UmtA3+GGgsRMVN\n\txHr7W9k+w3/lhRtN/ToQYmJsFH+8fcjEfo9enRx1y8SV3uJHJ8455XvPb1t+uLoOkqid\n\trfnA==",
        "X-Gm-Message-State": "AIkVDXKUsYEO2TKkQSv/Bi406FOocBwg5WFfQaXdlUOIiTP0zrNnPu4S3yW8ITmIuLydEA==",
        "X-Received": "by 10.98.10.3 with SMTP id s3mr72133645pfi.78.1483719080329;\n\tFri, 06 Jan 2017 08:11:20 -0800 (PST)",
        "From": "Alexander Duyck <alexander.duyck@gmail.com>",
        "To": "intel-wired-lan@lists.osuosl.org, jeffrey.t.kirsher@intel.com",
        "Date": "Fri, 06 Jan 2017 08:11:19 -0800",
        "Message-ID": "<20170106161119.2030.32664.stgit@localhost.localdomain>",
        "In-Reply-To": "<20170106160850.2030.39073.stgit@localhost.localdomain>",
        "References": "<20170106160850.2030.39073.stgit@localhost.localdomain>",
        "User-Agent": "StGit/0.17.1-dirty",
        "MIME-Version": "1.0",
        "Subject": "[Intel-wired-lan] [next PATCH 7/9] igb: Add support for ethtool\n\tprivate flag to allow use of legacy Rx",
        "X-BeenThere": "intel-wired-lan@lists.osuosl.org",
        "X-Mailman-Version": "2.1.18-1",
        "Precedence": "list",
        "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.lists.osuosl.org>",
        "List-Unsubscribe": "<http://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.osuosl.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>",
        "List-Post": "<mailto:intel-wired-lan@lists.osuosl.org>",
        "List-Help": "<mailto:intel-wired-lan-request@lists.osuosl.org?subject=help>",
        "List-Subscribe": "<http://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@lists.osuosl.org?subject=subscribe>",
        "Content-Type": "text/plain; charset=\"us-ascii\"",
        "Content-Transfer-Encoding": "7bit",
        "Errors-To": "intel-wired-lan-bounces@lists.osuosl.org",
        "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@lists.osuosl.org>"
    },
    "content": "From: Alexander Duyck <alexander.h.duyck@intel.com>\n\nSince there are potential drawbacks to the new Rx allocation approach I\nthought it best to add a \"chicken bit\" so that we can turn the feature off\nif in the event that a problem is found.\n\nIt also provides a means of validating the legacy Rx path in the event that\nwe are forced to fall back.  At some point in the future when we are\nconvinced we don't need it anymore we might be able to drop the legacy-rx\nflag.\n\nSigned-off-by: Alexander Duyck <alexander.h.duyck@intel.com>\n---\n drivers/net/ethernet/intel/igb/igb_ethtool.c |   48 ++++++++++++++++++++++++++\n 1 file changed, 48 insertions(+)",
    "diff": "diff --git a/drivers/net/ethernet/intel/igb/igb_ethtool.c b/drivers/net/ethernet/intel/igb/igb_ethtool.c\nindex 3a845cc613a8..bec8a48a5045 100644\n--- a/drivers/net/ethernet/intel/igb/igb_ethtool.c\n+++ b/drivers/net/ethernet/intel/igb/igb_ethtool.c\n@@ -144,6 +144,13 @@ enum igb_diagnostics_results {\n };\n #define IGB_TEST_LEN (sizeof(igb_gstrings_test) / ETH_GSTRING_LEN)\n \n+static const char igb_priv_flags_strings[][ETH_GSTRING_LEN] = {\n+#define IGB_PRIV_FLAGS_LEGACY_RX\tBIT(0)\n+\t\"legacy-rx\",\n+};\n+\n+#define IGB_PRIV_FLAGS_STR_LEN ARRAY_SIZE(igb_priv_flags_strings)\n+\n static int igb_get_settings(struct net_device *netdev, struct ethtool_cmd *ecmd)\n {\n \tstruct igb_adapter *adapter = netdev_priv(netdev);\n@@ -852,6 +859,8 @@ static void igb_get_drvinfo(struct net_device *netdev,\n \t\tsizeof(drvinfo->fw_version));\n \tstrlcpy(drvinfo->bus_info, pci_name(adapter->pdev),\n \t\tsizeof(drvinfo->bus_info));\n+\n+\tdrvinfo->n_priv_flags = IGB_PRIV_FLAGS_STR_LEN;\n }\n \n static void igb_get_ringparam(struct net_device *netdev,\n@@ -2280,6 +2289,8 @@ static int igb_get_sset_count(struct net_device *netdev, int sset)\n \t\treturn IGB_STATS_LEN;\n \tcase ETH_SS_TEST:\n \t\treturn IGB_TEST_LEN;\n+\tcase ETH_SS_PRIV_FLAGS:\n+\t\treturn IGB_PRIV_FLAGS_STR_LEN;\n \tdefault:\n \t\treturn -ENOTSUPP;\n \t}\n@@ -2385,6 +2396,10 @@ static void igb_get_strings(struct net_device *netdev, u32 stringset, u8 *data)\n \t\t}\n \t\t/* BUG_ON(p - data != IGB_STATS_LEN * ETH_GSTRING_LEN); */\n \t\tbreak;\n+\tcase ETH_SS_PRIV_FLAGS:\n+\t\tmemcpy(data, igb_priv_flags_strings,\n+\t\t       IGB_PRIV_FLAGS_STR_LEN * ETH_GSTRING_LEN);\n+\t\tbreak;\n \t}\n }\n \n@@ -3397,6 +3412,37 @@ static int igb_set_channels(struct net_device *netdev,\n \treturn 0;\n }\n \n+static u32 igb_get_priv_flags(struct net_device *netdev)\n+{\n+\tstruct igb_adapter *adapter = netdev_priv(netdev);\n+\tu32 priv_flags = 0;\n+\n+\tif (adapter->flags & IGB_FLAG_RX_LEGACY)\n+\t\tpriv_flags |= IGB_PRIV_FLAGS_LEGACY_RX;\n+\n+\treturn priv_flags;\n+}\n+\n+static int igb_set_priv_flags(struct net_device *netdev, u32 priv_flags)\n+{\n+\tstruct igb_adapter *adapter = netdev_priv(netdev);\n+\tunsigned int flags = adapter->flags;\n+\n+\tflags &= ~IGB_FLAG_RX_LEGACY;\n+\tif (priv_flags & IGB_PRIV_FLAGS_LEGACY_RX)\n+\t\tflags |= IGB_FLAG_RX_LEGACY;\n+\n+\tif (flags != adapter->flags) {\n+\t\tadapter->flags = flags;\n+\n+\t\t/* reset interface to repopulate queues */\n+\t\tif (netif_running(netdev))\n+\t\t\tigb_reinit_locked(adapter);\n+\t}\n+\n+\treturn 0;\n+}\n+\n static const struct ethtool_ops igb_ethtool_ops = {\n \t.get_settings\t\t= igb_get_settings,\n \t.set_settings\t\t= igb_set_settings,\n@@ -3435,6 +3481,8 @@ static int igb_set_channels(struct net_device *netdev,\n \t.set_rxfh\t\t= igb_set_rxfh,\n \t.get_channels\t\t= igb_get_channels,\n \t.set_channels\t\t= igb_set_channels,\n+\t.get_priv_flags\t\t= igb_get_priv_flags,\n+\t.set_priv_flags\t\t= igb_set_priv_flags,\n \t.begin\t\t\t= igb_ethtool_begin,\n \t.complete\t\t= igb_ethtool_complete,\n };\n",
    "prefixes": [
        "next",
        "7/9"
    ]
}