From patchwork Thu Feb 9 18:04:47 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dave Carroll X-Patchwork-Id: 9565351 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 1E322601C3 for ; Thu, 9 Feb 2017 18:44:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0F32C28543 for ; Thu, 9 Feb 2017 18:44:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 02B0328545; Thu, 9 Feb 2017 18:44:13 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D754528543 for ; Thu, 9 Feb 2017 18:44:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753525AbdBISoM (ORCPT ); Thu, 9 Feb 2017 13:44:12 -0500 Received: from mail-sn1nam02on0078.outbound.protection.outlook.com ([104.47.36.78]:43200 "EHLO NAM02-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751027AbdBISn6 (ORCPT ); Thu, 9 Feb 2017 13:43:58 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mscc365.onmicrosoft.com; s=selector1-microsemi-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=zN3TPb1x3aqKDA6G1YcuAbWGTyVFSawxZQm3B40dz4M=; b=M6xBp2HRL1XDCavHp2RH13lOmm3omRJmbSXqLcG9RXoEge/VAj4kIXsgimQxtIhg/P5hIWFHDAsA4hMy5JoU6h4fl6yim5mAd38cb9vX4fVCUfO/Ipgc1ddbghyIbPrqGSJ9H4WVheMvioGUujob+5Os1G+t27Cin/FkopIP7ZM= Received: from BLUPR02CA044.namprd02.prod.outlook.com (10.160.23.162) by DM2PR0201MB0815.namprd02.prod.outlook.com (10.160.95.149) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.888.16; Thu, 9 Feb 2017 18:05:36 +0000 Received: from BN1BFFO11FD044.protection.gbl (2a01:111:f400:7c10::1:158) by BLUPR02CA044.outlook.office365.com (2a01:111:e400:8ad::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.888.16 via Frontend Transport; Thu, 9 Feb 2017 18:05:36 +0000 Authentication-Results: spf=none (sender IP is 208.19.100.21) smtp.mailfrom=microsemi.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=microsemi.com; Received-SPF: None (protection.outlook.com: microsemi.com does not designate permitted sender hosts) Received: from avsrvexchhts1.microsemi.net (208.19.100.21) by BN1BFFO11FD044.mail.protection.outlook.com (10.58.144.107) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA_P384) id 15.1.888.7 via Frontend Transport; Thu, 9 Feb 2017 18:05:35 +0000 Received: from localhost.localdomain (10.225.65.2) by avsrvexchhts1.microsemi.net (10.100.34.105) with Microsoft SMTP Server id 14.3.339.0; Thu, 9 Feb 2017 10:05:05 -0800 From: Dave Carroll To: "Martin K . Petersen" , Arkadiusz Miskiewicz , James Bottomley CC: Dave Carroll , linux-scsi , , Scott Benesh , Subject: [PATCH] aacraid: Fix INTx/MSI-x issue with older controllers Date: Thu, 9 Feb 2017 11:04:47 -0700 Message-ID: <20170209180447.31404-1-david.carroll@microsemi.com> X-Mailer: git-send-email 2.8.4 MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:208.19.100.21; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(7916002)(39410400002)(39840400002)(39850400002)(39450400003)(39860400002)(2980300002)(428002)(189002)(199003)(4326007)(81166006)(1076002)(77096006)(81156014)(68736007)(39060400001)(8676002)(69596002)(104016004)(54906002)(106466001)(92566002)(356003)(305945005)(105586002)(36756003)(8936002)(5660300001)(6666003)(53936002)(33646002)(101416001)(38730400002)(626004)(2906002)(49486002)(86362001)(50986999)(50226002)(189998001)(97736004)(48376002)(50466002)(5003940100001)(47776003); DIR:OUT; SFP:1101; SCL:1; SRVR:DM2PR0201MB0815; H:avsrvexchhts1.microsemi.net; FPR:; SPF:None; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN1BFFO11FD044; 1:qHiHG4X4EjV1LYfQPyZ+TRvyya7+ay1t7lWBLfqnPXH19qRlRqgWTuAL2EmNcuyZWZryvsRRnY6eQ+t9pk23nIAC4GYjvkNEJYLcgfLOmpmEUJnUBWCkLfQvlYWxVqnZiJqQ0/clvhPs2+Y/4y9vA5v0PxBUYdFFZXDzUGYIvXcBu3eRvMl1qmj3BNLDKtVT+FQ2B182Su9IoZPZ/+tK2DHCs2M15KTBrtJjiitPnilos6oqPxex70M4a0cXXLUmlZ/CaA2Dj4Pb5fimLU76+d+ZOnyXPmfVFum+Yiflm5ewzADnANZqwjr2AmzHsY7Wic8fb/jMsPVJYYDob/Ofp79IeQbXUBptTyFqv52oBVVUk2Ne5WCxf/RUJ7nM5QaDgrSyhp1kmI15t7qQTrN49d1fE3PtBxyWNlNVpvKpIaneqB432uO/gF0x2ADT87a7UquWfWcaPwO2f1TJLPGDqjyG4qBh2iRT1ifcWuwhSnzUkszoZ7kmjYXAL29hA7iJg757fZODinfvVNG5RwPCR5OD8IZArL2u4DLJ4CKyK0mUd7cO1aWiEl9rKmgF5vre X-MS-Office365-Filtering-Correlation-Id: e303848e-7cb8-4e59-70a7-08d451163f53 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:DM2PR0201MB0815; X-Microsoft-Exchange-Diagnostics: 1; DM2PR0201MB0815; 3:ATcVfn5SjYME9qthbSaPrF8C1JynpRxAwN0XfEuszAqpi1FrqerRrNP5jngDDODFx4RBocmApJWbX5ZKN5HleAaPkzfxG7HsKibGEJE9YYq3rvEt8mSU7bLdquapKRqxcH8gzwjge5HvHilozRs3NTTqOlQDNJtAYlvxRS/QgNFRBzlswL1POK+KVz9e+8mmfGzsUr9J5+0afOTAMVgO5Fq/KbANYm1PV4coL/BLEQDXGwFGvMxme4vENltaGO3qfAY128Wk1/8ofGkkaLWkUFulosqWKTpA0aB+JjY/83a49bS7Xu7kt8DJXqBd0gvoSxltqYKRZjYTjcrZm95oLJqaseOTMQ3e8i3iGmVhhOAXxzA+FhzQiCaDjFLFsDS1; 25:1djyor5KCQ2mJYaXLK0XuspxAbTbMViHo+kss2R7bVeH9HSp4nsZh2CBKgvjYUVDrJ2FL4/aPmr+JKE0I+CBMy+B3qvxjs7Bs6oVTpaFT8/s/w/kVqIUA5hpLt0k78c/rGNGCq2f0mlitGDoeu2soErhbzdDgvLPhRBlacpbvptnGimxozHZipAVK5+I42mk5InY24dSA2AePzSrTSloLUyOmXdMj0a8hi7j8Atq6fpySd3qvkaw/dbGOqvnMXiwhlrZlKZ8184g44/pw12BnTUiJJe6VWNJcmhIyeO1dLgePgaLgPA/VwHNzGZJwU29mQR1wuq6buJBHbinocwYIiwF9W5RHmGE/Es4+3x++B5u5/HqcPWE6sdNt11Lm8xJphPBQGtPYHR/9eAiIecutgVLQj6fAi6WhAsmfmqtay4f98a8GBnPtcz3+uqm/c7sNidtKXYD8nhycxmlj0bo+A== X-Microsoft-Exchange-Diagnostics: 1; DM2PR0201MB0815; 31:sJcRmgdQtRWGHAkB3tQwlM3lLVOcoCkRUVzF/qJ1FR5ycHJBPLmPqt6dk4gQcN+5Lz2xjQTEneCjtJJEHnz6UvolJCPxPG3Hwhmd+dyi/B/U4G9YImL5JRTNdEesYBSMe1PvLIL+vGsNHULtSqKzi7xTKhsjpjxPSXFCjYQb+1A1Oo6ksj9sJDPErASNHwsNjOz+uYYactYvY8C01A0JZ8NYkb54cciSZq+/AOJ3m9j79ondoBADunjV172FnTaOe88/EjFnBtxFl4KqVhwJiw==; 20:xOw+/WJ41UftOVoMBEAapzy27qBsT42Xe11PPkgR5iWax2AN2qv6z+mjiraEOrpvXcE6oRZkSMkiEUGj/AkKB+hG7WWXQuhF8oWUplSftrXPzrBMmEHoDktruJqtDB63ovIARdo9RJthcQZY76ymfektm0t5374Hem0KTh271OuyPeHUK8wV+VZfHteW2ZVt6QOH1eAY1vrLRgrwc8w0RLAVStMH/CBwdt95EUIgwql6bvKw9hMaXp07bR8OpfOis9nxOu0vabT/l6dwJZxToA6TlnWguY/txRT15SjtvSgRMRUsbQtSn7dAww+hOYsIUeAwPGlnc74808SDpnxjLmilNUEYMAcKt71OI8EbPc6DRIrHJqkAL8gDPELEa8brZKbAKWnAdiZrGczjUwrhFj3vUpgZ49sa5tcP1OoEWstLbjgJavO07+UDURGBHqwsvt2bdV3sScqvGnuPA4Umf2fK0ognWXnNiIxxx+cw8/XnBbFoffC1ntek50+xPvcH X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(9452136761055)(72170198267865); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(5005006)(8121501046)(13017025)(13015025)(13024025)(13018025)(13023025)(10201501046)(3002001)(6055026)(6041248)(20161123560025)(20161123562025)(20161123558025)(20161123555025)(20161123564025)(6072148); SRVR:DM2PR0201MB0815; BCL:0; PCL:0; RULEID:; SRVR:DM2PR0201MB0815; X-Microsoft-Exchange-Diagnostics: 1; DM2PR0201MB0815; 4:DSJMi2Iapjk2wWAMn9nh5gCn/qpsirrD3jpLFvyNrqSUeCPDMlzNgpf8AXhvNKkOVWbJnDaoUIcWWGJHVETzqQb4GlrTRqkbvDiYjUFFKFcK4Z9d19qt0G0LhGyep/eHsnUp9ATOtK0+Wx/lBu9jAyQumvtFiu02vW+H7dmGuCvzb5fFUWjlhvExeqvBDeiZUdV7/O9SZjC83FyQd5+g23/4MBRZGhxNzjH8NUl+wPulDzS9a9A9jLJfsBg5+WIicYrz8HIRVOeyltWDNoQCBCmJHLRfcrfJjbYox2zOKl82kmdEfMpQbpNpAY67nMcEh6fenGwp/ozdjWeT17vjLdKEB/oubatsxSF/i4PRE6TOsM683wSirjEF1UpcN3/4Pv3gbK/4dbc82BK8UR242s2KtA78dDp7fAk3C6gIuPlYqQxeBtfXyj/2UW98dqA6CZdK5ksdY8vb9XnW4bdtnLC8nqDTQJ0tvvA56FEl6NU4PrRohmGVfM0PyLPEI8za7wq+O8WNh2Lt2XQceG5A5o5TeydL3UFERvjfUHbfIXKtsignQJFOrMBrmaTd+gy3jNHI43USmf+On6XPkyLD/zv9UFrLmYdj5+pOPX+KAP5s3IF7oPUP6jtMEMbXIMQp/p0xxikLtglVJPqijqqbn02pK6A9SXkBsY11a/JxUjY3cUX+Bs43aGtsKOwaQEiowlPLwAGiYa5js6wxejtUwHxj6T63pkkSqoLMElUyHdygcLnmkn3SgEkBSR7wzMX9QrpVtHf308w71pUKnRfDVJP/j9hv4ccJZ+Uf1R2OOE0= X-Forefront-PRVS: 02135EB356 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR0201MB0815; 23:8Q+qVuhtWuMJhkJpnCqP9S5GeczFcfMvo2//L8m?= =?us-ascii?Q?IbChJoEublM+d31JTUynuPM6IQ8BGdeIBW4ZiGQquHBm8FEv0yFUFNiCWker?= =?us-ascii?Q?W9z5adjw8+DFd9KLofD6W/Q8DJ0P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?XDpeDCXi5lu4znQePeL3j953ZP1MBdgCcS5UwanmLzAg71NKoSv19Uke5TG7?= =?us-ascii?Q?pQCDEwYpoFQNNDCDjPi3a9sa4yyxKExN+nLLU5uTXex3XaczNeno3IiHPZGf?= =?us-ascii?Q?qhK2vC2s87jfgwJt15aMa7MoCbw0bqYCiFkClyZOTsjmF1jO037lo1Q=3D?= =?us-ascii?Q?=3D?= X-Microsoft-Exchange-Diagnostics: 1; DM2PR0201MB0815; 6:SqrKHMjdLmlyZVNRclxe1AaXFxeYtoIywNfXEezXNoyWRXqy8lY/VmXHHuSQ8tDEQw4OHmFV+xdBzZ5cigV467EPt2LBnkNXnS0o75Pj1QuvUb1SPtFnzw2oIqII+2Xb4BQPhM1dw4JFUQQlwQ+S3/6UyqU9Z1qle8VsDSMSh3sjsadEc4CpPTtJa40Mp6oqH7IJdbmha0L8BL3qQEoJ7tceJop+ofK4sfzYGtpTKEtBG5jf9J8IudCEfvRHMjCzNoG/gt2IMcEGSDI7Q7qJJrLwVBjvios9Rfw/nGdvWriT+x49/DwuKWSdi/j1UJUdWKN8eF0nKfAt1ICskOxWenbnZ8GBn/qrS+2bccr2KxTXTClfZ1lNFp7p3i26e86GHpZVC0zO5UPBV4pUsfEEr1RIPgOPZGoTtw8hMSSx6+A=; 5:xIsdW6wLroQey4yW7+nftP9Kvr9ft8duWFErLlrMHP949DWW9j8PM16WkpdFDwj0ve40RUb4p4kvkEtz+xneuKTzGihAzRK26utBc4zMBZmloY/855Gh89peU7RtzZKrdNDoEaNmfeizmAPQ1XXVS4MLOfiXsbwMSnVXrxX6kwg=; 24:9eLCGQ+en5Drfv9oBXELJh0+mo5UhBkJk4/vQXVsue6qz/6ptbuktoSnjweR3oYUteGREnQB8TnZqL5QCk07WMGe36emB49kjUwP8twgmtg= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; DM2PR0201MB0815; 7:YqrqwTQhIOUX/j/sKKXKc6NcW1SoZjgjvXU3q2vKoMtxeZC6Dpp9Z2Cy0dIVNBeUEQPi4rfVdAmRIDInAKgoL2S+nsIB+s3QQb90uvYBmzg8VtOXfZsVu71OfFRF35nVGPuXaLVkakk7mID5YxrM6v3nHZx+YgT/Qk7kO3bgnh8po80h8X4lbLK85dOW3XL4fYs3v2bUvk/2Jlr8ekPRs1LKW1YsYODru6/jU57VBd0B52uakXlpf0IrWNJyUguGSBpLw72df6ds1Cp4VyTzmi0vGZkwfFHRbMTynoHiN2pXgZeB6y4u3LGDE3PL06q9xNnY4ORe0fr9RkVCJdZ4rPWYJmuEvFfls6cG5V4pOEyPJU9RBriDjejbl9YRylBGtn0kUbJ+MMo7wdcW8SHVkizPAOL+BPDJLdu4qDkLYPWq6akUimsg9f5uIvI5ApdB/sWBdwGG3TqFntIJ8HEpBd8Q8q2p7UYK5lRxpmbLH6G9IU0BaaHosccOfvt+q9rJQqGpE2lWNpVgDmNASTE7Aw== X-OriginatorOrg: microsemi.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Feb 2017 18:05:35.6213 (UTC) X-MS-Exchange-CrossTenant-Id: f267a5c8-86d8-4cc9-af71-1fd2c67c8fad X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f267a5c8-86d8-4cc9-af71-1fd2c67c8fad; Ip=[208.19.100.21]; Helo=[avsrvexchhts1.microsemi.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR0201MB0815 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP commit 78cbccd3bd683 ("[PATCH] aacraid: Fix for KDUMP driver hang") caused a problem on older controllers which do not support MSI-x (namely ASR3405,ASR3805). This patch conditionalizes the previous patch to controllers which support MSI-x cc: stable@vger.kernel.org Fixes: 78cbccd3bd683c295a44af8050797dc4a41376ff Reported-by: Arkadiusz Miskiewicz Signed-off-by: Dave Carroll Reviewed-by: Raghava Aditya Renukunta --- drivers/scsi/aacraid/comminit.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/aacraid/comminit.c b/drivers/scsi/aacraid/comminit.c index 4f56b10..d56df36 100644 --- a/drivers/scsi/aacraid/comminit.c +++ b/drivers/scsi/aacraid/comminit.c @@ -50,9 +50,13 @@ struct aac_common aac_config = { static inline int aac_is_msix_mode(struct aac_dev *dev) { - u32 status; + u32 status = 0; - status = src_readl(dev, MUnit.OMR); + if (dev->pdev->device == PMC_DEVICE_S6 || + dev->pdev->device == PMC_DEVICE_S7 || + dev->pdev->device == PMC_DEVICE_S8) { + status = src_readl(dev, MUnit.OMR); + } return (status & AAC_INT_MODE_MSIX); }