get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 686801,
    "url": "http://patchwork.ozlabs.org/api/patches/686801/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1477436933-13679-3-git-send-email-bimmy.pujari@intel.com/",
    "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": "<1477436933-13679-3-git-send-email-bimmy.pujari@intel.com>",
    "list_archive_url": null,
    "date": "2016-10-25T23:08:47",
    "name": "[next,S51-V2,2/8] i40evf: Be much more verbose about what we can and cannot offload",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "4b34dbba66e56eb9ca5e074728c31065a15d5928",
    "submitter": {
        "id": 68919,
        "url": "http://patchwork.ozlabs.org/api/people/68919/?format=api",
        "name": "Pujari, Bimmy",
        "email": "bimmy.pujari@intel.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/1477436933-13679-3-git-send-email-bimmy.pujari@intel.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/686801/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/686801/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 3t3TQf0YCmz9sCZ\n\tfor <incoming@patchwork.ozlabs.org>;\n\tWed, 26 Oct 2016 10:10:33 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 66DEC92043;\n\tTue, 25 Oct 2016 23:10:32 +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 O5es-H6-b+LG; Tue, 25 Oct 2016 23:10:30 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id F335991FCA;\n\tTue, 25 Oct 2016 23:10:29 +0000 (UTC)",
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\n\tby ash.osuosl.org (Postfix) with ESMTP id B563F1CF861\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 25 Oct 2016 23:10:26 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 9912631B5A\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 25 Oct 2016 23:10:26 +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 FazQvDrhMsPc for <intel-wired-lan@lists.osuosl.org>;\n\tTue, 25 Oct 2016 23:10:23 +0000 (UTC)",
            "from mga05.intel.com (mga05.intel.com [192.55.52.43])\n\tby silver.osuosl.org (Postfix) with ESMTPS id 0AB4931C47\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 25 Oct 2016 23:10:23 +0000 (UTC)",
            "from fmsmga006.fm.intel.com ([10.253.24.20])\n\tby fmsmga105.fm.intel.com with ESMTP; 25 Oct 2016 16:10:22 -0700",
            "from bimmy.jf.intel.com (HELO bimmy.linux1.jf.intel.com)\n\t([134.134.2.167])\n\tby fmsmga006.fm.intel.com with ESMTP; 25 Oct 2016 16:10:22 -0700"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.31,399,1473145200\"; d=\"scan'208\";a=\"23607170\"",
        "From": "Bimmy Pujari <bimmy.pujari@intel.com>",
        "To": "intel-wired-lan@lists.osuosl.org",
        "Date": "Tue, 25 Oct 2016 16:08:47 -0700",
        "Message-Id": "<1477436933-13679-3-git-send-email-bimmy.pujari@intel.com>",
        "X-Mailer": "git-send-email 2.4.11",
        "In-Reply-To": "<1477436933-13679-1-git-send-email-bimmy.pujari@intel.com>",
        "References": "<1477436933-13679-1-git-send-email-bimmy.pujari@intel.com>",
        "Subject": "[Intel-wired-lan] [next PATCH S51-V2 2/8] i40evf: Be much more\n\tverbose about what we can and cannot offload",
        "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>",
        "MIME-Version": "1.0",
        "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\nThis change makes it so that we are much more robust about defining what we\ncan and cannot offload.  Previously we were performing no checks.  This\nshould bring us up to parity with the i40e PF driver.\n\nIn addition the device only supports GSO as long as the MSS is 64 or\ngreater.  We were not checking this so an MSS less than that was resulting\nin Tx hangs.\n\nSigned-off-by: Alexander Duyck <alexander.h.duyck@intel.com>\nChange-ID: If533553ec92fc6ba694eab6ac81fdaf3004f3592\n---\nTesting Hints:\n        This is half of the fix needed to address MSS less than 64.  This\n        is the fix for upstream and kernels after 3.18.4, but we will need\n        to come up with a separate fix for out-of-tree that can be stripped\n        on kernels prior to 3.18.4.\n\n        An easy test for this patch is to just set the MTU for an interface\n        to a value 102.  Without this patch we should see Tx hangs with\n        netperf and with we should be able to pass traffic without\n        triggering Tx hangs.\n\n drivers/net/ethernet/intel/i40evf/i40evf_main.c | 59 +++++++++++++++++++++++++\n 1 file changed, 59 insertions(+)",
    "diff": "diff --git a/drivers/net/ethernet/intel/i40evf/i40evf_main.c b/drivers/net/ethernet/intel/i40evf/i40evf_main.c\nindex db36744..7bbb55f 100644\n--- a/drivers/net/ethernet/intel/i40evf/i40evf_main.c\n+++ b/drivers/net/ethernet/intel/i40evf/i40evf_main.c\n@@ -2172,6 +2172,64 @@ static int i40evf_change_mtu(struct net_device *netdev, int new_mtu)\n \treturn 0;\n }\n \n+/**\n+ * i40evf_features_check - Validate encapsulated packet conforms to limits\n+ * @skb: skb buff\n+ * @netdev: This physical port's netdev\n+ * @features: Offload features that the stack believes apply\n+ **/\n+static netdev_features_t i40evf_features_check(struct sk_buff *skb,\n+\t\t\t\t\t       struct net_device *dev,\n+\t\t\t\t\t       netdev_features_t features)\n+{\n+\tsize_t len;\n+\n+\t/* No point in doing any of this if neither checksum nor GSO are\n+\t * being requested for this frame.  We can rule out both by just\n+\t * checking for CHECKSUM_PARTIAL\n+\t */\n+\tif (skb->ip_summed != CHECKSUM_PARTIAL)\n+\t\treturn features;\n+\n+\t/* We cannot support GSO if the MSS is going to be less than\n+\t * 64 bytes.  If it is then we need to drop support for GSO.\n+\t */\n+\tif (skb_is_gso(skb) && (skb_shinfo(skb)->gso_size < 64))\n+\t\tfeatures &= ~NETIF_F_GSO_MASK;\n+\n+\t/* MACLEN can support at most 63 words */\n+\tlen = skb_network_header(skb) - skb->data;\n+\tif (len & ~(63 * 2))\n+\t\tgoto out_err;\n+\n+\t/* IPLEN and EIPLEN can support at most 127 dwords */\n+\tlen = skb_transport_header(skb) - skb_network_header(skb);\n+\tif (len & ~(127 * 4))\n+\t\tgoto out_err;\n+\n+\tif (skb->encapsulation) {\n+\t\t/* L4TUNLEN can support 127 words */\n+\t\tlen = skb_inner_network_header(skb) - skb_transport_header(skb);\n+\t\tif (len & ~(127 * 2))\n+\t\t\tgoto out_err;\n+\n+\t\t/* IPLEN can support at most 127 dwords */\n+\t\tlen = skb_inner_transport_header(skb) -\n+\t\t      skb_inner_network_header(skb);\n+\t\tif (len & ~(127 * 4))\n+\t\t\tgoto out_err;\n+\t}\n+\n+\t/* No need to validate L4LEN as TCP is the only protocol with a\n+\t * a flexible value and we support all possible values supported\n+\t * by TCP, which is at most 15 dwords\n+\t */\n+\n+\treturn features;\n+out_err:\n+\treturn features & ~(NETIF_F_CSUM_MASK | NETIF_F_GSO_MASK);\n+}\n+\n #define I40EVF_VLAN_FEATURES (NETIF_F_HW_VLAN_CTAG_TX |\\\n \t\t\t      NETIF_F_HW_VLAN_CTAG_RX |\\\n \t\t\t      NETIF_F_HW_VLAN_CTAG_FILTER)\n@@ -2206,6 +2264,7 @@ static const struct net_device_ops i40evf_netdev_ops = {\n \t.ndo_tx_timeout\t\t= i40evf_tx_timeout,\n \t.ndo_vlan_rx_add_vid\t= i40evf_vlan_rx_add_vid,\n \t.ndo_vlan_rx_kill_vid\t= i40evf_vlan_rx_kill_vid,\n+\t.ndo_features_check\t= i40evf_features_check,\n \t.ndo_fix_features\t= i40evf_fix_features,\n #ifdef CONFIG_NET_POLL_CONTROLLER\n \t.ndo_poll_controller\t= i40evf_netpoll,\n",
    "prefixes": [
        "next",
        "S51-V2",
        "2/8"
    ]
}