get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 848225,
    "url": "http://patchwork.ozlabs.org/api/patches/848225/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/20171212193130.5971-1-lyude@redhat.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": "<20171212193130.5971-1-lyude@redhat.com>",
    "list_archive_url": null,
    "date": "2017-12-12T19:31:30",
    "name": "[v3] igb: Free IRQs when device is hotplugged",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "79e8b4fb58fee1910a9dcb98c285227242e55a93",
    "submitter": {
        "id": 70744,
        "url": "http://patchwork.ozlabs.org/api/people/70744/?format=api",
        "name": "Lyude Paul",
        "email": "lyude@redhat.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/20171212193130.5971-1-lyude@redhat.com/mbox/",
    "series": [
        {
            "id": 18384,
            "url": "http://patchwork.ozlabs.org/api/series/18384/?format=api",
            "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=18384",
            "date": "2017-12-12T19:31:30",
            "name": "[v3] igb: Free IRQs when device is hotplugged",
            "version": 3,
            "mbox": "http://patchwork.ozlabs.org/series/18384/mbox/"
        }
    ],
    "comments": "http://patchwork.ozlabs.org/api/patches/848225/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/848225/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 3yxpBS096xz9sNr\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu, 14 Dec 2017 07:26:39 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby silver.osuosl.org (Postfix) with ESMTP id 5897330506;\n\tWed, 13 Dec 2017 20:26:37 +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 6GDez5jZ5erf; Wed, 13 Dec 2017 20:26:36 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby silver.osuosl.org (Postfix) with ESMTP id 13B8F2F068;\n\tWed, 13 Dec 2017 20:26:36 +0000 (UTC)",
            "from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137])\n\tby ash.osuosl.org (Postfix) with ESMTP id 64BA01BFDB4\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 12 Dec 2017 19:31:46 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby fraxinus.osuosl.org (Postfix) with ESMTP id 5DDB5870A3\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 12 Dec 2017 19:31:46 +0000 (UTC)",
            "from fraxinus.osuosl.org ([127.0.0.1])\n\tby localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024)\n\twith ESMTP id pk3WYc0yaFdj for <intel-wired-lan@lists.osuosl.org>;\n\tTue, 12 Dec 2017 19:31:44 +0000 (UTC)",
            "from mx1.redhat.com (mx1.redhat.com [209.132.183.28])\n\tby fraxinus.osuosl.org (Postfix) with ESMTPS id 19B0887072\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tTue, 12 Dec 2017 19:31:44 +0000 (UTC)",
            "from smtp.corp.redhat.com\n\t(int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13])\n\t(using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits))\n\t(No client certificate requested)\n\tby mx1.redhat.com (Postfix) with ESMTPS id 5C5D77E420;\n\tTue, 12 Dec 2017 19:31:43 +0000 (UTC)",
            "from whitewolf.lyude.net.com (ovpn-122-114.rdu2.redhat.com\n\t[10.10.122.114])\n\tby smtp.corp.redhat.com (Postfix) with ESMTP id E8FAE614C3;\n\tTue, 12 Dec 2017 19:31:38 +0000 (UTC)"
        ],
        "X-Virus-Scanned": [
            "amavisd-new at osuosl.org",
            "amavisd-new at osuosl.org"
        ],
        "X-Greylist": [
            "domain auto-whitelisted by SQLgrey-1.7.6",
            "Sender IP whitelisted, not delayed by milter-greylist-4.5.16\n\t(mx1.redhat.com [10.5.110.27]); Tue, 12 Dec 2017 19:31:43 +0000 (UTC)"
        ],
        "From": "Lyude Paul <lyude@redhat.com>",
        "To": "intel-wired-lan@lists.osuosl.org",
        "Date": "Tue, 12 Dec 2017 14:31:30 -0500",
        "Message-Id": "<20171212193130.5971-1-lyude@redhat.com>",
        "X-Scanned-By": "MIMEDefang 2.79 on 10.5.11.13",
        "X-Mailman-Approved-At": "Wed, 13 Dec 2017 20:26:34 +0000",
        "Subject": "[Intel-wired-lan] [PATCH v3] igb: Free IRQs when device is\n\thotplugged",
        "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>",
        "Cc": "netdev@vger.kernel.org, linux-kernel@vger.kernel.org,\n\tstable@vger.kernel.org, Stephen Hemminger <stephen@networkplumber.org>",
        "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": "Recently I got a Caldigit TS3 Thunderbolt 3 dock, and noticed that upon\nhotplugging my kernel would immediately crash due to igb:\n\n[  680.825801] kernel BUG at drivers/pci/msi.c:352!\n[  680.828388] invalid opcode: 0000 [#1] SMP\n[  680.829194] Modules linked in: igb(O) thunderbolt i2c_algo_bit joydev vfat fat btusb btrtl btbcm btintel bluetooth ecdh_generic hp_wmi sparse_keymap rfkill wmi_bmof iTCO_wdt intel_rapl x86_pkg_temp_thermal coretemp crc32_pclmul snd_pcm rtsx_pci_ms mei_me snd_timer memstick snd pcspkr mei soundcore i2c_i801 tpm_tis psmouse shpchp wmi tpm_tis_core tpm video hp_wireless acpi_pad rtsx_pci_sdmmc mmc_core crc32c_intel serio_raw rtsx_pci mfd_core xhci_pci xhci_hcd i2c_hid i2c_core [last unloaded: igb]\n[  680.831085] CPU: 1 PID: 78 Comm: kworker/u16:1 Tainted: G           O     4.15.0-rc3Lyude-Test+ #6\n[  680.831596] Hardware name: HP HP ZBook Studio G4/826B, BIOS P71 Ver. 01.03 06/09/2017\n[  680.832168] Workqueue: kacpi_hotplug acpi_hotplug_work_fn\n[  680.832687] RIP: 0010:free_msi_irqs+0x180/0x1b0\n[  680.833271] RSP: 0018:ffffc9000030fbf0 EFLAGS: 00010286\n[  680.833761] RAX: ffff8803405f9c00 RBX: ffff88033e3d2e40 RCX: 000000000000002c\n[  680.834278] RDX: 0000000000000000 RSI: 00000000000000ac RDI: ffff880340be2178\n[  680.834832] RBP: 0000000000000000 R08: ffff880340be1ff0 R09: ffff8803405f9c00\n[  680.835342] R10: 0000000000000000 R11: 0000000000000040 R12: ffff88033d63a298\n[  680.835822] R13: ffff88033d63a000 R14: 0000000000000060 R15: ffff880341959000\n[  680.836332] FS:  0000000000000000(0000) GS:ffff88034f440000(0000) knlGS:0000000000000000\n[  680.836817] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033\n[  680.837360] CR2: 000055e64044afdf CR3: 0000000001c09002 CR4: 00000000003606e0\n[  680.837954] Call Trace:\n[  680.838853]  pci_disable_msix+0xce/0xf0\n[  680.839616]  igb_reset_interrupt_capability+0x5d/0x60 [igb]\n[  680.840278]  igb_remove+0x9d/0x110 [igb]\n[  680.840764]  pci_device_remove+0x36/0xb0\n[  680.841279]  device_release_driver_internal+0x157/0x220\n[  680.841739]  pci_stop_bus_device+0x7d/0xa0\n[  680.842255]  pci_stop_bus_device+0x2b/0xa0\n[  680.842722]  pci_stop_bus_device+0x3d/0xa0\n[  680.843189]  pci_stop_and_remove_bus_device+0xe/0x20\n[  680.843627]  trim_stale_devices+0xf3/0x140\n[  680.844086]  trim_stale_devices+0x94/0x140\n[  680.844532]  trim_stale_devices+0xa6/0x140\n[  680.845031]  ? get_slot_status+0x90/0xc0\n[  680.845536]  acpiphp_check_bridge.part.5+0xfe/0x140\n[  680.846021]  acpiphp_hotplug_notify+0x175/0x200\n[  680.846581]  ? free_bridge+0x100/0x100\n[  680.847113]  acpi_device_hotplug+0x8a/0x490\n[  680.847535]  acpi_hotplug_work_fn+0x1a/0x30\n[  680.848076]  process_one_work+0x182/0x3a0\n[  680.848543]  worker_thread+0x2e/0x380\n[  680.848963]  ? process_one_work+0x3a0/0x3a0\n[  680.849373]  kthread+0x111/0x130\n[  680.849776]  ? kthread_create_worker_on_cpu+0x50/0x50\n[  680.850188]  ret_from_fork+0x1f/0x30\n[  680.850601] Code: 43 14 85 c0 0f 84 d5 fe ff ff 31 ed eb 0f 83 c5 01 39 6b 14 0f 86 c5 fe ff ff 8b 7b 10 01 ef e8 b7 e4 d2 ff 48 83 78 70 00 74 e3 <0f> 0b 49 8d b5 a0 00 00 00 e8 62 6f d3 ff e9 c7 fe ff ff 48 8b\n[  680.851497] RIP: free_msi_irqs+0x180/0x1b0 RSP: ffffc9000030fbf0\n\nAs it turns out, normally the freeing of IRQs that would fix this is called\ninside of the scope of __igb_close(). However, since the device is\nalready gone by the point we try to unregister the netdevice from the\ndriver due to a hotplug we end up seeing that the netif isn't present\nand thus, forget to free any of the device IRQs.\n\nSo: make sure that if we're in the process of dismantling the netdev, we\nalways allow __igb_close() to be called so that IRQs may be freed\nnormally. Additionally, only allow igb_close() to be called from\n__igb_close() if it hasn't already been called for the given adapter.\n\nSigned-off-by: Lyude Paul <lyude@redhat.com>\nFixes: 9474933caf21 (\"igb: close/suspend race in netif_device_detach\")\nCc: Todd Fujinaka <todd.fujinaka@intel.com>\nCc: Stephen Hemminger <stephen@networkplumber.org>\nCc: stable@vger.kernel.org\n---\nChanges since v2:\n  - Remove hunk in __igb_close() that was left over by accident, it's\n    not needed\n\n drivers/net/ethernet/intel/igb/igb_main.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/igb/igb_main.c b/drivers/net/ethernet/intel/igb/igb_main.c\nindex c208753ff5b7..c69a5b3ae8c8 100644\n--- a/drivers/net/ethernet/intel/igb/igb_main.c\n+++ b/drivers/net/ethernet/intel/igb/igb_main.c\n@@ -3676,7 +3676,7 @@ static int __igb_close(struct net_device *netdev, bool suspending)\n \n int igb_close(struct net_device *netdev)\n {\n-\tif (netif_device_present(netdev))\n+\tif (netif_device_present(netdev) || netdev->dismantle)\n \t\treturn __igb_close(netdev, false);\n \treturn 0;\n }\n",
    "prefixes": [
        "v3"
    ]
}