get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

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

{
    "id": 579080,
    "url": "http://patchwork.ozlabs.org/api/patches/579080/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1454611679-17424-2-git-send-email-jacob.e.keller@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": "<1454611679-17424-2-git-send-email-jacob.e.keller@intel.com>",
    "list_archive_url": null,
    "date": "2016-02-04T18:47:55",
    "name": "[2/6] fm10k: don't initialize service task until later in probe",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": false,
    "hash": "ceb5ccfdb1edcdd4f73d53c7327d5d9311fee6ae",
    "submitter": {
        "id": 9784,
        "url": "http://patchwork.ozlabs.org/api/people/9784/?format=api",
        "name": "Jacob Keller",
        "email": "jacob.e.keller@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/1454611679-17424-2-git-send-email-jacob.e.keller@intel.com/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/579080/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/579080/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\tby ozlabs.org (Postfix) with ESMTP id CCE4B140C04\n\tfor <incoming@patchwork.ozlabs.org>;\n\tFri,  5 Feb 2016 05:48:35 +1100 (AEDT)",
            "from localhost (localhost [127.0.0.1])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 2786D9226C;\n\tThu,  4 Feb 2016 18:48:35 +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 K2ZxzfD-+Qzg; Thu,  4 Feb 2016 18:48:33 +0000 (UTC)",
            "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby whitealder.osuosl.org (Postfix) with ESMTP id 3C209922E2;\n\tThu,  4 Feb 2016 18:48:33 +0000 (UTC)",
            "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id 091A21C0FC2\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  4 Feb 2016 18:48:31 +0000 (UTC)",
            "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 03CB595694\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  4 Feb 2016 18:48:31 +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 H7bMQ89gED3Z for <intel-wired-lan@lists.osuosl.org>;\n\tThu,  4 Feb 2016 18:48:27 +0000 (UTC)",
            "from mga11.intel.com (mga11.intel.com [192.55.52.93])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 3AC8F9569A\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tThu,  4 Feb 2016 18:48:27 +0000 (UTC)",
            "from fmsmga001.fm.intel.com ([10.253.24.23])\n\tby fmsmga102.fm.intel.com with ESMTP; 04 Feb 2016 10:48:26 -0800",
            "from jekeller-desk.amr.corp.intel.com (HELO\n\tjekeller-desk.jekeller.internal) ([134.134.3.65])\n\tby fmsmga001.fm.intel.com with ESMTP; 04 Feb 2016 10:48:27 -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-ExtLoop1": "1",
        "X-IronPort-AV": "E=Sophos;i=\"5.22,396,1449561600\"; d=\"scan'208\";a=\"896511418\"",
        "From": "Jacob Keller <jacob.e.keller@intel.com>",
        "To": "Intel Wired LAN <intel-wired-lan@lists.osuosl.org>",
        "Date": "Thu,  4 Feb 2016 10:47:55 -0800",
        "Message-Id": "<1454611679-17424-2-git-send-email-jacob.e.keller@intel.com>",
        "X-Mailer": "git-send-email 2.7.0.236.gda096a0.dirty",
        "In-Reply-To": "<1454611679-17424-1-git-send-email-jacob.e.keller@intel.com>",
        "References": "<1454611679-17424-1-git-send-email-jacob.e.keller@intel.com>",
        "Subject": "[Intel-wired-lan] [PATCH 2/6] fm10k: don't initialize service task\n\tuntil later in probe",
        "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": "delay initialization of the service timer and service task until late\nprobe. If we don't wait, failures in probe do not properly cleanup the\nservice timer or service task items, which results in the kernel panic\nbelow, potentially freezing the whole system. In addition, ensure that\nthe SERVICE_DISABLE bit is set before we request the mbx irq since the\nmbx interrupt attempts to schedule the service task otherwise. This\nprevents a similar trace from occurring after this change.\n\nWe didn't notice this issue before because probe almost always completes\nsuccessfully. I discovered it due to a mis-ordered mailbox handler\narray, which resulted in the following failure when requesting mailbox\ninterrupt.\n\n[  555.325619] ------------[ cut here ]------------\n[  555.325628] WARNING: CPU: 0 PID: 4941 at lib/list_debug.c:33 __list_add+0xa0/0xd0()\n[  555.325631] list_add corruption. prev->next should be next (ffffffff81f46648), but was           (null). (prev=ffff8807fad5d0e8).\n<snip>\n[  555.325722] CPU: 0 PID: 4941 Comm: insmod Tainted: G           OE   4.0.4-303.fc22.x86_64 #1\n[  555.325725] Hardware name: Intel Corporation S2600CO/S2600CO, BIOS SE5C600.86B.02.03.8x23.060520140825 06/05/2014\n[  555.325727]  0000000000000000 00000000b4f161b3 ffff88081a21f8e8 ffffffff81783124\n[  555.325734]  0000000000000000 ffff88081a21f940 ffff88081a21f928 ffffffff8109c66a\n[  555.325740]  0000000064000000 ffff8807fad5d0e8 ffff8807fad5d0e8 ffffffff81f46648\n[  555.325746] Call Trace:\n[  555.325752]  [<ffffffff81783124>] dump_stack+0x45/0x57\n[  555.325757]  [<ffffffff8109c66a>] warn_slowpath_common+0x8a/0xc0\n[  555.325759]  [<ffffffff8109c6f5>] warn_slowpath_fmt+0x55/0x70\n[  555.325763]  [<ffffffff813ba270>] __list_add+0xa0/0xd0\n[  555.325768]  [<ffffffff81102d1d>] __internal_add_timer+0x9d/0x110\n[  555.325771]  [<ffffffff81102dbf>] internal_add_timer+0x2f/0xc0\n[  555.325774]  [<ffffffff81104e5a>] mod_timer+0x12a/0x230\n[  555.325782]  [<ffffffffa03d54ca>] fm10k_probe+0x69a/0xc80 [fm10k]\n[  555.325787]  [<ffffffff813e8355>] local_pci_probe+0x45/0xa0\n[  555.325791]  [<ffffffff8129cf42>] ? sysfs_do_create_link_sd.isra.2+0x72/0xc0\n[  555.325794]  [<ffffffff813e96b9>] pci_device_probe+0xf9/0x150\n[  555.325799]  [<ffffffff814d7e73>] driver_probe_device+0xa3/0x400\n[  555.325802]  [<ffffffff814d82ab>] __driver_attach+0x9b/0xa0\n[  555.325805]  [<ffffffff814d8210>] ? __device_attach+0x40/0x40\n[  555.325808]  [<ffffffff814d5bd3>] bus_for_each_dev+0x73/0xc0\n[  555.325811]  [<ffffffff814d78ce>] driver_attach+0x1e/0x20\n[  555.325815]  [<ffffffff814d7480>] bus_add_driver+0x180/0x250\n[  555.325819]  [<ffffffffa03b2000>] ? 0xffffffffa03b2000\n[  555.325823]  [<ffffffff814d8aa4>] driver_register+0x64/0xf0\n[  555.325826]  [<ffffffff813e7bec>] __pci_register_driver+0x4c/0x50\n[  555.325832]  [<ffffffffa03d6ca3>] fm10k_register_pci_driver+0x23/0x30 [fm10k]\n[  555.325838]  [<ffffffffa03b2080>] fm10k_init_module+0x80/0x1000 [fm10k]\n[  555.325843]  [<ffffffff81002128>] do_one_initcall+0xb8/0x200\n[  555.325848]  [<ffffffff811e10d2>] ? __vunmap+0xa2/0x100\n[  555.325852]  [<ffffffff811fe239>] ? kmem_cache_alloc_trace+0x1b9/0x240\n[  555.325855]  [<ffffffff8178230e>] ? do_init_module+0x28/0x1cb\n[  555.325858]  [<ffffffff81782346>] do_init_module+0x60/0x1cb\n[  555.325862]  [<ffffffff8112168e>] load_module+0x205e/0x26b0\n[  555.325866]  [<ffffffff8111d110>] ? store_uevent+0x70/0x70\n[  555.325870]  [<ffffffff812234b0>] ? kernel_read+0x50/0x80\n[  555.325873]  [<ffffffff81121f3e>] SyS_finit_module+0xbe/0xf0\n[  555.325878]  [<ffffffff81789749>] system_call_fastpath+0x12/0x17\n[  555.325880] ---[ end trace 9e0f58d071eafd2a ]---\n\nSigned-off-by: Jacob Keller <jacob.e.keller@intel.com>\n---\n drivers/net/ethernet/intel/fm10k/fm10k_pci.c | 25 ++++++++++++++++---------\n 1 file changed, 16 insertions(+), 9 deletions(-)",
    "diff": "diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_pci.c b/drivers/net/ethernet/intel/fm10k/fm10k_pci.c\nindex 8c23fb3df572..ed1f8cf39508 100644\n--- a/drivers/net/ethernet/intel/fm10k/fm10k_pci.c\n+++ b/drivers/net/ethernet/intel/fm10k/fm10k_pci.c\n@@ -1795,15 +1795,6 @@ static int fm10k_sw_init(struct fm10k_intfc *interface,\n \t/* initialize DCBNL interface */\n \tfm10k_dcbnl_set_ops(netdev);\n \n-\t/* Initialize service timer and service task */\n-\tset_bit(__FM10K_SERVICE_DISABLE, &interface->state);\n-\tsetup_timer(&interface->service_timer, &fm10k_service_timer,\n-\t\t    (unsigned long)interface);\n-\tINIT_WORK(&interface->service_task, fm10k_service_task);\n-\n-\t/* kick off service timer now, even when interface is down */\n-\tmod_timer(&interface->service_timer, (HZ * 2) + jiffies);\n-\n \t/* Intitialize timestamp data */\n \tfm10k_ts_init(interface);\n \n@@ -1989,6 +1980,12 @@ static int fm10k_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \tif (err)\n \t\tgoto err_sw_init;\n \n+\t/* the mbx interrupt might attempt to schedule the service task, so we\n+\t * must ensure it is disabled since we haven't yet requested the timer\n+\t * or work item.\n+\t */\n+\tset_bit(__FM10K_SERVICE_DISABLE, &interface->state);\n+\n \terr = fm10k_mbx_request_irq(interface);\n \tif (err)\n \t\tgoto err_mbx_interrupt;\n@@ -2008,6 +2005,16 @@ static int fm10k_probe(struct pci_dev *pdev, const struct pci_device_id *ent)\n \t/* stop all the transmit queues from transmitting until link is up */\n \tnetif_tx_stop_all_queues(netdev);\n \n+\t/* Initialize service timer and service task late in order to avoid\n+\t * cleanup issues.\n+\t */\n+\tsetup_timer(&interface->service_timer, &fm10k_service_timer,\n+\t\t    (unsigned long)interface);\n+\tINIT_WORK(&interface->service_task, fm10k_service_task);\n+\n+\t/* kick off service timer now, even when interface is down */\n+\tmod_timer(&interface->service_timer, (HZ * 2) + jiffies);\n+\n \t/* Register PTP interface */\n \tfm10k_ptp_register(interface);\n \n",
    "prefixes": [
        "2/6"
    ]
}