Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/907695/?format=api
{ "id": 907695, "url": "http://patchwork.ozlabs.org/api/patches/907695/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/patch/1525292788-22260-1-git-send-email-maurosr@linux.vnet.ibm.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": "<1525292788-22260-1-git-send-email-maurosr@linux.vnet.ibm.com>", "list_archive_url": null, "date": "2018-05-02T20:26:28", "name": "[v3] ixgbe/ixgbevf: Free IRQ when PCI error recovery removes the device", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "9ba7638ed77ef7a0ae1c9c59291bc47ae7b3debf", "submitter": { "id": 71608, "url": "http://patchwork.ozlabs.org/api/people/71608/?format=api", "name": "Mauro S. M. Rodrigues", "email": "maurosr@linux.vnet.ibm.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/1525292788-22260-1-git-send-email-maurosr@linux.vnet.ibm.com/mbox/", "series": [ { "id": 42194, "url": "http://patchwork.ozlabs.org/api/series/42194/?format=api", "web_url": "http://patchwork.ozlabs.org/project/intel-wired-lan/list/?series=42194", "date": "2018-05-02T20:26:28", "name": "[v3] ixgbe/ixgbevf: Free IRQ when PCI error recovery removes the device", "version": 3, "mbox": "http://patchwork.ozlabs.org/series/42194/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/907695/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/907695/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.133; helo=hemlock.osuosl.org;\n\tenvelope-from=intel-wired-lan-bounces@osuosl.org;\n\treceiver=<UNKNOWN>)", "ozlabs.org; dmarc=none (p=none dis=none)\n\theader.from=linux.vnet.ibm.com" ], "Received": [ "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\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 40bqZ31P2Dz9s27\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu, 3 May 2018 06:26:49 +1000 (AEST)", "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 01FC487C68;\n\tWed, 2 May 2018 20:26:48 +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 ch6LMxL2CHbW; Wed, 2 May 2018 20:26:47 +0000 (UTC)", "from ash.osuosl.org (ash.osuosl.org [140.211.166.34])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 7F455895A4;\n\tWed, 2 May 2018 20:26:47 +0000 (UTC)", "from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133])\n\tby ash.osuosl.org (Postfix) with ESMTP id A28711C3F93\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tWed, 2 May 2018 20:26:46 +0000 (UTC)", "from localhost (localhost [127.0.0.1])\n\tby hemlock.osuosl.org (Postfix) with ESMTP id 9F0D987CB2\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tWed, 2 May 2018 20:26:46 +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 tXKBo7e3EcVi for <intel-wired-lan@lists.osuosl.org>;\n\tWed, 2 May 2018 20:26:45 +0000 (UTC)", "from mx0a-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com\n\t[148.163.158.5])\n\tby hemlock.osuosl.org (Postfix) with ESMTPS id 7115087C68\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tWed, 2 May 2018 20:26:45 +0000 (UTC)", "from pps.filterd (m0098419.ppops.net [127.0.0.1])\n\tby mx0b-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id\n\tw42KO5Ld033942\n\tfor <intel-wired-lan@lists.osuosl.org>; Wed, 2 May 2018 16:26:44 -0400", "from e17.ny.us.ibm.com (e17.ny.us.ibm.com [129.33.205.207])\n\tby mx0b-001b2d01.pphosted.com with ESMTP id 2hqjs3knad-1\n\t(version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT)\n\tfor <intel-wired-lan@lists.osuosl.org>;\n\tWed, 02 May 2018 16:26:44 -0400", "from localhost\n\tby e17.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use\n\tOnly! Violators will be prosecuted\n\tfor <intel-wired-lan@lists.osuosl.org> from\n\t<maurosr@linux.vnet.ibm.com>; Wed, 2 May 2018 16:26:43 -0400", "from b01cxnp23034.gho.pok.ibm.com (9.57.198.29)\n\tby e17.ny.us.ibm.com (146.89.104.204) with IBM ESMTP SMTP Gateway:\n\tAuthorized Use Only! Violators will be prosecuted; \n\tWed, 2 May 2018 16:26:40 -0400", "from b01ledav005.gho.pok.ibm.com (b01ledav005.gho.pok.ibm.com\n\t[9.57.199.110])\n\tby b01cxnp23034.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP\n\tid w42KQdIW51773690; Wed, 2 May 2018 20:26:39 GMT", "from b01ledav005.gho.pok.ibm.com (unknown [127.0.0.1])\n\tby IMSVA (Postfix) with ESMTP id C8513AE05C;\n\tWed, 2 May 2018 16:28:33 -0400 (EDT)", "from localhost (unknown [9.18.239.64])\n\tby b01ledav005.gho.pok.ibm.com (Postfix) with ESMTP id A5F4EAE056;\n\tWed, 2 May 2018 16:28:33 -0400 (EDT)" ], "X-Virus-Scanned": [ "amavisd-new at osuosl.org", "amavisd-new at osuosl.org" ], "X-Greylist": "domain auto-whitelisted by SQLgrey-1.7.6", "From": "\"Mauro S. M. Rodrigues\" <maurosr@linux.vnet.ibm.com>", "To": "jeffrey.t.kirsher@intel.com, intel-wired-lan@lists.osuosl.org,\n\talexander.duyck@gmail.com", "Date": "Wed, 2 May 2018 17:26:28 -0300", "X-Mailer": "git-send-email 2.7.4", "X-TM-AS-GCONF": "00", "x-cbid": "18050220-0040-0000-0000-000004256EBE", "X-IBM-SpamModules-Scores": "", "X-IBM-SpamModules-Versions": "BY=3.00008959; HX=3.00000241; KW=3.00000007;\n\tPH=3.00000004; SC=3.00000258; SDB=6.01026564; UDB=6.00524312;\n\tIPR=6.00805755; \n\tMB=3.00020894; MTD=3.00000008; XFM=3.00000015; UTC=2018-05-02 20:26:41", "X-IBM-AV-DETECTION": "SAVI=unused REMOTE=unused XFE=unused", "x-cbparentid": "18050220-0041-0000-0000-0000082B7671", "Message-Id": "<1525292788-22260-1-git-send-email-maurosr@linux.vnet.ibm.com>", "X-Proofpoint-Virus-Version": "vendor=fsecure engine=2.50.10434:, ,\n\tdefinitions=2018-05-02_07:, , signatures=0", "X-Proofpoint-Spam-Details": "rule=outbound_notspam policy=outbound score=0\n\tpriorityscore=1501\n\tmalwarescore=0 suspectscore=2 phishscore=0 bulkscore=0 spamscore=0\n\tclxscore=1011 lowpriorityscore=0 impostorscore=0 adultscore=0\n\tclassifier=spam adjust=0 reason=mlx scancount=1\n\tengine=8.0.1-1709140000\n\tdefinitions=main-1805020171", "Subject": "[Intel-wired-lan] [PATCH v3] ixgbe/ixgbevf: Free IRQ when PCI error\n\trecovery removes the device", "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": "abdhalee@in.ibm.com, nbannoth@in.ibm.com", "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": "Since commit f7f37e7ff2b9 (\"ixgbe: handle close/suspend race with\nnetif_device_detach/present\") ixgbe_close_suspend is called, from\nixgbe_close, only if the device is present, i.e. if it isn't detached.\nThat exposed a situation where IRQs weren't freed if a PCI error\nrecovery system opts to remove the device. For such case the pci channel\nstate is set to pci_channel_io_perm_failure and ixgbe_io_error_detected\nwas returning PCI_ERS_RESULT_DISCONNECT before calling\nixgbe_close_suspend consequentially not freeing IRQ and crashing when\nthe remove handler calls pci_disable_device, hitting a BUG_ON at\nfree_msi_irqs, which asserts that there is no non-free IRQ associated\nwith the device to be removed:\n\nBUG_ON(irq_has_action(entry->irq + i));\n\nThe issue is fixed by calling the ixgbe_close_suspend before evaluate\nthe pci channel state.\n\nReported-by: Naresh Bannoth <nbannoth@in.ibm.com>\nReported-by: Abdul Haleem <abdhalee@in.ibm.com>\nSigned-off-by: Mauro S. M. Rodrigues <maurosr@linux.vnet.ibm.com>\n---\nv2: Extended the fix to ixgbevf driver.\n\nv3: Improving the fix according to Alexander Duyck's review.\n---\n drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 6 +++---\n drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c | 6 +++---\n 2 files changed, 6 insertions(+), 6 deletions(-)", "diff": "diff --git a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\nindex afadba9..60eee07 100644\n--- a/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\n+++ b/drivers/net/ethernet/intel/ixgbe/ixgbe_main.c\n@@ -10909,14 +10909,14 @@ static pci_ers_result_t ixgbe_io_error_detected(struct pci_dev *pdev,\n \trtnl_lock();\n \tnetif_device_detach(netdev);\n \n+\tif (netif_running(netdev))\n+\t\tixgbe_close_suspend(adapter);\n+\n \tif (state == pci_channel_io_perm_failure) {\n \t\trtnl_unlock();\n \t\treturn PCI_ERS_RESULT_DISCONNECT;\n \t}\n \n-\tif (netif_running(netdev))\n-\t\tixgbe_close_suspend(adapter);\n-\n \tif (!test_and_set_bit(__IXGBE_DISABLED, &adapter->state))\n \t\tpci_disable_device(pdev);\n \trtnl_unlock();\ndiff --git a/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c b/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c\nindex e3d04f2..6feb88f 100644\n--- a/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c\n+++ b/drivers/net/ethernet/intel/ixgbevf/ixgbevf_main.c\n@@ -4770,14 +4770,14 @@ static pci_ers_result_t ixgbevf_io_error_detected(struct pci_dev *pdev,\n \trtnl_lock();\n \tnetif_device_detach(netdev);\n \n+\tif (netif_running(netdev))\n+\t\tixgbevf_close_suspend(adapter);\n+\n \tif (state == pci_channel_io_perm_failure) {\n \t\trtnl_unlock();\n \t\treturn PCI_ERS_RESULT_DISCONNECT;\n \t}\n \n-\tif (netif_running(netdev))\n-\t\tixgbevf_close_suspend(adapter);\n-\n \tif (!test_and_set_bit(__IXGBEVF_DISABLED, &adapter->state))\n \t\tpci_disable_device(pdev);\n \trtnl_unlock();\n", "prefixes": [ "v3" ] }