get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 811596,
    "url": "http://patchwork.ozlabs.org/api/patches/811596/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/ubuntu-kernel/patch/5aeca0bb01c843b4bb2335385e842403386a2fa9.1504636892.git.joseph.salisbury@canonical.com/",
    "project": {
        "id": 15,
        "url": "http://patchwork.ozlabs.org/api/projects/15/?format=api",
        "name": "Ubuntu Kernel",
        "link_name": "ubuntu-kernel",
        "list_id": "kernel-team.lists.ubuntu.com",
        "list_email": "kernel-team@lists.ubuntu.com",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<5aeca0bb01c843b4bb2335385e842403386a2fa9.1504636892.git.joseph.salisbury@canonical.com>",
    "list_archive_url": null,
    "date": "2017-09-08T13:38:42",
    "name": "[SRU,Zesty,2/2] PCI: Disable VF decoding before pcibios_sriov_disable() updates resources",
    "commit_ref": null,
    "pull_url": null,
    "state": "new",
    "archived": false,
    "hash": "9d85709bad9c5fc8fce9a1bd7169fc44fb55c0c0",
    "submitter": {
        "id": 7793,
        "url": "http://patchwork.ozlabs.org/api/people/7793/?format=api",
        "name": "Joseph Salisbury",
        "email": "joseph.salisbury@canonical.com"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/ubuntu-kernel/patch/5aeca0bb01c843b4bb2335385e842403386a2fa9.1504636892.git.joseph.salisbury@canonical.com/mbox/",
    "series": [
        {
            "id": 2215,
            "url": "http://patchwork.ozlabs.org/api/series/2215/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/ubuntu-kernel/list/?series=2215",
            "date": "2017-09-08T13:38:42",
            "name": "Fixes for LP:1715073",
            "version": 1,
            "mbox": "http://patchwork.ozlabs.org/series/2215/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/811596/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/811596/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<kernel-team-bounces@lists.ubuntu.com>",
        "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.ubuntu.com\n\t(client-ip=91.189.94.19; helo=huckleberry.canonical.com;\n\tenvelope-from=kernel-team-bounces@lists.ubuntu.com;\n\treceiver=<UNKNOWN>)",
        "Received": [
            "from huckleberry.canonical.com (huckleberry.canonical.com\n\t[91.189.94.19])\n\tby ozlabs.org (Postfix) with ESMTP id 3xpdh8525Lz9s8J;\n\tFri,  8 Sep 2017 23:38:48 +1000 (AEST)",
            "from localhost ([127.0.0.1] helo=huckleberry.canonical.com)\n\tby huckleberry.canonical.com with esmtp (Exim 4.86_2)\n\t(envelope-from <kernel-team-bounces@lists.ubuntu.com>)\n\tid 1dqJUb-0006X2-L2; Fri, 08 Sep 2017 13:38:45 +0000",
            "from youngberry.canonical.com ([91.189.89.112])\n\tby huckleberry.canonical.com with esmtps\n\t(TLS1.0:DHE_RSA_AES_128_CBC_SHA1:128)\n\t(Exim 4.86_2) (envelope-from <joseph.salisbury@canonical.com>)\n\tid 1dqJUZ-0006W8-Dx\n\tfor kernel-team@lists.ubuntu.com; Fri, 08 Sep 2017 13:38:43 +0000",
            "from 1.general.jsalisbury.us.vpn ([10.172.67.212] helo=salisbury)\n\tby youngberry.canonical.com with esmtpsa\n\t(TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)\n\t(Exim 4.76) (envelope-from <joseph.salisbury@canonical.com>)\n\tid 1dqJUZ-00054b-3S\n\tfor kernel-team@lists.ubuntu.com; Fri, 08 Sep 2017 13:38:43 +0000",
            "by salisbury (Postfix, from userid 1000)\n\tid 2100F7E00D8; Fri,  8 Sep 2017 09:38:42 -0400 (EDT)"
        ],
        "From": "Joseph Salisbury <joseph.salisbury@canonical.com>",
        "To": "kernel-team@lists.ubuntu.com",
        "Subject": "[SRU][Zesty][PATCH 2/2] [PATCH] PCI: Disable VF decoding before\n\tpcibios_sriov_disable() updates resources",
        "Date": "Fri,  8 Sep 2017 09:38:42 -0400",
        "Message-Id": "<5aeca0bb01c843b4bb2335385e842403386a2fa9.1504636892.git.joseph.salisbury@canonical.com>",
        "X-Mailer": "git-send-email 2.7.4",
        "In-Reply-To": [
            "<cover.1504636892.git.joseph.salisbury@canonical.com>",
            "<cover.1504636892.git.joseph.salisbury@canonical.com>"
        ],
        "References": [
            "<cover.1504636892.git.joseph.salisbury@canonical.com>",
            "<cover.1504636892.git.joseph.salisbury@canonical.com>"
        ],
        "X-BeenThere": "kernel-team@lists.ubuntu.com",
        "X-Mailman-Version": "2.1.20",
        "Precedence": "list",
        "List-Id": "Kernel team discussions <kernel-team.lists.ubuntu.com>",
        "List-Unsubscribe": "<https://lists.ubuntu.com/mailman/options/kernel-team>,\n\t<mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe>",
        "List-Archive": "<https://lists.ubuntu.com/archives/kernel-team>",
        "List-Post": "<mailto:kernel-team@lists.ubuntu.com>",
        "List-Help": "<mailto:kernel-team-request@lists.ubuntu.com?subject=help>",
        "List-Subscribe": "<https://lists.ubuntu.com/mailman/listinfo/kernel-team>,\n\t<mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=\"utf-8\"",
        "Content-Transfer-Encoding": "base64",
        "Errors-To": "kernel-team-bounces@lists.ubuntu.com",
        "Sender": "\"kernel-team\" <kernel-team-bounces@lists.ubuntu.com>"
    },
    "content": "From: Gavin Shan <gwshan@linux.vnet.ibm.com>\n\nA struct resource represents the address space consumed by a device.  We\nshould not modify that resource while the device is actively using the\naddress space.  For VFs, pci_iov_update_resource() enforces this by\nprinting a warning and doing nothing if the VFE (VF Enable) and MSE (VF\nMemory Space Enable) bits are set.\n\nPreviously, both sriov_enable() and sriov_disable() called the\npcibios_sriov_disable() arch hook, which may update the struct resource,\nwhile VFE and MSE were enabled.  This effectively dropped the resource\nupdate pcibios_sriov_disable() intended to do.\n\nDisable VF memory decoding before calling pcibios_sriov_disable().\n\nReported-by: Carol L Soto <clsoto@us.ibm.com>\nTested-by: Carol L Soto <clsoto@us.ibm.com>\nSigned-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>\nSigned-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>\n[bhelgaas: changelog]\nSigned-off-by: Bjorn Helgaas <bhelgaas@google.com>\nCc: shan.gavin@gmail.com\nCc: Benjamin Herrenschmidt <benh@kernel.crashing.org>\nCc: Paul Mackerras <paulus@samba.org>\n(cherry picked from linux-next commit 0fc690a7c3f7053613dcbab6a7613bb6586d8ee2)\nSigned-off-by: Joseph Salisbury <joseph.salisbury@canonical.com>\n---\n drivers/pci/iov.c | 7 ++++---\n 1 file changed, 4 insertions(+), 3 deletions(-)",
    "diff": "diff --git a/drivers/pci/iov.c b/drivers/pci/iov.c\nindex 2479ae8..138830f 100644\n--- a/drivers/pci/iov.c\n+++ b/drivers/pci/iov.c\n@@ -331,7 +331,6 @@ static int sriov_enable(struct pci_dev *dev, int nr_virtfn)\n \twhile (i--)\n \t\tpci_iov_remove_virtfn(dev, i, 0);\n \n-\tpcibios_sriov_disable(dev);\n err_pcibios:\n \tiov->ctrl &= ~(PCI_SRIOV_CTRL_VFE | PCI_SRIOV_CTRL_MSE);\n \tpci_cfg_access_lock(dev);\n@@ -339,6 +338,8 @@ static int sriov_enable(struct pci_dev *dev, int nr_virtfn)\n \tssleep(1);\n \tpci_cfg_access_unlock(dev);\n \n+\tpcibios_sriov_disable(dev);\n+\n \tif (iov->link != dev->devfn)\n \t\tsysfs_remove_link(&dev->dev.kobj, \"dep_link\");\n \n@@ -357,14 +358,14 @@ static void sriov_disable(struct pci_dev *dev)\n \tfor (i = 0; i < iov->num_VFs; i++)\n \t\tpci_iov_remove_virtfn(dev, i, 0);\n \n-\tpcibios_sriov_disable(dev);\n-\n \tiov->ctrl &= ~(PCI_SRIOV_CTRL_VFE | PCI_SRIOV_CTRL_MSE);\n \tpci_cfg_access_lock(dev);\n \tpci_write_config_word(dev, iov->pos + PCI_SRIOV_CTRL, iov->ctrl);\n \tssleep(1);\n \tpci_cfg_access_unlock(dev);\n \n+\tpcibios_sriov_disable(dev);\n+\n \tif (iov->link != dev->devfn)\n \t\tsysfs_remove_link(&dev->dev.kobj, \"dep_link\");\n \n",
    "prefixes": [
        "SRU",
        "Zesty",
        "2/2"
    ]
}