Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1353403imm; Tue, 22 May 2018 02:41:57 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrhmrD5DbaBsjQcFJcTBvl0SNH0LnwIee6x8xyt0g3LAHPTBf3nIvkHyCS3MYdrq+xY+Aig X-Received: by 2002:a63:79ca:: with SMTP id u193-v6mr3765640pgc.112.1526982116951; Tue, 22 May 2018 02:41:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526982116; cv=none; d=google.com; s=arc-20160816; b=SVy7WT0gv5t9GiEwm3HWXXmv5PFnabW4IqXf+yW5Q2MQsaZ8TT6WDNko0XaZw8z1KL hUIpAK+KQWcKhPff41hVI95JLtTr9fTs0P3ibusSNauhPSkTmAju/UgGevGnQJ7y23bv H8FmtwOjJvpSBH34nfQGswWgeIy1lLMmic/H3HWrsTxnJ3DQnxkMYkSQbAK9yOIGSDR7 LMNrIbhcZoM/z+FM6rvZYKzpod7oB4w5KJ/e3/3nfG1pYA26ePnPBV1v9zbNvHRFAy5N mU8/0gkDTGM1Mmrvs3/vxVhMAU+dsYqFDW+RQ0Y0iEidaZ5JeH2aZy32fRMIV18A/5Ts uHiA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=KMkN6RLWXzO0jIhwCZoMyNLax54S6tvoY6uRe+uwLsM=; b=UUoRroh7y/hdFWNz0WJmyMYMvdJ+tbw+3DYlhc2otJOZk4hl+HRdUXQe3P/Jz/Zit+ RywFdepCPTIyf1IQZ1s3BsY5Cd+QpI2elBDV3132iPGoLgdaaWa547FR44yfUkvfSkn3 UdZVU2s/fatMLL8uuKKnp/FOGsWDQHrwmWAtALCElklBxu/7o1b2tAviFD/yEu38+bvl NQCiUGTCYStjzcxXuPmge6Xc/mEaxHoRZ4EDKI1lolgN1QeZ4HkJlJOO9UBWWLUb6yQ2 q5WIS1so9C4thafKeDjCpDZR8A83PvgHLo42xxJyIXH6F8StjtWY6+mYVqIrMqogw46U W0yg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m64-v6si15899925pfm.0.2018.05.22.02.41.42; Tue, 22 May 2018 02:41:56 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751609AbeEVJlM (ORCPT + 99 others); Tue, 22 May 2018 05:41:12 -0400 Received: from mail.bootlin.com ([62.4.15.54]:49689 "EHLO mail.bootlin.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751146AbeEVJk5 (ORCPT ); Tue, 22 May 2018 05:40:57 -0400 Received: by mail.bootlin.com (Postfix, from userid 110) id 280CE20734; Tue, 22 May 2018 11:40:55 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on mail.bootlin.com X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,SHORTCIRCUIT, URIBL_BLOCKED shortcircuit=ham autolearn=disabled version=3.4.0 Received: from localhost.localdomain (LStLambert-657-1-97-87.w90-63.abo.wanadoo.fr [90.63.216.87]) by mail.bootlin.com (Postfix) with ESMTPSA id A5AA220737; Tue, 22 May 2018 11:40:44 +0200 (CEST) From: Miquel Raynal To: Thomas Gleixner , Jason Cooper , Marc Zyngier , Catalin Marinas , Will Deacon , Andrew Lunn , Gregory Clement , Sebastian Hesselbarth Cc: Rob Herring , Mark Rutland , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Thomas Petazzoni , Antoine Tenart , Maxime Chevallier , Nadav Haklai , Haim Boot , Hanna Hawa , linux-kernel@vger.kernel.org, Miquel Raynal Subject: [PATCH v2 04/16] irqchip/irq-mvebu-icu: clarify the reset operation of configured interrupts Date: Tue, 22 May 2018 11:40:30 +0200 Message-Id: <20180522094042.24770-5-miquel.raynal@bootlin.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180522094042.24770-1-miquel.raynal@bootlin.com> References: <20180522094042.24770-1-miquel.raynal@bootlin.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Rewrite a small section to clarify the reset operation of interrupts already configured by ATF that we want to handle in the driver. This will simplify the introduction of System Error Interrupts support. Signed-off-by: Miquel Raynal Reviewed-by: Thomas Petazzoni --- drivers/irqchip/irq-mvebu-icu.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/irqchip/irq-mvebu-icu.c b/drivers/irqchip/irq-mvebu-icu.c index a2a3acd74491..0f2655d7f19e 100644 --- a/drivers/irqchip/irq-mvebu-icu.c +++ b/drivers/irqchip/irq-mvebu-icu.c @@ -258,8 +258,12 @@ static int mvebu_icu_probe(struct platform_device *pdev) * avoid unpredictable SPI assignments done by firmware. */ for (i = 0 ; i < ICU_MAX_IRQS ; i++) { - u32 icu_int = readl_relaxed(icu->base + ICU_INT_CFG(i)); - if ((icu_int >> ICU_GROUP_SHIFT) == ICU_GRP_NSR) + u32 icu_int, icu_grp; + + icu_int = readl_relaxed(icu->base + ICU_INT_CFG(i)); + icu_grp = icu_int >> ICU_GROUP_SHIFT; + + if (icu_grp == ICU_GRP_NSR) writel_relaxed(0x0, icu->base + ICU_INT_CFG(i)); } -- 2.14.1