From patchwork Fri Aug 10 15:39:37 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: 10562865 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 0797514C0 for ; Fri, 10 Aug 2018 15:45:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E5F3A28518 for ; Fri, 10 Aug 2018 15:45:20 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D9DBE286C5; Fri, 10 Aug 2018 15:45:20 +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 258E628518 for ; Fri, 10 Aug 2018 15:45:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727662AbeHJSPf (ORCPT ); Fri, 10 Aug 2018 14:15:35 -0400 Received: from mail-bl2nam02on0081.outbound.protection.outlook.com ([104.47.38.81]:48192 "EHLO NAM02-BL2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727422AbeHJSPe (ORCPT ); Fri, 10 Aug 2018 14:15:34 -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=X4JzRgS6Do/LAuM/TyGaO4Mk1zC13x8arDhESBMQAKU=; b=JYJHGsGkpNuqzIUD84IXIkTgSLOnGlMdjnhD8mCWT2OI5oATP45uIijd76ufXKhEZuqgIsX6vop7fLB3b24g5LNE2hUv96NZ3mbg1edlWGOk05RUt9qq/s8fE5nQZ5poubzrk56/cxlzEhBdwQD6y/z0RIBrKY7sC9fBfAZNFEE= Received: from DM6PR02CA0032.namprd02.prod.outlook.com (2603:10b6:5:1c::45) by DM6PR02MB4460.namprd02.prod.outlook.com (2603:10b6:5:29::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1038.19; Fri, 10 Aug 2018 15:45:08 +0000 Received: from SN1NAM02FT051.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e44::201) by DM6PR02CA0032.outlook.office365.com (2603:10b6:5:1c::45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1038.21 via Frontend Transport; Fri, 10 Aug 2018 15:45:08 +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 SN1NAM02FT051.mail.protection.outlook.com (10.152.73.103) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.3 via Frontend Transport; Fri, 10 Aug 2018 15:45:06 +0000 Received: from unknown-38-66.xilinx.com ([149.199.38.66]:45990 helo=xsj-pvapsmtp01) by xsj-pvapsmtpgw02 with esmtp (Exim 4.63) (envelope-from ) id 1fo9b7-0000H9-UJ; Fri, 10 Aug 2018 08:45:05 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fo9b2-0006lu-RD; Fri, 10 Aug 2018 08:45:00 -0700 Received: from xsj-pvapsmtp01 (maildrop.xilinx.com [149.199.38.66]) by xsj-smtp-dlp1.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w7AFivLB007795; Fri, 10 Aug 2018 08:44:58 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fo9az-0006kA-9h; Fri, 10 Aug 2018 08:44:57 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 1/4] PCI: Add setup_platform_service_irq hook to struct pci_host_bridge Date: Fri, 10 Aug 2018 21:09:37 +0530 Message-ID: <1533915580-31805-2-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533915580-31805-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533915580-31805-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)(396003)(136003)(346002)(376002)(39860400002)(2980300002)(438002)(199004)(189003)(51416003)(47776003)(76176011)(50226002)(107886003)(4326008)(356003)(2906002)(36386004)(48376002)(7696005)(50466002)(6666003)(305945005)(36756003)(8936002)(9786002)(106466001)(106002)(446003)(16586007)(126002)(110136005)(63266004)(8676002)(478600001)(316002)(11346002)(2616005)(186003)(81156014)(81166006)(426003)(5660300001)(336012)(54906003)(26005)(486006)(77096007)(476003)(107986001)(5001870100001);DIR:OUT;SFP:1101;SCL:1;SRVR:DM6PR02MB4460;H:xsj-pvapsmtpgw02;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-100.xilinx.com,xapps1.xilinx.com;A:1;MX:1; X-Microsoft-Exchange-Diagnostics: 1;SN1NAM02FT051;1:HZ+AHAN06TLtb1MMFhkn/PRkuvyRTadtsns7aYW2CSeHqnehOfXJ5wTjdzqU0EgH4qWu0HqQ/exuieoR4t+inPLZFavaApNJJpv1wTMRjlfp6DqOPtpBC9nddy/tUKDg MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f6ffd4fb-6bfd-4a53-d801-08d5fed83fcf X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:DM6PR02MB4460; X-Microsoft-Exchange-Diagnostics: 1;DM6PR02MB4460;3:YnmZsfQ1fERanQUxrF/b7hkomKBsmOERzBAobYPsoLKU2d8vCgWZEuGPt5uHKIXsEG/3hU+mXC1+blIGhDpoD3TYMKEuvX28wJbPYmXOK9C5+w31R8csscao00cnFDRwrSLx7kos/3rItyjmeJWkuV+PkrJlabgeZtp4E1dy+QWQaqyRKbwVOvMfaZDBgds56RitntrosjsJx2vFudBoSF3HI9eLV0eGVdSwkvsHTEHTxRMvbEsKBghjmXgWMy2eBl4TJClkagxODGwfiEQQBJRg7bJV485jxR4ug0mbtxyaowW5mMpKRd2Re9KgARkl6RPIWgIwc65lldPldHnRRRMsjJNKhiaIF8M6QsbDAHk=;25:VWapaYOAwcIC3+7IE6TUUmeSG9cBJ2hAqYIiC4G0VzJ5lLngwtZTVGo3LfIcpOV/3+0ZQcUFhzLs6MnUh+zCQ1K1xptLQbYWT2Ybc6sszd7iwH9ccNZFP7KkdHiXDjbyBsxVMJxfZleu9/IqfibCMYO5M6/pJpKUwHsUw8t89jSq6Uo/LV6X+Mt9PgDyjtTf4keiWC73nZO8Z0f1pchc2omIxY8cE5k9TPOOlSJH+tsDmFFTmPI5deciDA1U2rsQ9M5nKPjN05Ceo3FM8LAjNLceCuObu0AxTdcuD/H0iL30xX7izPSvN/6ZX/QvVZqloP6cJQVKtFYLT82KBAi9Jw== X-MS-TrafficTypeDiagnostic: DM6PR02MB4460: X-Microsoft-Exchange-Diagnostics: 1;DM6PR02MB4460;31:uO9VdSEZvxEtGUaIkktTJSxVFWk6GRwGaSbJgv0Q1i3ufPxe4w25xobAi68tvP+wha8NKdmUM6FUV3Oy0FDXO+znFDIecRG0Gz/ozJ4slNouWLzFx9JkQ8qqCbGmcJPCZ9oGviq4FN1xkugi5kKJWRUL2ERQibOM/7yVllZvKb5HAqHly4Ay+B+9AI5mYUiIXQ0KLj7Hg82DAQ3kqImam3jtCqBeCiQawrqUp8Z3m/g=;20:FvJ+O+EsPpaQnAvrT1KCuFQqdBAsCmvLbMn5eaBvpPBpEQZ8Ce9WrPRkTA8JCBjICFuUzKPSLKZnmJxiOscrcJfRv+VIwTfCDRH5E0706HABXK19VlQ9vSdceeA5oVB94E6n0FG+X2hTNT7HCp2NrWxx8KEZEEjtBwXA9/o9NpsI7kw3G9hbo/YwpqDENkzcgQUqWJDhhs0oUIuNlW/NGMKHiFJUW8MIzqARiUYT/RmuXvyT9Ee3R77Zke5ZgYDXqBZkpxjTNbeLicJCGTEZ/0SOSxP+oKA1CFiYyxi3ukaEhq87oW90EzZbbxMLpDJ6qRMWMEO+oqTI+Eu1wpCfYopNsNKUmc43wUqNHC8rdHe4UwlmsIGQEUtpn5CZIPJafBtADHtVyKlYnSibec7s3d4RX/n1xUzBz4vtRR8vrNwV3CREqjvl6zsjCpRE/LMDnvVBHiPFXD61AF+f1WdAV1C8RMdEUiEUdlsef9nnpqkUe1/gP+JvU/roiDCSh3HV X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3231311)(944501410)(52105095)(3002001)(10201501046)(93006095)(93004095)(6055026)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(20161123562045)(20161123558120)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:DM6PR02MB4460;BCL:0;PCL:0;RULEID:;SRVR:DM6PR02MB4460; X-Microsoft-Exchange-Diagnostics: 1;DM6PR02MB4460;4:ShuYbdbpicH/g3mhtAHz8vGnSwP71w3gZ4MDQzFG4ZC7gN/A8P+IgaGbHzqHuzzHgyHEGG9+Bf4Wm8VAotOIhDahVmGEkJg8UO+cV3MBP/1S2XRpMY3dQOSj4F7LNIaCFP1/AuX2ujOBRFo/ghgjF0QpsPa2rAO5vMBhnhX40WVAbC5ufwfu3OtbfUe3uMUueS7X4zqPtqTjqjp7XrrGaYTshoLACQMA3uB/ZMQiXe7caV30VFgiw69Lx8UYpvTtjrlnuSyh3svZHoLVPm53AzvFTZbkIw96DQVGJmNJJrd3hLOqrnlXddllBSACYHjK X-Forefront-PRVS: 07607ED19A X-Microsoft-Exchange-Diagnostics: 1;DM6PR02MB4460;23:X7w6R1O1J44AnAAdAXdiecgmW4+g4Jq80hFVEA4FVPlTLyI1HBJl59uw5YYd0fpfbTitpEYmvDrmvlyYbkwcSTeIoszsiNEo2cvZ7ZB+49mRwtVFTQHbcNXEOzHCAuNK//ZWKgdVUwFfcGzyIozJC9KFlPEkoK1SRbtUHgV9OIuIVbuXr5H1NUjNsOCRNasnzz9Fi4muGC7j/mkBdA4LiM6q3dmJ1CISUE6jhd3vv3BHzmJy2g6D/sx8+0CMoI/r1aegCKnDdnRiQn8uXZgrmwwApSQApCxaDznd5M6EMeKHqwU/gZWF84vBGE9VoADYMGI5Ws3d2VlQ1nubLKwdXxSFDZa8w8zg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atorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Aug 2018 15:45:06.8207 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: f6ffd4fb-6bfd-4a53-d801-08d5fed83fcf 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: DM6PR02MB4460 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 Add setup_platform_service_irq hook to struct pci_host_bridge. Some platforms have dedicated interrupt line from root complex to interrupt controller for PCIe services like AER/PME etc. This hook is to register platform IRQ's to PCIe port services. Signed-off-by: Bharat Kumar Gogada --- include/linux/pci.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/include/linux/pci.h b/include/linux/pci.h index 340029b..c28f575 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -470,6 +470,7 @@ struct pci_host_bridge { u8 (*swizzle_irq)(struct pci_dev *, u8 *); /* Platform IRQ swizzler */ int (*map_irq)(const struct pci_dev *, u8, u8); void (*release_fn)(struct pci_host_bridge *); + int (*setup_platform_service_irq)(struct pci_host_bridge *, int *, int); void *release_data; struct msi_controller *msi; unsigned int ignore_reset_delay:1; /* For entire hierarchy */ From patchwork Fri Aug 10 15:39:38 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: 10562867 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 1993C14C0 for ; Fri, 10 Aug 2018 15:45:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 07A57283E2 for ; Fri, 10 Aug 2018 15:45:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F007328574; Fri, 10 Aug 2018 15:45:23 +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 76632283E2 for ; Fri, 10 Aug 2018 15:45:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728229AbeHJSPp (ORCPT ); Fri, 10 Aug 2018 14:15:45 -0400 Received: from mail-by2nam01on0046.outbound.protection.outlook.com ([104.47.34.46]:59524 "EHLO NAM01-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728220AbeHJSPp (ORCPT ); Fri, 10 Aug 2018 14:15: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=CTWN8O1xjIHsZtDgTKpfk9Fw/JRSsjKb7bVvz4rTgcw=; b=dZSImeMHaerBACCq3rLjLui369Lq53iTmg0ejMt4hxRGoQYJuktiLAfmw5Z243B+eqAvqNWVrw4AwVxYIyoGyTG4vdNuqcpYIwMt+KIssU6b8mivbr+1u9WM5d6wJD1LiOV+HdRpVpRmV61BqOgrs1WstUZ6xKg2FfQR4C2twSI= Received: from BL0PR02CA0102.namprd02.prod.outlook.com (2603:10b6:208:51::43) by BYAPR02MB4453.namprd02.prod.outlook.com (2603:10b6:a03:57::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1017.15; Fri, 10 Aug 2018 15:45:19 +0000 Received: from CY1NAM02FT056.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e45::202) by BL0PR02CA0102.outlook.office365.com (2603:10b6:208:51::43) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1038.20 via Frontend Transport; Fri, 10 Aug 2018 15:45:18 +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 CY1NAM02FT056.mail.protection.outlook.com (10.152.74.160) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.3 via Frontend Transport; Fri, 10 Aug 2018 15:45:17 +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 1fo9bI-0004wJ-BK; Fri, 10 Aug 2018 08:45:16 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fo9bD-0006uk-82; Fri, 10 Aug 2018 08:45:11 -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 w7AFj0Jc007803; Fri, 10 Aug 2018 08:45:01 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fo9b2-0006kA-Fb; Fri, 10 Aug 2018 08:45:00 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 2/4] PCI: Add pci_check_platform_service_irqs Date: Fri, 10 Aug 2018 21:09:38 +0530 Message-ID: <1533915580-31805-3-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533915580-31805-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533915580-31805-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)(396003)(136003)(39860400002)(376002)(346002)(2980300002)(438002)(199004)(189003)(5660300001)(16586007)(110136005)(9786002)(478600001)(316002)(63266004)(54906003)(5024004)(126002)(476003)(106002)(486006)(106466001)(6666003)(2616005)(48376002)(336012)(50466002)(36386004)(446003)(11346002)(47776003)(426003)(107886003)(4326008)(2906002)(7696005)(51416003)(356003)(76176011)(8936002)(50226002)(36756003)(81156014)(81166006)(8676002)(186003)(26005)(77096007)(305945005)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:BYAPR02MB4453;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-83.xilinx.com;A:1;MX:1; X-Microsoft-Exchange-Diagnostics: 1;CY1NAM02FT056;1:TsbpoHC7TtELHSbLbgqHKuSIAuJN8383YqRM2z7KgmgXA8M3VovkgrNnKIBo6LSf/vRIs8Bl9rd/FPCPhVUmGZl6AXGzfwF6yyodogRtf6W590jUPXkUMIUXahnbjSti MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c307116c-a314-4a5e-8d1f-08d5fed845f4 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:BYAPR02MB4453; X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4453;3:nVr0AW3T2qqUKKmj54XWc1sHz+2BmFieVIMSb1b4aAdnYZKYih+z+vVnRxQ7Hy2+BdM3OMucvG0zVjAlcmPD/88xkAXaZt1tHrp/U0/D7bM2t9s4UGpGr0x12NvckVEussiyjesYhDDadETnRYIvE2SzaU6t64hhe3I+0XeRfrVSnBFfRQK+8+SnhV0lvgag9JfT6PyiojelJA7PI/ohYoKQGc6ucJN+S7uXdyZJNf2OOjL1pSPQulJMJUSTQhhE8fRDybzELzIaL1BWQfmjufYukk2be5NCOQb9eAhtbQzDn7et1pddSg8Z+FXioxUpyEwl+UmfQpH2uW73g2xG0Wkb+NfF9qCFGOJ1zvJ9hv4=;25:y7pWrvKQaduJB+aHspLXNuJz3ZChosgE7HUt8VoSYOZ7m6q17i2nwgIJes5DZwQ/EnRVgf4jT3DxwxbNQlqEi2Gmc27RYkjR3XHuR6XmXaC2rZN53cHcwP+dHJ2gPk+YqFalhD5mAnCcQPYqS1ARDz+0NHYC38qY3Vn8E//8UAawtnrLgw56sP5lGZzlIzaS2/p85fHaqdGVJVksONCCnLxr5Og+rgxagjI+n8PbotLg5ZqYOd1USBxuJ4KDROdjnzOjJxix6wOaltDtSPplBLglhYjKqaZAkajFeCMkagr9TMplzbwAHXMFbKJSpxC1oL/dSo02ohYpFy3V0LpNGg== X-MS-TrafficTypeDiagnostic: BYAPR02MB4453: X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4453;31:+MkcwrYcpokHDnWb761MNugCWXEBt/SKhFwlqMOqkDJXO5A6cw9cKifEPMYydiUKc1UY2dMlL2aXRCN8NyyO+R9SE6y3jNPnH4k3kXbZB3v9p9qutgKGslSwRi6grNG+Zb/gxPonLEYKzRAjoDNLTP3fOM4ma60DhSavw6DWf+ru3zPIUCBCCMfsqwYa8pjj7dg8NW5Kk+NIIFWCbVff9gxQG9XDIrg6ScnuP/R68+c=;20:DXUoZQGJZdCV26Y6NY1TCpdaxs6B2no2e59i4iGS9nYwlKoe87xlEXGmOe+0j7SnKvCpf8VK2osXM29RUM9j3DDx2oJFCpUf/aUOVv/rbGh2rHuYCcaI6BpLQZO84DmxN27Smt9RTSAH366i6JZLtRvHVenjvPdT+h+/4jrP7szdDzID9vBP00p9nN0lHJuSU4dpwY0auYfNk34X9ch+XY3JSumRlp+sdDu/TpZads9tzo1LJ/Omexv27qweXXLHXiTQSkTzhykOjh4KKLyjWqliwqY0OhXRiMNcis+LDutA+chVZxx7AXeNROxQHMKeURVgkEJ6ZJJB6ZNPNdrN82D27JIQRw+l7djbWafOCIl6HXM6Z+SOxbLXIcD2weZ3NVoJMOi3xtfIVbFXnwi7rmG68EplpR7D91Sd8Hwf9mLR+XMfjguRQeKElXXyBq1jt5iaYOSxhlYHAv2HPIZ9ti8ZLgsUnBJN2DQdlJMYoZzK5FLexOFZpWOIZmWvhm+L X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(10201501046)(3002001)(3231311)(944501410)(52105095)(93006095)(93004095)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123564045)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:BYAPR02MB4453;BCL:0;PCL:0;RULEID:;SRVR:BYAPR02MB4453; X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4453;4:EFL9U3i6WnPssre1iNpu3tS8NMfdQfULyafhTUF3NlIFqDW3tYkK8EC/OzYKzjo1UG6IA8Q9QBWJUiVzlPb3rnzKhjcbrcLOf9SfskBYJB/ZPVk2RuMW/pUgiSIyGU0RwJXWRZzN82v1arZEalrSZIqx/p3Huz3yaWw/DBGBAcKCzV5wa00dOABso/OdsVhdwopVFyqE23GUxiEP1ZeiV8YwnT5IYFbDYwP/9xpiEev3p+F6A6yISkETIS/zBUacX3KcR5KdWg29GWybl9shhpvLkPwFjXLNt3jjv0EwdNa/U4C2NHC1RlWREkLWGjcj X-Forefront-PRVS: 07607ED19A X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4453;23:R0QhJqg50AP+pxU/62k2sxsyEGO1pX8wQxTKCvunV4ZxfnYoplES58dYVFGH9M33NoOEw2sLCamH2zfq5wvVUV1tMHPULvbZ+bAKOHfqiVgFDT7C4b6eFmi/DrD+lw6od0ZbG1XWXF8x4AneAsrQ+aPekuR8Jm3HKpiZaxkVyhvP5KsXKHNt2ySZac1u5dX3fplPVOfVlRiDAoGlmnpO34DMq6didyHjTjEM0XjZsqcjtJeZxLDry51A2aU8X3K9fYvroaESE1m3K470wnfaBdhbXcwhb7IUMyjV4V5MagK3oY1yMhYDK6sPzL6bZ0eT5D/2IsVwBwlM8VIpjGYEXW7Ygnfy/rw9RWgmjBlgVDJJ8zA+DnH82V86X5+ni+OruODap+coE1Sm9JmidIlPHSF+ixZaYPnqI/W77iOZEViO3s4P/HwEqU+hz07jtsc+uu9PKNUelm3uUmd5IV86dafRRloFSo2rgFsUPcxRfec0aBo9ffnkMSwT0c8M6r8N7can6j1tTDfEl/xWD2i/Gx9JQJbkZH0MsNqMYELQHS0mDDJRW7K1rdPdJt2vTesDEFd0puwTYUcT8HMkdMc5MZIVeDT0C5RLXrEEB8yIMskMO1jja8Fne6tMmj0O6micgVw4o/oGiJTwNqttei1NyizwlUVPF9bqZraaPya5cdDObURYJyS06iEK5kYfQYJPfCKX1OhqfEJOi9xZvPv6pGIFJiSUozIsslmB0Dk9duCauldw/M4+4XJNBR1qC3gERl1Jl+AFVbawu2rG6fmDDhBwEQR2s4YKj+CKlj+L6gb5mMaLdk1b7/W10RenYcxPKSILLOxM4eXGpyp0TWpVyyZX4CgsS/oNOq2VKxDW/ctMt1lKdZKIJ5gPF7keWVlOXssWX81pOuxL5D29w3sHx6tWut6M/wRAPsfE/ofhMvcDok8h488ppUZzeJ1slNrrWe6dgdzemZZcGpmDRnG4fHzrC/ldQir05vdg3Q5ACEvf+vdEqfB2IXyPzDQOFKVYq96xnvA/0drQDo1xDYIcH/TzaaUolTb3zlzhpLdRq58dbVfKdmIsJenbeFf34ffyQXQtWVAwI21g4HeLr83hg6pULsut5urZtS0Q/+NKxDY= X-Microsoft-Antispam-Message-Info: 1gBoKsUQqhXa5iwAdNL0iJbDS4Yb5LzaoANeyZIaZAWS05h2Y6RtXFcz7sHMho+uGH3oWi8CTVE3j6ffvHVBCop19XzDAopHXukl0uaaSLZH7N9Dm75KDqiUCQjhribGTBElPy6f5jj/mGP1UZlSBc+LzHRY99gLFFSaejN4J0Dlj7P8XdIloMq5gs4wTgjG4VIevVZQWnvHrMayEojZLwTIpQhGMnJEzJvDwZAAgfQ4d0VhzlROBBm8X2THqlLrZjAeE7majF+lRytvZWXrU1gp/S23eddTusp/5nFgoPDZWNT5zZRzvAOYUMVWFhCAFs39dkk7et9m+nCuyKd9lgOH4nVyGQLc15ppXvVBGWk= X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4453;6:mLEFKo6cNInuOkj870XDXh00+/2M7nSsxIDeUA8w1k/Pz6R6LGaEqT6heIElKgs8EtPPJvraQoTsm7yCW0B83CNp1hC3GunTHBEKVo2pwf9nv7j2sheEl6eJ5Gk1MAln8oGjClz5wao+MXflLJ5bnGJVIGi89fPbdgRtgT20nPf1mecZ4BIih+vkc8hKalr8K+6uAXaEc4e0WDkR9TaR99uZDloXyXKPy5wThcdxdDz+z4cZ5sH/s/5j06cC/szvuW1zdDy61vBabcKAw4rYWWGHnsMnok00AtjUIne2mcOvT6+orN+Kdwhlqp4zZ0gj6/wE+gZwGFeTuUFYADXFt7Ubsl6uWV1WPYoUezagYtJ4n9bU8g6DqIhW5UYE7ZFtJZWsiNOgXzdIc6feXbunDadD3KupOiloLkHf/TAydWJIMLANm+oSzwRj/bWoHMgViR9MnjZaBBP3yV4aL2mF8w==;5:lA0C48/67PWxyx3+5H0hyOtLde2VSYjgSdmnmmpQDP81dt2d2RNkQta2eXG+XQeeyFJ9h+GPS7K31u+ZFekb4ChbmZJzeu1wRNlYRIbg0xPZ0FuYJTrokOpwekMW9GlaD/xOBfCKlyRoCWDL6grTq3+xmJhpC876xEvxbGJzVks=;7:H15THKgzcu33nBA5zdJnvWzXnJj98F+9YajvZFJw3SdTwYnkRYn3YBcfjXi0KQi5NxHlIqQMR0lo8O84aACtn4gsZr37LzlI2EknuPrbOLGg44t/BvoSw6XHut0qJlPP01JrvcPDaurVzG0WFayK8JoGBxbnz3MP1kzWmi6F2zFHRWP3FtZ58OZduBFwQqrHwecUbs072W/anJghcWS7B3xA4D9y5LTkY//YPy21WgvYJ1o6eshNLqinMrCYVqEO SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Aug 2018 15:45:17.1119 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c307116c-a314-4a5e-8d1f-08d5fed845f4 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: BYAPR02MB4453 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 Adding method pci_check_platform_service_irqs to check if platform has registered method to proivde dedicated IRQ lines for PCIe services like AER/PME etc. Signed-off-by: Bharat Kumar Gogada --- include/linux/pci.h | 24 ++++++++++++++++++++++++ 1 files changed, 24 insertions(+), 0 deletions(-) diff --git a/include/linux/pci.h b/include/linux/pci.h index c28f575..8eb6470 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h @@ -2271,6 +2271,30 @@ static inline bool pci_ari_enabled(struct pci_bus *bus) } /** + * pci_check_platform_service_irqs - check platform service irq's + * @pdev: PCI Express device to check + * @irqs: Array of irqs to populate + * @mask: Bitmask of capabilities + * + * Return value: Bitmask after clearing platform supported service + * bits + */ +static inline int pci_check_platform_service_irqs(struct pci_dev *dev, + int *irqs, int mask) +{ + struct pci_host_bridge *bridge; + + if (pci_pcie_type(dev) != PCI_EXP_TYPE_ROOT_PORT) + return -EINVAL; + + bridge = pci_find_host_bridge(dev->bus); + if (bridge && bridge->setup_platform_service_irq) + return bridge->setup_platform_service_irq(bridge, irqs, mask); + else + return -EINVAL; +} + +/** * pci_is_thunderbolt_attached - whether device is on a Thunderbolt daisy chain * @pdev: PCI device to check * From patchwork Fri Aug 10 15:39:39 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: 10562869 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 8E89014C0 for ; Fri, 10 Aug 2018 15:45:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7A56C28518 for ; Fri, 10 Aug 2018 15:45:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6D6C1286C5; Fri, 10 Aug 2018 15:45:32 +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 EB9BF28518 for ; Fri, 10 Aug 2018 15:45:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728508AbeHJSPt (ORCPT ); Fri, 10 Aug 2018 14:15:49 -0400 Received: from mail-sn1nam01on0055.outbound.protection.outlook.com ([104.47.32.55]:19140 "EHLO NAM01-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727539AbeHJSPs (ORCPT ); Fri, 10 Aug 2018 14:15:48 -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=L7tkekGIa17b1q0GEbZGGQoiXNe1EgzmuXzI5rXfVMA=; b=1RHVjlIVHlfX78WcIOQnGvAOJaAwYKvyNzGO/W1yKgO5j/h5hMlRCk/6EEoVO+884kmRlD6NbUn8yu2cu420Jeqq3fVJbzcHSO6ycqZ2vK/Qz5Gn/GGQno8lc9wgV0XcWWgCWyEe43hoXY6c5hDvkuQWV5lYaqZ2XzMo930/Dx0= Received: from BL0PR02CA0010.namprd02.prod.outlook.com (2603:10b6:207:3c::23) by BYAPR02MB4456.namprd02.prod.outlook.com (2603:10b6:a03:57::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1017.15; Fri, 10 Aug 2018 15:45:18 +0000 Received: from SN1NAM02FT064.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e44::205) by BL0PR02CA0010.outlook.office365.com (2603:10b6:207:3c::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1038.23 via Frontend Transport; Fri, 10 Aug 2018 15:45:18 +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 SN1NAM02FT064.mail.protection.outlook.com (10.152.72.143) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.13 via Frontend Transport; Fri, 10 Aug 2018 15:45:16 +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 1fo9bI-0004wH-3t; Fri, 10 Aug 2018 08:45:16 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fo9bC-0006uk-WE; Fri, 10 Aug 2018 08:45:11 -0700 Received: from xsj-pvapsmtp01 (xsj-pvapsmtp01.xilinx.com [149.199.38.66]) by xsj-smtp-dlp2.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w7AFj4lF025241; Fri, 10 Aug 2018 08:45:04 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fo9b5-0006kA-Jw; Fri, 10 Aug 2018 08:45:04 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 3/4] PCI/portdrv: Check platform supported service IRQ's Date: Fri, 10 Aug 2018 21:09:39 +0530 Message-ID: <1533915580-31805-4-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533915580-31805-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533915580-31805-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)(346002)(396003)(376002)(39860400002)(136003)(2980300002)(438002)(199004)(189003)(356003)(2906002)(2616005)(476003)(486006)(48376002)(4326008)(186003)(63266004)(77096007)(36386004)(26005)(76176011)(426003)(336012)(106466001)(6666003)(107886003)(126002)(11346002)(446003)(5660300001)(47776003)(8676002)(81166006)(81156014)(305945005)(51416003)(50466002)(7696005)(50226002)(316002)(8936002)(106002)(36756003)(54906003)(9786002)(110136005)(478600001)(16586007)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:BYAPR02MB4456;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-83.xilinx.com;A:1;MX:1; X-Microsoft-Exchange-Diagnostics: 1;SN1NAM02FT064;1:BQkeLGrUnitluIFbh1tp58aA4haPQqd2X06CeMyzBSZbR1XZ1f/sdckCxVAdxUArKzfRH9jsebHkjWTjh4pu/SBBDU2lTJ4chnamE9QcXi/v0ZO5AS0JGjDypvFCWdx+ MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 392f49fb-780c-4bd6-9c77-08d5fed845c2 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:BYAPR02MB4456; X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4456;3:aGmVR4edfcgBo5YRDQlCikkl/v1BEGrkUcoxCOY99NQYJrqB7TeDSfsD5wtl2r8AQaZiayoqr1IbCzNkMBtdFG0zOOA0UqeBpNyIiV28Da0k7DTzjciD9v5W7xM2cm5euUlb+Vu8NRpCV8MOzTpnQwxy3e5KF3UoqGZNxa9rU7m3Y0AB/1Md0mpX88aQnS8VONOaxkBeslN5FZfeo6A231SK+T0dhL7mzFugYUGx1K1S1Ykbv78pqn42qvS5DlpKNlKmlORzr2v1PlMYYA4Y5AdWQdlWsM0ly2uNHmcqrQpgJkUcD39FTs+kUdhgDidVZL90vQTh2p2HPOp/0xZUteKjM2PiD+CG+SUxDBIcYBk=;25:r+PZr7KocN8ngVf7nJ63ZXx1uiSwWvxqZ9ZxnTBB+KAZZRR9GIXwgdE0WWX1SBnFnIZ6IeGI/zZa7xM34inbllmhg5mZB3DUUldgak0qKitL5OTJfweyOMPzsFCoQHYHWhsT6nGJ1VyUnFjfIxcZIv4ln+8cwAsJcBvH4UOFDLC7tovRIY1ylzg7Fd0jptMHll2KZOS9acTZOuR2bhviYUx46Vv/YzLoj0O2sIEATAtAOX3FXqKNaXjxL6B+IyYGv4KFYOc0sYE2aDwvaggRPnC05oyL2sgzaq01W+2/dEjjsgce1S7KmynS2lwyav/EqzIQOt6gMHaBuOVBkWyy4A== X-MS-TrafficTypeDiagnostic: BYAPR02MB4456: X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4456;31:TYu7X6PEQLdDKpe3tyC4+rDgCUzNXSGBgqVsYdh9gLDbuPM6E3MI6wQBJIA7kkHQ0UNpYk0zktPUVGtNjrKuhCGlT00vuaRhRWzYk5KwB1iy55oFDD+AbsdIvpUiomJi42UhkcTTfLyZgc/37RuTdxsy2em/hGO+nRk4lRmmbW2k9ONwjViLLcxy6x+VqcWygA+RJcP8Q8CpimDH2DM/e8HCLIt9KvygdPc+EfiPeeg=;20:JSCi5cIROIa39VJgteaXD6WFvMQKDXWS5UCCnHXGuRKn1OZzBp6FvD47XmHv4dwvmo77TQ7NZndTHjNC5VzZvI+kxUlyvpgWj3noMkd+B1mG7QPbJtH0vZFoNQZZSwfKYQ4bDKIHeG3tQujkFSNj0sSB9ynXJ9Go4mKgywKDXgmiueNxb4MseL8Ul6vGZnTB1oRWkYh7Sph6DZE8bhkujsW47hVl2llvv7HSby/EEcAwmFMFLL4Rfm1QRo9MimP/cTqP5HCi/VDp6W9TdIeHQvPMGitEP6OD9BPDws45ECiMkwbSvLHZfTWhJfibJZNFXSKrlB/ZezyTZdUzcXT+u1tPrvx+4cYvAewGorHyDQ1qBqg0En98wgojyUU8kacqtHm1wp7yhKwaEDdL8vrrqwcbiNwdsXdcEYoiJvPKGLv5wdIYoHPxqor89y+LM39/kGMXhC+TOAmoVmeZvSod1Pz5gWRV4RQJzqI11fEv1/IF2VAsUFVg78P9Foy7s9aL X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(93006095)(93004095)(3231311)(944501410)(52105095)(3002001)(10201501046)(6055026)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123564045)(20161123562045)(20161123558120)(20161123560045)(6072148)(201708071742011)(7699016);SRVR:BYAPR02MB4456;BCL:0;PCL:0;RULEID:;SRVR:BYAPR02MB4456; X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4456;4:FatQXnkgkDfXtMa60f2Eju7dWPddBGh+F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rln1iWvjpjxPd7lX3q7M2IDDRDLvmeqwrT7jGVpMN77yieNf8Fn5KAzvPnQWjHH3DBe07tz3X6VWe9rc6fb9aferVI2yJEy8zxbJbm4rV5HhkJKG96SIbPT5TDimyt8VWFNs6CCMBPJq8MPpMyo62hWSCeL+m0x3qew1iLFqHKXNyxcmSJVncHqEG84okG4UbYKq+dfjpLRVCRWncOIMjFgosiodE9upvk3rOFgUcvxX6eyZZM8Vaol/Bw1EOuzcOJ4mYyOUzKcq94Fzpss9peZRAJcANDwDfHi73qAOJbwfn30qxkH5H90O2/krboUXezJF1YFN8f05L0INU4MCZpwYVXvl2gY9OlFA2WgytMrfUoRNl7+nMgJxvuiyO3gUeA== X-Microsoft-Antispam-Message-Info: DtjrdhXfJ45QW6j3xnfKp6Y1T0ztmKw/6H9dfecy9UYmGXY3W1LJuqyk/if7hn3SNSUNq1FUDH3HuHyhxc1PiUhmfL79AlbfCZe5ZDNjISfgoapt7Cu5uQS0lDvB6dtmFS610mJpVKXGw4dEH+oMd9YI5samt9t+UqC6Hokm2rfBP05vi3XazSxQpOEQs0bcqNIjnkRgE83/B64Cuek3iQqymWe2y8YAr9HmjMARGJ2qfZyFcmEwFHYtG5v/zV9CjXicoa0yEllspdsLZ3dWrTL8B/6yX4/Fklby0mIrNaWrapekZ6Row6fAyLp/dvLVVn3w9RwqgEy/fI3O2ZvlDFDhWSu1nM0avzLlWbeCVLo= X-Microsoft-Exchange-Diagnostics: 1;BYAPR02MB4456;6:gVlx5u5kT9J3lX7JPXyeVQQbOshukkF6W4in0TbHsOf1cTu33iJ0yXAR4hPt8EMsaujPrShUlzxpmuTkypYfJbdQGeo2aFPCFWNpvMPSotNFZubQVM4alPakJWEWipzc35Hu/OeGPI9OakLOOGu5Txqs6Wb5p0zGLciHLSgqA/53pNC5BenZ9v72QgsAvIWmfdosILDXAB7H3sn0u4r4mxm/Ggj7DVMdlWCrtUjeqTewbG11To0njtiiyyXFFU1afjIabucUT88475+4fX7TgiButpwrFKVyAlJz0lSgvBZNkPlJ7nGuml7WjpS2drMDBgJjv77gnVTKG7l43oyVfgj283eadjO2RZJJ915WGZpdcqWvBkrfXazLF1WZ9KPR/LrilgM/CLH4Ia5gna1V5z7FPGoOkNxBxlhjJs8G+TxGucnYcxDUzSMXIMfQSfGL1Bu2rqjNrwYTiefzu4ktew==;5:GCzvIbwJznjXTU2q7DxEZwhrgN+j83Hw1Hkz8DwGwbFjWJ+Sb9j8Z1kdUfasSF1GnC/Z90FkJu/DubgndHItUCaTaAyCls7Dz3kZxjrnWKPivPwnrKaUlaVQQwOtEMw83nfv4AZKgXapUuLQyqa+W9X6b6Cqh+Y2m1DCxgSOpzw=;7:sooqOuPLyCXJ5SFg/XNgFqHmFdfrXW/5kE4Zsm/MQVkh6W8U4sBrTcYhkhEUCB4MdJh0Esqt5Ml5oTbPFPp1Qh4VDS1Id1IH7I4tS3a8ITt16o+Umd4JUvp99GrNx5ovoqVNHQGhpLSuxFaIaE0gK15I+bSGTg8qHtoVAYnk0SpbLmxskDl5QVl5SJ4mIOZh6i6PCao9WaHCTu0oBRigXo8UZwVqSW983PWwHkDENByGT8Xni8o3pzvO57XgHrNo SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Aug 2018 15:45:16.8003 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 392f49fb-780c-4bd6-9c77-08d5fed845c2 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: BYAPR02MB4456 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 Platforms may have dedicated IRQ lines for PCIe services like AER/PME etc., check for such IRQ lines. Check mask and fill legacy irq line for services other than platform supported service IRQ number. Signed-off-by: Bharat Kumar Gogada --- drivers/pci/pcie/portdrv_core.c | 19 +++++++++++++++++-- 1 files changed, 17 insertions(+), 2 deletions(-) diff --git a/drivers/pci/pcie/portdrv_core.c b/drivers/pci/pcie/portdrv_core.c index e0261ad..a7d024c 100644 --- a/drivers/pci/pcie/portdrv_core.c +++ b/drivers/pci/pcie/portdrv_core.c @@ -166,6 +166,19 @@ static int pcie_init_service_irqs(struct pci_dev *dev, int *irqs, int mask) irqs[i] = -1; /* + * Some platforms have dedicated interrupt line from root complex to + * interrupt controller for PCIe services like AER/PME etc., check + * if platform registered with any such IRQ. + */ + if (pci_pcie_type(dev) == PCI_EXP_TYPE_ROOT_PORT) { + int plat_mask; + + plat_mask = pci_check_platform_service_irqs(dev, irqs, mask); + if (plat_mask > 0) + mask = mask & plat_mask; + } + + /* * If we support PME but can't use MSI/MSI-X for it, we have to * fall back to INTx or other interrupts, e.g., a system shared * interrupt. @@ -183,8 +196,10 @@ static int pcie_init_service_irqs(struct pci_dev *dev, int *irqs, int mask) if (ret < 0) return -ENODEV; - for (i = 0; i < PCIE_PORT_DEVICE_MAXSERVICES; i++) - irqs[i] = pci_irq_vector(dev, 0); + for (i = 0; i < PCIE_PORT_DEVICE_MAXSERVICES; i++) { + if (mask & (1 << i)) + irqs[i] = pci_irq_vector(dev, 0); + } return 0; } From patchwork Fri Aug 10 15:39:40 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: 10562873 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 12A2814C0 for ; Fri, 10 Aug 2018 15:45:55 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 02B4C283E2 for ; Fri, 10 Aug 2018 15:45:55 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EA42928574; Fri, 10 Aug 2018 15:45:54 +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 F2CEA283E2 for ; Fri, 10 Aug 2018 15:45:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728335AbeHJSPr (ORCPT ); Fri, 10 Aug 2018 14:15:47 -0400 Received: from mail-bn3nam01on0043.outbound.protection.outlook.com ([104.47.33.43]:19900 "EHLO NAM01-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727422AbeHJSPq (ORCPT ); Fri, 10 Aug 2018 14:15:46 -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=5qwHBlGQWEgGgbuibNm/2oogv9eT2EkZpa1U3I1FmkE=; b=ZQTDbj1dQNB8tQEz5N4B/5vD2pon0v/Komi0yM+7UUkwqLC6/8l9U6Xhrzj8sXkDlXpW/48XqTx3Dx3x8h7uAkokBC6tY/8Cnh1UvPymP/e23CaH0DPuD3sxzC4zC8bzWhQDutGrgE96541wlTkyOcmY1dU54iOEUNhIbkt1h8I= Received: from BLUPR0201CA0030.namprd02.prod.outlook.com (2a01:111:e400:52e7::40) by SN4PR0201MB3518.namprd02.prod.outlook.com (2603:10b6:803:44::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1017.15; Fri, 10 Aug 2018 15:45:19 +0000 Received: from SN1NAM02FT006.eop-nam02.prod.protection.outlook.com (2a01:111:f400:7e44::202) by BLUPR0201CA0030.outlook.office365.com (2a01:111:e400:52e7::40) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1038.20 via Frontend Transport; Fri, 10 Aug 2018 15:45:18 +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 SN1NAM02FT006.mail.protection.outlook.com (10.152.72.68) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.1038.3 via Frontend Transport; Fri, 10 Aug 2018 15:45:16 +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 1fo9bI-0004wI-79; Fri, 10 Aug 2018 08:45:16 -0700 Received: from [127.0.0.1] (helo=localhost) by xsj-pvapsmtp01 with smtp (Exim 4.63) (envelope-from ) id 1fo9bD-0006uk-3P; Fri, 10 Aug 2018 08:45:11 -0700 Received: from xsj-pvapsmtp01 (xsj-pvapsmtp01.xilinx.com [149.199.38.66]) by xsj-smtp-dlp1.xlnx.xilinx.com (8.13.8/8.13.1) with ESMTP id w7AFj8Aw007910; Fri, 10 Aug 2018 08:45:08 -0700 Received: from [172.23.37.224] (helo=xhdbharatku40.xilinx.com) by xsj-pvapsmtp01 with esmtp (Exim 4.63) (envelope-from ) id 1fo9b9-0006kA-GA; Fri, 10 Aug 2018 08:45:07 -0700 From: Bharat Kumar Gogada To: , CC: , , Bharat Kumar Gogada Subject: [PATCH 4/4] PCI: xilinx-nwl: Add method to setup_platform_service_irq hook Date: Fri, 10 Aug 2018 21:09:40 +0530 Message-ID: <1533915580-31805-5-git-send-email-bharat.kumar.gogada@xilinx.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533915580-31805-1-git-send-email-bharat.kumar.gogada@xilinx.com> References: <1533915580-31805-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)(346002)(39860400002)(376002)(2980300002)(438002)(199004)(189003)(107886003)(50466002)(305945005)(36756003)(47776003)(486006)(77096007)(26005)(126002)(2616005)(476003)(4326008)(186003)(2906002)(11346002)(106466001)(51416003)(76176011)(7696005)(336012)(446003)(63266004)(426003)(478600001)(48376002)(110136005)(16586007)(356003)(54906003)(81156014)(8676002)(81166006)(106002)(316002)(36386004)(5660300001)(50226002)(9786002)(8936002)(6666003)(107986001);DIR:OUT;SFP:1101;SCL:1;SRVR:SN4PR0201MB3518;H:xsj-pvapsmtpgw01;FPR:;SPF:Pass;LANG:en;PTR:unknown-60-83.xilinx.com;A:1;MX:1; X-Microsoft-Exchange-Diagnostics: 1;SN1NAM02FT006;1:h+F/rlrwwD8c2AZiDCGUWG7oBR7BDiTQm26qSGpQ7R+/biQGtppE3ZOkXRh8GGeO94nEqSmhHxOTRt9KANLMRvkAbG+eD3DzrkNA656iMHQf5LuiWzzx/H2Avy35f0zt MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: da58ba00-d572-4f57-d3df-08d5fed845de X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989117)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(4608076)(2017052603328)(7153060);SRVR:SN4PR0201MB3518; X-Microsoft-Exchange-Diagnostics: 1;SN4PR0201MB3518;3:TWomFYLOm3nAotVBnDYN9Y+nSdn0ZrDsRmhR19wowKfD0P0Cx9svZE3G7blAV62hscAhMBuF66d1lm9OeBl1i4KAuZeXyPMa9wsVf2QG1Q3OiXzC7xlLlYLmEKKgO7jiV7rbIIwhP18TmLBiTTptpDyzwg39IkkTUJmLIu2EEFyt1K3lYo3xc3Mh3+uaZFiVosxH2Q++xTtA3zSZ+KAlItkTtxPccQAVWXC3G1S20nbXZIcrvb4FiFxNJ54slEdV6btE+di4gXjxhwC9xZxv6L/ixX1+r/qNhypwxeTAsWpNMBwvyVo2PxZDPhibmL5m0UCrdGVibipb8ZtfzRroVrTzdEUpjWcjaBxgI+12CWA=;25:1ueEQ4KkoRxta37wK5LK9t/Ae7ilEbmbPjnXIfcK3Iu799PbO4MFDTmEctdOBnz8IkcQ4Fbudl80eYCKD1Fb6MMnb4TBoLxvl2NKbVxOGzO/yyRSXR4faTGsxvpg4nmuhntvXGPwDpRf7T0zufYLCh5w6Nwk6yH49/Nq2y3Fxj8fdMB9oyk/lmMsQ+eTfVqR93VkBjAlctIBD+pjCoZNTc3G7B2qhYq5cOdMdJ6Bur2eY4XaXZdVsdPVZ8LvdRbfmJSWLOJf+mKBn/sYS+OEJwEmcKnvQo3eFddoaVQ2hh8O/LN+ZNK0vPGE99vVs1X4u+Nvtruedx+KpKT2PcnPCw== X-MS-TrafficTypeDiagnostic: SN4PR0201MB3518: X-Microsoft-Exchange-Diagnostics: 1;SN4PR0201MB3518;31:no1ULoG8PViFDNBE8Hw3b/Craui7ir/OqjQVEUDAt+n25g9aYbf3mwpUWrUIUc6zupuK/6C5HPpKUvRkPExU2X1mdQkolf9Dmn+n3V0JqY/f4u5gJ9pgEWnyTwYs0w/p7CPFI+OS5FZECaZYEIcQv0X7JLLQjH36HGj4qhNA2syHa/2lPwC3rf82K8zqh0dgJXPMINWSfCd39c2sVK+z8HGcGXD4M0U4TOY6tuv6Uhw=;20:zKaM+nbTJufyE6/Z8AGYvsoOG96lRDPNNa5LJO3rHpzZg3GJBgSf1PJ3cV8Xz2GtoTThcmdyRg+ibflnLe19pAmsSb6QigV+Vo7W2arAs6CvkAIjBwFvJMYBw+qws8mxFcfD0Au0SUpImQi8wE4WqetSE2xCo/0ljPYrswkxsAx6Mtxmpc4N0eqYIBTn85wHyphyFA84YsiN2NjbTLpWtEUctS45u6JEfCYzsV2a7UZgqMyYdCGnDpvju00zXMnDe87ghOmz9ETvqHx8BwH6nX915qd4vvjOrNZPTSShBbabCAxmXiQl1ltN3+o3AGw63AEv+SfzzOtfVuBnP0GmcMXVjS1TilYZM3d0HJqzJ0X3H8NdXJQCAAu++TWdlvOBeV37EU77kjxU7qk0kR1+V5IAOUgu5x0BHNWcZDXOqtTXFSXtUrI3lDkzErPuncfGZWX9BLWlLMB29E8JvxfwFlkJ+Hm6JmyYjaAQU/DkQLYhJDnS+uoICnV5lGng8XUJ X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(192813158149592); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(3231311)(944501410)(52105095)(10201501046)(93006095)(93004095)(3002001)(6055026)(149027)(150027)(6041310)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(6072148)(201708071742011)(7699016);SR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6Ge5QBW8Mwhz+ftRYk9NmzMyiiO/QxbDwdoYS459iSU9P6vozEbB1VcZv+/UR0iDeUcmFGFlIvmWy1RALmlSRXdEDDXkU8m+PUSx4LIXMokSygXSFzAhOVhHmBVDyc0JIXo0WkLXPE4EaPa+iUYobX50BB8paNtFng8wfFZRvbJPUEq2gp9cftlgBFN1pV2D3v8MHSnobG2uS3O1jBdhfZ8OzCo5qnSt1bgrILSNPffKwMcBKRdiJExelu21o+uo/YOwRKxaWog85guw50z4akvjbksxOPdxE9dlTQw69pJiASwKs3+YbQtBD3c+gf1tQ==;5:wRhqTCiNm8xV6a2CR52E8/qGS7I0z+sQKY7lxZWAhGFMMbZhvmV3N92M5bZ8YkxD/6tS8oS0JHKbU3xKcA/G6cnSBuZ4KwfvOwYNT48E1ZQmeMHOT2NHxsR/2lDqU4TUnsfUF6LbQcOoUnJyZtpeQmFQxSICzaJkTaI8Z+03KHs=;7:vtYcCKXjkNtDJkNsTadN1TdryUdRN7qdxleYDnxkVKWjEQlVKI8W0SXqqUzXQ92h+bFuSpJZFSaSuDkkOsy9LrMsIgducVqzxYlxofbvep6SPxMjlEe3fv2f4o+iZ0eCdU2X4IhbeflvRVKx1rEKcfGXNswA21bxiX7/Dlfq4a+ilkYCm8kmyeGyyBWuMCS2ZhhpAqPBj0uN8L9PgJ3lw2Fz8A0lc4Jm+G4J7F9GbKkt+p8DLTdpaIhwvtSEYr31 SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: xilinx.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Aug 2018 15:45:16.9852 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: da58ba00-d572-4f57-d3df-08d5fed845de 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: SN4PR0201MB3518 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 Add nwl_setup_service_irqs hook to setup_platform_service_irq IRQs to register platform provided IRQ number to kernel AER service. Signed-off-by: Bharat Kumar Gogada --- drivers/pci/controller/pcie-xilinx-nwl.c | 16 ++++++++++++++++ 1 files changed, 16 insertions(+), 0 deletions(-) diff --git a/drivers/pci/controller/pcie-xilinx-nwl.c b/drivers/pci/controller/pcie-xilinx-nwl.c index fb32840..285647b 100644 --- a/drivers/pci/controller/pcie-xilinx-nwl.c +++ b/drivers/pci/controller/pcie-xilinx-nwl.c @@ -22,6 +22,7 @@ #include #include "../pci.h" +#include "../pcie/portdrv.h" /* Bridge core config registers */ #define BRCFG_PCIE_RX0 0x00000000 @@ -819,6 +820,20 @@ static int nwl_pcie_parse_dt(struct nwl_pcie *pcie, return 0; } +int nwl_setup_service_irqs(struct pci_host_bridge *bridge, int *irqs, + int plat_mask) +{ + struct nwl_pcie *pcie; + + pcie = pci_host_bridge_priv(bridge); + if (plat_mask & PCIE_PORT_SERVICE_AER) { + irqs[PCIE_PORT_SERVICE_AER_SHIFT] = pcie->irq_misc; + plat_mask &= ~(1 << PCIE_PORT_SERVICE_AER_SHIFT); + } + + return plat_mask; +} + static const struct of_device_id nwl_pcie_of_match[] = { { .compatible = "xlnx,nwl-pcie-2.11", }, {} @@ -880,6 +895,7 @@ static int nwl_pcie_probe(struct platform_device *pdev) bridge->ops = &nwl_pcie_ops; bridge->map_irq = of_irq_parse_and_map_pci; bridge->swizzle_irq = pci_common_swizzle; + bridge->setup_platform_service_irq = nwl_setup_service_irqs; if (IS_ENABLED(CONFIG_PCI_MSI)) { err = nwl_pcie_enable_msi(pcie);