From patchwork Fri Jul 5 09:56:56 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Z.Q. Hou" X-Patchwork-Id: 11032969 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 EEB83138D for ; Fri, 5 Jul 2019 15:49:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D9CE928701 for ; Fri, 5 Jul 2019 15:49:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CDC1728739; Fri, 5 Jul 2019 15:49:50 +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=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D02E828701 for ; Fri, 5 Jul 2019 15:49:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=/fH32VwoBW+yNayRnXZS33ixd3jn4uXslwRtZyuj84s=; b=IrAn/9yyKzGBG1y8av1o/yrOkp m5ysYB2oonOeFQmk47AjwsDIN06gNdYZtYjRs3MEZ/L5+IPJdCHmVmb7g1t4AWMTNM7sv8wNzocMh M16v0ujIJL5x13Q+lUQQbte0COiH3fbii0miLcUVNpPv0QiQzSul6KqpCZOQfkZrv556w3xKZPpuV PpmYqTAENSEeEM6k0mWbNIS/s/vsXfIrFuePFSgzvVImBdnrjaTuqZirbL35PD+mJOSr3YRUiFx8Y aa/5+DcvlO4pAoYoSRw9CtFd2+FiOcEcgUHq3g4gdqsTdryI0BWLNthc+YLM8GEtC8HEro2rgD55J 8vR7DRDA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hjQT6-00044S-E2; Fri, 05 Jul 2019 15:49:48 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hjQNu-00064W-Uv for linux-arm-kernel@bombadil.infradead.org; Fri, 05 Jul 2019 15:44:26 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=sDrZie/RIz15BQiPm1KT0dSq58Ejjf210SOf12NLeuE=; b=kXvwpEBQ3fzhGOKKMLvLW3aEd CfBuEsqu9qVMYLqnfMvckL87ToVBBw3NAj+G1HjphmLkZgS2mpXm66DSEgtBgJHZ7OhxtpVjSBly7 l4UsWtWBgBkaujokwNZk74GzL8Ifl+c4q0dr41Njb3TzOMsPysTCgUvANQZMbVngNYhpbdQLz778v LYACQ9TjQHKyKPDK/doQgzm7VtnUSZXguO+RK/cnwmlh+zZhRAHU36VejO8/RLTdG0yYT6+Ela5ev 1C2EtJk0SM5R7/O45ipAEHHxRtoyUQ4KwxT8QJGo8msCbRHYPTeXB824gnnM5Gk23ItC5nc4jmq4H bKjofjE/w==; Received: from inva021.nxp.com ([92.121.34.21]) by merlin.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hjL8B-00010n-T6 for linux-arm-kernel@lists.infradead.org; Fri, 05 Jul 2019 10:07:52 +0000 Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 050C6200703; Fri, 5 Jul 2019 12:07:48 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 7D0882006F8; Fri, 5 Jul 2019 12:07:39 +0200 (CEST) Received: from titan.ap.freescale.net (TITAN.ap.freescale.net [10.192.208.233]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id 7BF38402EB; Fri, 5 Jul 2019 18:07:29 +0800 (SGT) From: Hou Zhiqiang To: linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, bhelgaas@google.com, robh+dt@kernel.org, mark.rutland@arm.com, l.subrahmanya@mobiveil.co.in, shawnguo@kernel.org, leoyang.li@nxp.com, lorenzo.pieralisi@arm.com, catalin.marinas@arm.com, will.deacon@arm.com Subject: [PATCHv6 28/28] PCI: mobiveil: Fix the potential INTx missing problem Date: Fri, 5 Jul 2019 17:56:56 +0800 Message-Id: <20190705095656.19191-29-Zhiqiang.Hou@nxp.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> References: <20190705095656.19191-1-Zhiqiang.Hou@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Minghuan.Lian@nxp.com, Hou Zhiqiang , Xiaowei.Bao@nxp.com, Mingkai.Hu@nxp.com MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The current INTx process is clear all the recorded INTx after each one of the recorded INTx handled, this can result in potential INTx missing. This patch change it to only clear the handled INTx status. Fixes: 9af6bcb11e12 ("PCI: mobiveil: Add Mobiveil PCIe Host Bridge IP driver") Signed-off-by: Hou Zhiqiang Reviewed-by: Minghuan Lian Reviewed-by: Subrahmanya Lingappa Acked-by: Karthikeyan Mitran Tested-by: Karthikeyan Mitran --- V6: - Splited from #10 of v5 patches, no functional change. drivers/pci/controller/pcie-mobiveil.c | 5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/pci/controller/pcie-mobiveil.c b/drivers/pci/controller/pcie-mobiveil.c index a5549cf..3ab7d2e 100644 --- a/drivers/pci/controller/pcie-mobiveil.c +++ b/drivers/pci/controller/pcie-mobiveil.c @@ -372,9 +372,8 @@ static void mobiveil_pcie_isr(struct irq_desc *desc) dev_err_ratelimited(dev, "unexpected IRQ, INT%d\n", bit); - /* clear interrupt */ - csr_writel(pcie, - shifted_status << PAB_INTX_START, + /* clear interrupt handled */ + csr_writel(pcie, 1 << (PAB_INTX_START + bit), PAB_INTP_AMBA_MISC_STAT); }