get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 860160,
    "url": "http://patchwork.ozlabs.org/api/patches/860160/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20180112193251.11739-2-jeffrey.t.kirsher@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": "<20180112193251.11739-2-jeffrey.t.kirsher@intel.com>",
    "list_archive_url": null,
    "date": "2018-01-12T19:32:41",
    "name": "[02/12] virtchnl: Add virtchl structures to support queue channels",
    "commit_ref": null,
    "pull_url": null,
    "state": "superseded",
    "archived": false,
    "hash": "c6ddc01d98eeec5981fe24afcf13ab8df584fcc1",
    "submitter": {
        "id": 473,
        "url": "http://patchwork.ozlabs.org/api/people/473/?format=api",
        "name": "Kirsher, Jeffrey T",
        "email": "jeffrey.t.kirsher@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/20180112193251.11739-2-jeffrey.t.kirsher@intel.com/mbox/",
    "series": [
        {
            "id": 23043,
            "url": "http://patchwork.ozlabs.org/api/series/23043/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=23043",
            "date": "2018-01-12T19:32:45",
            "name": "[01/12] i40evf: Fix link up issue when queues are disabled",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/23043/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/860160/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/860160/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<intel-wired-lan-bounces@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"
        ],
        "Authentication-Results": "ozlabs.org;\n\tspf=pass (mailfrom) smtp.mailfrom=osuosl.org\n\t(client-ip=140.211.166.136; helo=silver.osuosl.org;\n\tenvelope-from=intel-wired-lan-bounces@osuosl.org;\n\treceiver=<UNKNOWN>)",
        "Received": [
            "from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136])\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 3zJCZb33W6z9sQm\n\tfor <incoming@patchwork.ozlabs.org>;\n\tSat, 13 Jan 2018 06:32:55 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id B463624792;\n\tFri, 12 Jan 2018 19:32:53 +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 JeRdrAoZP7BU; Fri, 12 Jan 2018 19:32:52 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby silver.osuosl.org (Postfix) with ESMTP id 06A862C9A9;\n\tFri, 12 Jan 2018 19:32:52 +0000 (UTC)",
            "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id BBD131C002D\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 Jan 2018 19:32:49 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id B82C889EF7\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 Jan 2018 19:32:49 +0000 (UTC)",
            "from hemlock.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id tgTO9pgo5C55 for <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 Jan 2018 19:32:48 +0000 (UTC)",
            "from mga02.intel.com (mga02.intel.com [134.134.136.20])\n\tby hemlock.osuosl.org (Postfix) with ESMTPS id 8BEA289EF8\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tFri, 12 Jan 2018 19:32:48 +0000 (UTC)",
            "from orsmga003.jf.intel.com ([10.7.209.27])\n\tby orsmga101.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384;\n\t12 Jan 2018 11:32:47 -0800",
            "from jtkirshe-nuc.jf.intel.com ([134.134.177.151])\n\tby orsmga003.jf.intel.com with ESMTP; 12 Jan 2018 11:32:47 -0800"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6",
        "X-Amp-Result": "SKIPPED(no attachment in message)",
        "X-Amp-File-Uploaded": "False",
        "X-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.46,350,1511856000\"; d=\"scan'208\";a=\"19654865\"",
        "From": "Jeff Kirsher <jeffrey.t.kirsher@intel.com>",
        "To": "intel-wired-lan@lists.osuosl.org",
        "Date": "Fri, 12 Jan 2018 11:32:41 -0800",
        "Message-Id": "<20180112193251.11739-2-jeffrey.t.kirsher@intel.com>",
        "X-Mailer": "git-send-email 2.14.3",
        "In-Reply-To": "<20180112193251.11739-1-jeffrey.t.kirsher@intel.com>",
        "References": "<20180112193251.11739-1-jeffrey.t.kirsher@intel.com>",
        "Subject": "[Intel-wired-lan] [PATCH 02/12] virtchnl: Add virtchl structures to\n\tsupport queue channels",
        "X-BeenThere": "intel-wired-lan@osuosl.org",
        "X-Mailman-Version": "2.1.24",
        "Precedence": "list",
        "List-Id": "Intel Wired Ethernet Linux Kernel Driver Development\n\t<intel-wired-lan.osuosl.org>",
        "List-Unsubscribe": "<https://lists.osuosl.org/mailman/options/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@osuosl.org?subject=unsubscribe>",
        "List-Archive": "<http://lists.osuosl.org/pipermail/intel-wired-lan/>",
        "List-Post": "<mailto:intel-wired-lan@osuosl.org>",
        "List-Help": "<mailto:intel-wired-lan-request@osuosl.org?subject=help>",
        "List-Subscribe": "<https://lists.osuosl.org/mailman/listinfo/intel-wired-lan>, \n\t<mailto:intel-wired-lan-request@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@osuosl.org",
        "Sender": "\"Intel-wired-lan\" <intel-wired-lan-bounces@osuosl.org>"
    },
    "content": "From: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com>\n\nThis patch defines new structs in support of the virtchannel message\nthat the VF sends to the PF to create a queue channel specified by the\nuser via tc tool.\n\nSigned-off-by: Harshitha Ramamurthy <harshitha.ramamurthy@intel.com>\n---\n include/linux/avf/virtchnl.h | 39 +++++++++++++++++++++++++++++++++++++++\n 1 file changed, 39 insertions(+)",
    "diff": "diff --git a/include/linux/avf/virtchnl.h b/include/linux/avf/virtchnl.h\nindex 3ce61342fa31..b6aaecd82c70 100644\n--- a/include/linux/avf/virtchnl.h\n+++ b/include/linux/avf/virtchnl.h\n@@ -136,6 +136,8 @@ enum virtchnl_ops {\n \tVIRTCHNL_OP_ENABLE_VLAN_STRIPPING = 27,\n \tVIRTCHNL_OP_DISABLE_VLAN_STRIPPING = 28,\n \tVIRTCHNL_OP_REQUEST_QUEUES = 29,\n+\tVIRTCHNL_OP_ENABLE_CHANNELS = 30,\n+\tVIRTCHNL_OP_DISABLE_CHANNELS = 31,\n };\n \n /* This macro is used to generate a compilation error if a structure\n@@ -244,6 +246,7 @@ VIRTCHNL_CHECK_STRUCT_LEN(16, virtchnl_vsi_resource);\n #define VIRTCHNL_VF_OFFLOAD_ENCAP\t\t0X00100000\n #define VIRTCHNL_VF_OFFLOAD_ENCAP_CSUM\t\t0X00200000\n #define VIRTCHNL_VF_OFFLOAD_RX_ENCAP_CSUM\t0X00400000\n+#define VIRTCHNL_VF_OFFLOAD_ADQ\t\t\t0X00800000\n \n #define VF_BASE_MODE_OFFLOADS (VIRTCHNL_VF_OFFLOAD_L2 | \\\n \t\t\t       VIRTCHNL_VF_OFFLOAD_VLAN | \\\n@@ -496,6 +499,29 @@ struct virtchnl_rss_hena {\n \n VIRTCHNL_CHECK_STRUCT_LEN(8, virtchnl_rss_hena);\n \n+/* VIRTCHNL_OP_ENABLE_CHANNELS\n+ * VIRTCHNL_OP_DISABLE_CHANNELS\n+ * VF sends these messages to enable or disable channels based on\n+ * the user specified queue count and queue offset for each traffic class.\n+ * This struct encompasses all the information that the PF needs from\n+ * VF to create a channel.\n+ */\n+struct virtchnl_channel_info {\n+\tu16 count; /* number of queues in a channel */\n+\tu16 offset; /* queues in a channel start from 'offset' */\n+\tu32 pad;\n+\tu64 max_tx_rate;\n+};\n+\n+VIRTCHNL_CHECK_STRUCT_LEN(16, virtchnl_channel_info);\n+\n+struct virtchnl_tc_info {\n+\tu32\tnum_tc;\n+\tstruct\tvirtchnl_channel_info list[1];\n+};\n+\n+VIRTCHNL_CHECK_STRUCT_LEN(24, virtchnl_tc_info);\n+\n /* VIRTCHNL_OP_EVENT\n  * PF sends this message to inform the VF driver of events that may affect it.\n  * No direct response is expected from the VF, though it may generate other\n@@ -711,6 +737,19 @@ virtchnl_vc_validate_vf_msg(struct virtchnl_version_info *ver, u32 v_opcode,\n \tcase VIRTCHNL_OP_REQUEST_QUEUES:\n \t\tvalid_len = sizeof(struct virtchnl_vf_res_request);\n \t\tbreak;\n+\tcase VIRTCHNL_OP_ENABLE_CHANNELS:\n+\t\tvalid_len = sizeof(struct virtchnl_tc_info);\n+\t\tif (msglen >= valid_len) {\n+\t\t\tstruct virtchnl_tc_info *vti =\n+\t\t\t\t(struct virtchnl_tc_info *)msg;\n+\t\t\tvalid_len += vti->num_tc *\n+\t\t\t\tsizeof(struct virtchnl_channel_info);\n+\t\t\tif (vti->num_tc == 0)\n+\t\t\t\terr_msg_format = true;\n+\t\t}\n+\t\tbreak;\n+\tcase VIRTCHNL_OP_DISABLE_CHANNELS:\n+\t\tbreak;\n \t/* These are always errors coming from the VF. */\n \tcase VIRTCHNL_OP_EVENT:\n \tcase VIRTCHNL_OP_UNKNOWN:\n",
    "prefixes": [
        "02/12"
    ]
}