From patchwork Wed Aug 1 16:44:47 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bharat Kumar Gogada X-Patchwork-Id: 10552743 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 47C32139A for ; Wed, 1 Aug 2018 17:14:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2D8992B9DB for ; Wed, 1 Aug 2018 17:14:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 212402B9E0; Wed, 1 Aug 2018 17:14:45 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,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 242012B9DB for ; Wed, 1 Aug 2018 17:14:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2404020AbeHATBQ (ORCPT ); Wed, 1 Aug 2018 15:01:16 -0400 Received: from mail-co1nam03on0042.outbound.protection.outlook.com ([104.47.40.42]:11461 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2403811AbeHATBQ (ORCPT ); Wed, 1 Aug 2018 15:01:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xilinx.onmicrosoft.com; s=selector1-xilinx-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=m/YLddCwqWOYLbFELmo7npsj2XC8xBXch6W/yzlPNc0=; b=G3y5+sj5vodCDxM/XeMm6Tb3oEzueBjbbh6zeBW9IQqkVIvwMIDLvAYtYoG70V7Q6ePKZecXK4pFI40+m535X91rc52rn5/41CbOAw16X1JUFqSQhGWeH+EDDsFtDQ0IaNanE9kHoTiDpHCK5flY+uQJdfRgPdGm0yVDjapxrEQ= Received: from MWHPR0201CA0061.namprd02.prod.outlook.com (2603:10b6:301:73::38) by BL0PR02MB4323.namprd02.prod.outlook.com (2603:10b6:208:40::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.995.19; Wed, 1 Aug 2018 16:49:45 +0000 Received: from SN1NAM02FT040.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e44::207) by MWHPR0201CA0061.outlook.office365.com (2603:10b6:301:73::38) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1017.15 via Frontend Transport; Wed, 1 Aug 2018 16:49:44 +0000 Authentication-Results: spf=pass (sender IP is 149.199.60.100) smtp.mailfrom=xilinx.com; google.com; dkim=none (message not signed) header.d=none;google.com; dmarc=bestguesspass action=none header.from=xilinx.com; Received-SPF: Pass (protection.outlook.com: domain of xilinx.com designates 149.199.60.100 as permitted sender) receiver=protection.outlook.com; client-ip=149.199.60.100; helo=xsj-pvapsmtpgw02; Received: from xsj-pvapsmtpgw02 (149.199.60.100) by SN1NAM02FT040.mail.protection.outlook.com (10.152.72.195) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.995.12 via Frontend Transport; Wed, 1 Aug 2018 16:49:42 +0000 Received: from unknown-38-66.xilinx.com ([149.199.38.66]:60556 helo=xsj-pvapsmtp01) by xsj-pvapsmtpgw02 with esmtp (Exim 4.63) (envelope-from ) id 1fkuJh-0002wU-JY; Wed, 01 Aug 2018 09:49:41 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fkuJc-0004si-EN; Wed, 01 Aug 2018 09:49:36 -0700 Received: from xsj-pvapsmtp01 (mailman.xilinx.com [149.199.38.66]) by xsj-smtp-dlp1.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w71GnZTZ001199; Wed, 1 Aug 2018 09:49:35 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fkuJa-0004rx-V1; Wed, 01 Aug 2018 09:49:35 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 1/3] PCI: xilinx-nwl: Save error IRQ number in device_node private data Date: Wed, 1 Aug 2018 22:14:47 +0530 Message-ID: <1533141889-19962-2-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> X-RCIS-Action: ALLOW X-TM-AS-Product-Ver: IMSS-7.1.0.1224-8.2.0.1013-23620.005 X-TM-AS-User-Approved-Sender: Yes;Yes X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:149.199.60.100;IPV:NLI;CTRY:US;EFV:NLI;SFV:NSPM;SFS:(10009020)(136003)(396003)(39860400002)(376002)(346002)(2980300002)(438002)(189003)(199004)(7696005)(50226002)(54906003)(36386004)(76176011)(356003)(305945005)(51416003)(316002)(2906002)(16586007)(478600001)(110136005)(81166006)(26005)(8676002)(77096007)(81156014)(4326008)(126002)(11346002)(476003)(2616005)(47776003)(446003)(486006)(50466002)(8936002)(336012)(63266004)(186003)(106002)(36756003)(106466001)(5660300001)(107886003)(48376002)(6666003)(9786002)(426003)(107986001)(5001870100001);DIR:OUT;SFP:1101;SCL:1;SRVR:BL0PR02MB4323;H:xsj-pvapsmtpgw02;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-100.xilinx.com,xapps1.xilinx.com;MX:1;A:1; X-Microsoft-Exchange-Diagnostics: 1;SN1NAM02FT040;1:G5uvWzAIeUqUvv3MAQVEQ2KeNI/Z9YEuonDjnsZuxmgFWCQzRpnJctUvmeqALzBadlOZ7byWnmSeQSY1Yquu60MEQVtgl35v7jhOIYiakFYeqaHeQnJ6dkhpAroDzvPE MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6ddafdd0-a283-4cf8-e51a-08d5f7cec81a X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(5600074)(711020)(4608076)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060);SRVR:BL0PR02MB4323; X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4323;3:sfcPVhpbow4uiqcnPBHgQ53x1hRtA3Dc0AY36u3MhqYiMwdCxGsb6XxajrebRP40KAs0upsJc+0WrW4d2m7/SefQvXsN4hYawjzGOMf/e8++ub9+57pqoWJBZDqYsii1z1F/AFYDpj4brLQLAdovwUwFViF85QVlFeiH7EhZMpXrGJLXef3OJ7amOPkMZCtvUVeNJaEshhra//Y3N7VznXQdmacpL+dPU/vf0f7RjLIaO0eCYpw/irNDeD47QVYtCLX/RIHc9aXyz+v61oOo9ajObbIFENxiRryTxWIxm1AgqNNgEKEfxmCWApIK8qT/addNgIenrs3VoR+y+n/9LDCD5XKtdxr3+Qz11a8zr90=;25:Bhdtz2IJHuTNBL+VpGYbM8MOppXqWo+vhVZDZosFaYHJ6K5zsJrT22P+j9IAMKbU0mBEBAxIK5tknJ3CTP7ByII+oocNHYfm9ocZvJNlEBC4sNCPnOBgrXVhz8eT1LKhlME+/ImFHUjUq2QZZm4k2/7jeF/z0g1inR+Lmi0/oO62/US3MECs9xqJMIXHsavkBjdEMm+tz2+ppwrQxEMrs5r47wfzQNIIb0ak18RshhTrnaGKwa51g1yVuNLRCEP/Nheo4Pj2XGHOm+LxrOEV5f+o4L7cvnOGgfeSOrViWfI/lwyTqtKIhYGHqt5lj/o6CqYkYWLYbURtyQQPmYJlEg== X-MS-TrafficTypeDiagnostic: BL0PR02MB4323: X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4323;31:OQTG77kpCVORdAz8/Lt1eiD8vQCyBi0RoFK5SiZ9gWJ3rBQ7ZxwhbNgKJAJ0RiXaTFMbtICar9RbUGldwo1beb94/yF/ARHEVlaO77ySIFDOdM1rk6lVFXGUmVbPvj3cZNBuPGkbAvP+NKx0fx4mEMBgCgDFIB7bu7Pupmd2r/r6x3cxm5T2SB/OMhC/QaKrqD9emMOlFbbfNTvivwQCxycOrNw/BdFvOaIUZ0NzwA8=;20:zAN2wQqXyOMqnGNA/z42FvZz0omZeCQYWuRNygjmqAwp2EINbFQXxXyXles9lYwiQ7WBdP+ndWgw1mCxyM5CKisYzH/sBhh1u67IPNbQy1X1Gq6NoPd7MTXX+yzTO82+1rKSI7AuSa+S039reuTt2TbyPH4H4/XveFIMdCJvVTwkP6s6bnWnW8KEfAt5NVCQK1I96gXVIDZ+CbU3EDtzenRuh/80P7xTf7Yp92yeZvPA3vEyStIFPx0JqzAtrvSbaR4Sb9D9OgJ9LHX+yjKiX/4rZ/k6zK9sf6iTBX+D9tUr0/tmjS4yjkWi4/oykgXDf5jrcgt0yir7qCAcIq7o/5S0ehwgcApbh/jghaDpECowi/wuMdSUtV27VMj9mkDMcaCNs4JJsO2w8JSUsNLGGTabl49u/B/Sw/MEjJ6EvaQbI+dNsRM+R01UAoKlmpNC8LVEaKXvVN5+vZi33LcMTvblzBuVhOhSpM2gNxuTsiuHBB5xg73y0ekjYPPthr0W X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592)(211171220733660); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(10201501046)(3231311)(944501410)(52105095)(3002001)(93006095)(93004095)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:BL0PR02MB4323;BCL:0;PCL:0;RULEID:;SRVR:BL0PR02MB4323; X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4323;4:rKF0WrVdjo/dG4WNjzKzpom2jWIT//tJVwOH/h6d2vlM1JgKykNXjr64PoXF6i6i8jlufqkvXF4R/JkretBSOidiGkkVqWuuOa/fwyFAbOpze6JkxeR5lQeygESaq+YJcg5TXx/shiG1blYqHlLpMyym/YMxInCpesB87vIbInf4/kOq6r37dr5hQMiDGqgWxEf7EIbly76Z4UMm+xwrxKoWYuofXzYjHbLjboKZ1IX9/EbyMRXWxSaDymYXoM8suolLcztX3U4Kir0t6RkHbn2Mrju83wDSFs/eAnjHUJ44HsfPuNRZbdrfz+R8lgWySV03OHWGTVTlpHpEbz3APKj8FzKMeUXfA04E2XYF0FU= X-Forefront-PRVS: 0751474A44 X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4323;23:lRboK1WBUV3BB+G8XtpiKLf3NANB4qpdi88B9FgwxIhY/OmYaJH4ZMdRlSU77QzRkyiUCdxmeW2KsUMdGYdOxicFHM0tZPmPmOweCGv9mQ31hzLkj+kMqqDCLt77sOFbNnbsgz4Y6RqRUMZvkLkc8RxuXWIUoic/lZgFYs72XIpmSNoUlPdZQIJFxZIIenPdkbc1dYfJgfQOPcXIgnYCS9bdCdN3J7R/GzOsd/n0CLVvk1mNjZHw+GvKbe5CdWe8oQfW9O/C0dRCODBmO6LYbFZen/0+bGztWaefJ1Mg1t14AWpngcJvDdM59+5InGJMfre5mkAYC0Tew805JVg/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osticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Aug 2018 16:49:42.3759 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6ddafdd0-a283-4cf8-e51a-08d5f7cec81a X-MS-Exchange-CrossTenant-Id: 657af505-d5df-48d0-8300-c31994686c5c X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=657af505-d5df-48d0-8300-c31994686c5c;Ip=[149.199.60.100];Helo=[xsj-pvapsmtpgw02] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR02MB4323 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Xilinx ZynqMP PS PCIe has dedicated interrupt line for reporting PCIe errors along with AER. Save this error irq number in struct device_node private data, this will be used via PCI qiurks for AER kernel service. Signed-off-by: Bharat Kumar Gogada --- drivers/pci/controller/pcie-xilinx-nwl.c | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/drivers/pci/controller/pcie-xilinx-nwl.c b/drivers/pci/controller/pcie-xilinx-nwl.c index fb32840..d505fe5 100644 --- a/drivers/pci/controller/pcie-xilinx-nwl.c +++ b/drivers/pci/controller/pcie-xilinx-nwl.c @@ -663,6 +663,9 @@ static int nwl_pcie_bridge_init(struct nwl_pcie *pcie) struct platform_device *pdev = to_platform_device(dev); u32 breg_val, ecam_val, first_busno = 0; int err; +#ifdef CONFIG_PCIEAER + struct device_node *node = dev->of_node; +#endif breg_val = nwl_bridge_readl(pcie, E_BREG_CAPABILITIES) & BREG_PRESENT; if (!breg_val) { @@ -744,6 +747,9 @@ static int nwl_pcie_bridge_init(struct nwl_pcie *pcie) pcie->irq_misc); return err; } +#ifdef CONFIG_PCIEAER + node->data = &pcie->irq_misc; +#endif /* Disable all misc interrupts */ nwl_bridge_writel(pcie, (u32)~MSGF_MISC_SR_MASKALL, MSGF_MISC_MASK); From patchwork Wed Aug 1 16:44:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bharat Kumar Gogada X-Patchwork-Id: 10552739 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4CB7F96FA for ; Wed, 1 Aug 2018 17:14:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 33C862B9DE for ; Wed, 1 Aug 2018 17:14:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 27DB02B9E2; Wed, 1 Aug 2018 17:14:21 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,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 2AF422B9DE for ; Wed, 1 Aug 2018 17:14:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2403758AbeHATAp (ORCPT ); Wed, 1 Aug 2018 15:00:45 -0400 Received: from mail-cys01nam02on0047.outbound.protection.outlook.com ([104.47.37.47]:18784 "EHLO NAM02-CY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2390055AbeHATAp (ORCPT ); Wed, 1 Aug 2018 15:00:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xilinx.onmicrosoft.com; s=selector1-xilinx-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=WX9pQxq75+rYVmtssBthd6R/Om2gjjtW0Sv4/7M2H0A=; b=X4YspJApH1tS1y3zRmPNy3H216B0IPgkZuGu8BrG86Mp2dPIeyY58rupELERgSiIpq1OV1nr/riHgXcpuzDn5SJvm4AGjSPTnMbcblmZUGuaZ0bfogFS+1Dc9tP3Lml7aDg7MePmmanvkKY9lo1+5JuMer5mNg6YL03JfJitotU= Received: from SN4PR0201CA0021.namprd02.prod.outlook.com (2603:10b6:803:2b::31) by MWHPR0201MB3515.namprd02.prod.outlook.com (2603:10b6:301:77::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1017.15; Wed, 1 Aug 2018 16:49:54 +0000 Received: from BL2NAM02FT060.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e46::201) by SN4PR0201CA0021.outlook.office365.com (2603:10b6:803:2b::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.995.17 via Frontend Transport; Wed, 1 Aug 2018 16:49:54 +0000 Authentication-Results: spf=pass (sender IP is 149.199.60.83) smtp.mailfrom=xilinx.com; google.com; dkim=none (message not signed) header.d=none;google.com; dmarc=bestguesspass action=none header.from=xilinx.com; Received-SPF: Pass (protection.outlook.com: domain of xilinx.com designates 149.199.60.83 as permitted sender) receiver=protection.outlook.com; client-ip=149.199.60.83; helo=xsj-pvapsmtpgw01; Received: from xsj-pvapsmtpgw01 (149.199.60.83) by BL2NAM02FT060.mail.protection.outlook.com (10.152.76.124) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.3 via Frontend Transport; Wed, 1 Aug 2018 16:49:52 +0000 Received: from unknown-38-66.xilinx.com ([149.199.38.66] helo=xsj-pvapsmtp01) by xsj-pvapsmtpgw01 with esmtp (Exim 4.63) (envelope-from ) id 1fkuJr-0002L8-Ok; Wed, 01 Aug 2018 09:49:51 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fkuJm-0004te-LH; Wed, 01 Aug 2018 09:49:46 -0700 Received: from xsj-pvapsmtp01 (maildrop.xilinx.com [149.199.38.66]) by xsj-smtp-dlp2.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w71GncKF009084; Wed, 1 Aug 2018 09:49:38 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fkuJe-0004rx-2f; Wed, 01 Aug 2018 09:49:38 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 2/3] PCI: Use dedicated Xilinx controller irq number for AER Date: Wed, 1 Aug 2018 22:14:48 +0530 Message-ID: <1533141889-19962-3-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> X-RCIS-Action: ALLOW X-TM-AS-Product-Ver: IMSS-7.1.0.1224-8.2.0.1013-23620.005 X-TM-AS-User-Approved-Sender: Yes;Yes X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:149.199.60.83;IPV:NLI;CTRY:US;EFV:NLI;SFV:NSPM;SFS:(10009020)(136003)(396003)(39860400002)(346002)(376002)(2980300002)(438002)(189003)(199004)(2906002)(36386004)(81156014)(81166006)(4326008)(8676002)(336012)(8936002)(107886003)(126002)(51416003)(76176011)(486006)(106466001)(476003)(2616005)(11346002)(446003)(7696005)(63266004)(5660300001)(6666003)(186003)(9786002)(77096007)(26005)(106002)(110136005)(305945005)(54906003)(356003)(478600001)(50226002)(36756003)(316002)(47776003)(48376002)(50466002)(426003)(16586007)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:MWHPR0201MB3515;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-83.xilinx.com;MX:1;A:1; X-Microsoft-Exchange-Diagnostics: 1;BL2NAM02FT060;1:97kWJoh12+2ikg6BwDou28hkyhUaauhMLD5Ie2xAtKcHuWLZ2KI+MYjjbWDxNGqLiiSl0+yivuSBAix9fTUNEWnR9AUDDjziXfwHX7r8IUjZeKwWQwg7CsNMxFvQw0r2 MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 745967a1-0a2e-41f4-03f5-08d5f7cece4c X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:MWHPR0201MB3515; X-Microsoft-Exchange-Diagnostics: 1;MWHPR0201MB3515;3:s/6Jz5hMK3ozP8l7xmkzAP+Epu5J1CIMizzSFltL9q99UKeiVGvI8nWbIPQzM/ErEfOgby2JL2JZYRbrpVl/VIUNMcd5i2nbHVV13iJ5t8bhsjZqq6OfZf1HXRGMhPXv4y1OD0z9SBVxYnvS5fa3SvnKGjmX21CbNG+oc0yw4qbMIx4/Ucz0YKPbio7yvgtQyLWn6c7h8gfzrJp3RM9Ow3Z6MRL4pvXkp2gA+ChFowfE4ozJ0lRylfDri0rC4SOQAi9RGg7nIyVHQDC6zDY6M8+mvfODy+8AW5FmLalt779S9MVm5Y87h6FAujeTUIsaOiVWcE6qlgv5vo4hw91eC+jngHlYY+UXLn6kCDH6Q7s=;25:YaQi0wUmE+3Y3dzKNp9bX4r/FGPFVK/neGAgjo7kw13rDWiQHpNIxTkYE2euX0SLBtwaX7Y124H3AuGhobQk26S+4n9U9oeREjxZ7G7udBBj6ej71Sz9dySmbhSDHFOp6r5oKQH6EUIVWO428ifMnFAnM3jOaScafjQxXPgS3Yt2b/uU/xnWXqy2VD2M7d59qYJ8K0fktbGLlBT0wWsquS+2GqE6xmHMI8Bv+4zfLmq/NKe5UlZoqeELSlxqb1DpRoHTLwdgxUwuFvtDuHVnp1PkM2kw4fG1BqlnJQSpKZ8aJHuey9OkrT6GYY1T3+5EFgYNadAfScKIykpgM280KQ== X-MS-TrafficTypeDiagnostic: MWHPR0201MB3515: X-Microsoft-Exchange-Diagnostics: 1;MWHPR0201MB3515;31:Ovx5KaEDS3gwVcLyaCrtUN2EciEYZ7jLfsmksM1GAxm/QxLe74oJTwAZa5WzWd1Xk/r1uXYZIZ+MqRita+8CUop82cl3mo3mCiV+U8d2+iHJI86OCRPgH6055uexMW3WyJgMvx2toQNztFgBtz+4DDAEmlAHWYuvGvYF8QiArUlDlHydBVy49PS1Pm/eSD0l0eRQAPbJqEuqM8xBdwXyBdDTc/A9ypitoe98Av1gPjM=;20:3snA8SoEYMoONtIP7en/0GCfu1Y3Nt/iEpJUw9ViRTkdtdSVLS16TDguk0/byvkVGNvNfY09Ku2y+gYA3uvixn5fpNRDyXiKUW0BSkCcIomTJS2zA/v/wcv+a0/OanKNS7B4UduSdMMshQdJtBRfldB6NaGtmv1NKm0bDVTFoELgrHZecg6v0H3ftq3iuRbtZhxdAa/PHQ4rrHCWkxQRKnEePY9VkMs98KjObhMMT4d5jEnEitpwi9OZk3pPNz3qYkPJamr6JCaj7s2ejywP84LZ1sDZjOfWt9lh0FX719WaBpAg2Nus2/How1QLVALVwaxoT8219NrsRlPOjiXt/b8OvCTvJK/NUEHfL8mbrD6y9V+aCh+uYdhNK0YFCR/Y+Q9Czsg4I7nIaac/mmgZDJj0ivJlIbeoYv2yLurVUrAEUMGaepaUHOGVO/VSZszu2BqlvO5L/BtBeDSvHQjtQe5af6Db748JNhKqa70oafBCNqq1UUekTVZRsB7EV/Zm X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592)(211171220733660); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231311)(944501410)(52105095)(10201501046)(93006095)(93004095)(3002001)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:MWHPR0201MB3515;BCL:0;PCL:0;RULEID:;SRVR:MWHPR0201MB3515; X-Microsoft-Exchange-Diagnostics: 1;MWHPR0201MB3515;4:fixu/MJeoD1W/6atAM4ONiuJ7roJStjC4s2KnKgfWzXVNossa9WpeG42LucztwLFD0BkHMZF6S9A8dttiRHuVzk0n/YMclzbWYj+6/D9MSRu1q6pJqdjFqEXstu5zbd/3/KQJa7L2P2gpdvh+iF90P4K/EGKXCSRQLWTdNDwav2Sgq9iCQz+EYjL83vltelBA/WkUdizfeq6saj6+QPxSnCKenZCKE5LBmj+kvqNrDRcSwS36V1MCNm4hAsjsgkc+IJAbZbKUMaVljxO3GCd9dS7UfUkmd1/BW3Vyvrx1i1ZGUf2TCOIf8Oz2ekPC2jAKM76X22QQfcrt8XR36U9epo628Mv3gJqd0Pl6vBHiS0= X-Forefront-PRVS: 0751474A44 X-Microsoft-Exchange-Diagnostics: 1;MWHPR0201MB3515;23:hZKO14MXuqXa95bkhrYogjNELnu17eHX7LftVHygUwOda/g6qu9eEslI+Sx3KJHJpDc3CiqfOM2Ih1s76xw6fTxoTIqCL9mqFIy+91fGk+4HORjOSMWdgDe/EhFOcQqbk0Cugne/4dAo/ktgWaA4ljC3/PNjPnZdGS9g3xIkEeugrdTG67FKkshm1BwJdOXbZb+WJc39pxXcVBYsp6HR9MSZrw+CVue18tFBdwMIsftF2r8tQk2L4hZyxbVDvjkicAb8tVifPlz6+XmJ7dUVMOMVJg8J702thAGLa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V9j SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Aug 2018 16:49:52.7017 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 745967a1-0a2e-41f4-03f5-08d5f7cece4c X-MS-Exchange-CrossTenant-Id: 657af505-d5df-48d0-8300-c31994686c5c X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=657af505-d5df-48d0-8300-c31994686c5c;Ip=[149.199.60.83];Helo=[xsj-pvapsmtpgw01] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR0201MB3515 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Xilinx ZynqMP PS PCIe does not report AER interrupts using Advanced Error Interrupt Message Number. The controller has dedicated interrupt line for reporting PCIe errors along with AER. Using pci_dev->sysdata of root port to save controller irq number, which will be used for registering AER irq handler. Signed-off-by: Bharat Kumar Gogada --- drivers/pci/quirks.c | 29 +++++++++++++++++++++++++++++ 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index f439de8..e666373 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c @@ -4753,3 +4753,32 @@ static void quirk_gpu_hda(struct pci_dev *hda) PCI_CLASS_MULTIMEDIA_HD_AUDIO, 8, quirk_gpu_hda); DECLARE_PCI_FIXUP_CLASS_FINAL(PCI_VENDOR_ID_NVIDIA, PCI_ANY_ID, PCI_CLASS_MULTIMEDIA_HD_AUDIO, 8, quirk_gpu_hda); + +#if defined(CONFIG_ARCH_ZYNQMP) && defined(CONFIG_PCIE_XILINX_NWL) && \ + defined(CONFIG_PCIEAER) +/* + * Xilinx ZynqMP PS PCIe does not report AER interrupts using Advanced + * Error Interrupt Message Number. The controller has dedicated interrupt line + * for reporting PCIe errors along with AER. + */ +#include +#include + +static void quirk_xilinx_aer_irq(struct pci_dev *dev) +{ + struct device_node *dev_node; + + if (pci_pcie_type(dev) == PCI_EXP_TYPE_ROOT_PORT && + pci_find_ext_capability(dev, PCI_EXT_CAP_ID_ERR)) { + dev_node = of_find_compatible_node(NULL, NULL, + "xlnx,nwl-pcie-2.11"); + if (!dev_node) { + dev_err(&dev->dev, "Error could not find ZynqMP PS PCIe node\n"); + return; + } + + dev->sysdata = dev_node->data; + } +} +DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_XILINX, PCI_ANY_ID, quirk_xilinx_aer_irq); +#endif From patchwork Wed Aug 1 16:44:49 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bharat Kumar Gogada X-Patchwork-Id: 10552741 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A38D3139A for ; Wed, 1 Aug 2018 17:14:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8B9F92B9DB for ; Wed, 1 Aug 2018 17:14:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7ED522B9E0; Wed, 1 Aug 2018 17:14:33 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,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 373D72B9DB for ; Wed, 1 Aug 2018 17:14:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2403996AbeHATBJ (ORCPT ); Wed, 1 Aug 2018 15:01:09 -0400 Received: from mail-eopbgr700054.outbound.protection.outlook.com ([40.107.70.54]:48566 "EHLO NAM04-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2390055AbeHATBJ (ORCPT ); Wed, 1 Aug 2018 15:01:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=xilinx.onmicrosoft.com; s=selector1-xilinx-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=24nzfMdNwRVkjQ+gIcRdply1bMWPaXvgWBFCsDHhLKw=; b=r96k/1PvjfB6DiUj+/9NQbDcmy2HsBU7fPLNbvNbQEKoswmrheOi3kX5BVGtKPP8D18mGq7+zdC6gZF7HUz32xepOG90XSReNtT+aPGOxbPMx4zRNQXgDaASbqGX8P35dtn7xS9rf4zF+yr9EQI5PxkuYaNKGbEiyXBTGFbRLQc= Received: from SN4PR0201CA0062.namprd02.prod.outlook.com (2603:10b6:803:20::24) by BL0PR02MB4449.namprd02.prod.outlook.com (2603:10b6:208:45::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.995.19; Wed, 1 Aug 2018 16:50:05 +0000 Received: from BL2NAM02FT030.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e46::204) by SN4PR0201CA0062.outlook.office365.com (2603:10b6:803:20::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1017.15 via Frontend Transport; Wed, 1 Aug 2018 16:50:04 +0000 Authentication-Results: spf=pass (sender IP is 149.199.60.83) smtp.mailfrom=xilinx.com; google.com; dkim=none (message not signed) header.d=none;google.com; dmarc=bestguesspass action=none header.from=xilinx.com; Received-SPF: Pass (protection.outlook.com: domain of xilinx.com designates 149.199.60.83 as permitted sender) receiver=protection.outlook.com; client-ip=149.199.60.83; helo=xsj-pvapsmtpgw01; Received: from xsj-pvapsmtpgw01 (149.199.60.83) by BL2NAM02FT030.mail.protection.outlook.com (10.152.77.172) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.3 via Frontend Transport; Wed, 1 Aug 2018 16:50:03 +0000 Received: from unknown-38-66.xilinx.com ([149.199.38.66] helo=xsj-pvapsmtp01) by xsj-pvapsmtpgw01 with esmtp (Exim 4.63) (envelope-from ) id 1fkuK1-0002LE-V4; Wed, 01 Aug 2018 09:50:01 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fkuJw-0004uj-RL; Wed, 01 Aug 2018 09:49:56 -0700 Received: from xsj-pvapsmtp01 (smtp.xilinx.com [149.199.38.66]) by xsj-smtp-dlp1.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w71GnpIM001636; Wed, 1 Aug 2018 09:49:51 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fkuJq-0004rx-MG; Wed, 01 Aug 2018 09:49:51 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 3/3] PCI/portdrv: Add support for sharing xilinx controller irq with AER Date: Wed, 1 Aug 2018 22:14:49 +0530 Message-ID: <1533141889-19962-4-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533141889-19962-1-git-send-email-bharat.kumar.gogada@xilinx.com> X-RCIS-Action: ALLOW X-TM-AS-Product-Ver: IMSS-7.1.0.1224-8.2.0.1013-23620.005 X-TM-AS-User-Approved-Sender: Yes;Yes X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:149.199.60.83;IPV:NLI;CTRY:US;EFV:NLI;SFV:NSPM;SFS:(10009020)(39860400002)(376002)(136003)(346002)(396003)(2980300002)(438002)(199004)(189003)(106466001)(8676002)(81166006)(50226002)(5660300001)(476003)(305945005)(36756003)(126002)(478600001)(11346002)(63266004)(486006)(356003)(2616005)(2906002)(81156014)(76176011)(51416003)(4326008)(107886003)(48376002)(106002)(186003)(54906003)(7696005)(77096007)(110136005)(16586007)(446003)(9786002)(336012)(8936002)(36386004)(47776003)(316002)(26005)(50466002)(426003)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:BL0PR02MB4449;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-83.xilinx.com;A:1;MX:1; X-Microsoft-Exchange-Diagnostics: 1;BL2NAM02FT030;1:71d6wl3DXobYy4kuCBcXsRx7RWrdMQl1TSMzo0mZRU+ZW1GbEUOH7e5OYKipWbL0jzfRRlP5GWvfAVqC58SU+yIA116v5ZQsEwZC6ELRfnmKutvgUiRDVl1hPNSk9zL1 MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b532f728-c342-468f-e1a9-08d5f7ced4b8 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(5600074)(711020)(4608076)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060);SRVR:BL0PR02MB4449; X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4449;3:BUtZIitqc3EpM6TAVn48VHDNvjDdxkF22UnXodjd6jU2UPy+5ynVFsodT4bjOUzRX9ApKzyoW92qK6QLZLmv2tBuN7+inv1TRorz/yHZ17OeAdv3LyO+ZY4mwAVkip8xya21YVgRki/ebzcg8I2hQywpuqilqMyzU9iAWJ6J6d1gXtuuaFhQfixats63qXBoIm+dNEG+HBePGMjJNcC6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sxKMC0K4dxtz+NrvokYGaUSizNn371XQtakMUl9rsEid62NqAKd/YjFZ328f821y/RGx+FOwo8jIMqj5cyWGrwPF2820uiWrGLMLHuXcKIWCdngTnGymwpUYGp+xsdFaxauYjcWTeYHKoNTlA44TJaKSvuJRKmiSEayTBBRjcdEvLuR/rsATSd9lZ0O5n87iJCJii51qKI/ka3X5oLKt9j0Wh1YRKzpTekJo3n X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592)(211171220733660); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231311)(944501410)(52105095)(93006095)(93004095)(3002001)(10201501046)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:BL0PR02MB4449;BCL:0;PCL:0;RULEID:;SRVR:BL0PR02MB4449; X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4449;4:hXH+bOFsVoYCqhM1tnH/iZJLni8d4OrZJP32poehq2ug5yL1z5Nt0MAv2cfDTQo6rr+6DOlTAkT10n9A3jZpD3OvS+iRFrA5BUeXnY8O7ZkY249KztXNeRB3hZuQPofORuZSdX/g+/yGluN+JHAR9iv35QGs43FkXs07Xzo1sw19ic5U9Zc0AgPFdnmVA6IBGaT3tLn3Oarc6KwLV91tkV/7mZiIOtxZWch75SGMVdToOYyCC83YyDxP4TmET//SK6FCDKI1SdKYF57QM3ELrnNcYBfPHa73rBC77+n3N239otU0rajql+g4zjogioF3Y8kYvhRgqKmz81tBJBL7Ys0ZgRFA8btj+y0xtTeNGhY= X-Forefront-PRVS: 0751474A44 X-Microsoft-Exchange-Diagnostics: 1;BL0PR02MB4449;23:YY0LtyXHG2gKBTsSv8Agn//4AdO23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PYewI6mKPEjo44a7eSsMVrItVKXSQE9vIGcu5NlQh/OMw7M/iJSBRq/YAEqlGglDC6ajmkpt29nJxRYfNwOFfRT5oHBORzJpST1ok5h+VjJDQRM4r5effx97Xv/+06zqXNAb9n51yxeypiZFfBPgbskmB0Y1JNhFoyfn2tGslrnftvzYifIj2W35yJL/FSnX59xait0TYfyA/8i+Zj6lwLOuvIJ+n3dJ SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Aug 2018 16:50:03.4814 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: b532f728-c342-468f-e1a9-08d5f7ced4b8 X-MS-Exchange-CrossTenant-Id: 657af505-d5df-48d0-8300-c31994686c5c X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=657af505-d5df-48d0-8300-c31994686c5c;Ip=[149.199.60.83];Helo=[xsj-pvapsmtpgw01] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR02MB4449 Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Xilinx ZynqMP PS PCIe does not report AER interrupts using Advanced Error Interrupt Message Number. The controller has dedicated interrupt line for reporting PCIe errors along with AER. Using dedicated controller irq number for AER which is shared with misc interrupt handler in pcie-xilinx-nwl. This irq number is set using PCI quirk. Signed-off-by: Bharat Kumar Gogada --- drivers/pci/pcie/portdrv_core.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/drivers/pci/pcie/portdrv_core.c b/drivers/pci/pcie/portdrv_core.c index e0261ad..fa9150e 100644 --- a/drivers/pci/pcie/portdrv_core.c +++ b/drivers/pci/pcie/portdrv_core.c @@ -264,6 +264,10 @@ static int pcie_device_init(struct pci_dev *pdev, int service, int irq) int retval; struct pcie_device *pcie; struct device *device; +#if defined(CONFIG_ARCH_ZYNQMP) && defined(CONFIG_PCIE_XILINX_NWL) + if (service == PCIE_PORT_SERVICE_AER && pdev->sysdata) + irq = *(int *)pdev->sysdata; +#endif pcie = kzalloc(sizeof(*pcie), GFP_KERNEL); if (!pcie)