Received: by 2002:a25:b323:0:0:0:0:0 with SMTP id l35csp2529310ybj; Mon, 23 Sep 2019 05:29:25 -0700 (PDT) X-Google-Smtp-Source: APXvYqwEll5byP8WRGMqAyD+Rmxd3VISHiYkPmnf5XeUSMLBC6LfJS8p2vpwmQfTq+G8k2hs5Fj3 X-Received: by 2002:a05:6402:1681:: with SMTP id a1mr36552669edv.218.1569241765276; Mon, 23 Sep 2019 05:29:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569241765; cv=none; d=google.com; s=arc-20160816; b=eHOpEjO+4+Og+85Azmq+4bduKFNBNCJtcfBbSTnIHZ6RV5IJT7bYHMENYQt+DpLZ49 bj33nLetZK6zLFp6etN3ZOH8ULqh4Yl5v6bl2jzDTJiLhl/iOoakOggfI2dP/OyFnpy2 aJJ2NVZMfhF9H50JxYxFGhP0qt/dV2H/cmAkgm+K3ZKLT8muXlzMsWa+/EycEtk+07J+ j57G47Y4nokPx3e3mFYawQMaotuz1oBzjiVhEoRU5bRe2dtlezObTL4FNxrULUZeKTPq 25yAl95ChP017TT2cWwAtstIpY3xxTl2CM0LN+HMWq85Le5DNmRFlgTwWEtplFCvIDTl h+sA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dmarc-filter:dkim-signature:dkim-signature; bh=+crPnGft+zZHXGVhTxLrCRBi5J41OVmy7KmdT97O34E=; b=BSXpc48XhQKPjJ3SdqOG08ddJESHa6LnYiFgF5t3l8B5AhUxqty9SvdeVIyHoAWLP5 1BSBX/IDhxgh0uTje495uYLEGsfFlOZ/J3McluNHUyoI8x8Lla1bS7wAhWfz+YITVtNk 7np3XOeO7/smFy4O2+3mttoK0SEscar5PcAzU4JXGvx8jBCpqCHLgyfLC/U2HgUZ7nr1 BRbdchnDgR0RltjNdPV/0J/FWmBbZUv8ZVAg8sgyC7fy54vSRx7VIFChYYnwKVTwrHrO 3o3cJ+l8mXpuJIw1gm8/JHRuBWcDrJw93ubJZnLnvqQCLFurrtqDPtF9dBECEaOD8tZ6 3wzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=cIu4Ag7I; dkim=pass header.i=@codeaurora.org header.s=default header.b=cIu4Ag7I; 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 q10si6361635eda.293.2019.09.23.05.29.01; Mon, 23 Sep 2019 05:29:25 -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; dkim=pass header.i=@codeaurora.org header.s=default header.b=cIu4Ag7I; dkim=pass header.i=@codeaurora.org header.s=default header.b=cIu4Ag7I; 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 S2404812AbfITWbp (ORCPT + 99 others); Fri, 20 Sep 2019 18:31:45 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:44106 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2393874AbfITWbo (ORCPT ); Fri, 20 Sep 2019 18:31:44 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id E1ABB6118D; Fri, 20 Sep 2019 22:31:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1569018703; bh=+crPnGft+zZHXGVhTxLrCRBi5J41OVmy7KmdT97O34E=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cIu4Ag7IzhL+frMMcRMaDtGCKgqg6EDR0OLFaZAhBw9mgXCfgJR9qiGixHlTglBSz GUqWIieWCgsvIyZpALpcitmjpUKnXhKDiR45iQwEwy0/+F3X7TgWbc8SgyT8SPTUIH nQi4BWwil+oLjdZo7MjrDbMGOgBhby6m7bfBRGZA= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_INVALID,DKIM_SIGNED,SPF_NONE autolearn=no autolearn_force=no version=3.4.0 Received: from localhost (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: ilina@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id ECFEB60A60; Fri, 20 Sep 2019 22:31:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1569018703; bh=+crPnGft+zZHXGVhTxLrCRBi5J41OVmy7KmdT97O34E=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cIu4Ag7IzhL+frMMcRMaDtGCKgqg6EDR0OLFaZAhBw9mgXCfgJR9qiGixHlTglBSz GUqWIieWCgsvIyZpALpcitmjpUKnXhKDiR45iQwEwy0/+F3X7TgWbc8SgyT8SPTUIH nQi4BWwil+oLjdZo7MjrDbMGOgBhby6m7bfBRGZA= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org ECFEB60A60 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=ilina@codeaurora.org Date: Fri, 20 Sep 2019 16:31:42 -0600 From: Lina Iyer To: Stephen Boyd Cc: evgreen@chromium.org, linus.walleij@linaro.org, marc.zyngier@arm.com, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, bjorn.andersson@linaro.org, mkshah@codeaurora.org, linux-gpio@vger.kernel.org, rnayak@codeaurora.org Subject: Re: [PATCH RFC 02/14] drivers: irqchip: pdc: Do not toggle IRQ_ENABLE during mask/unmask Message-ID: <20190920223142.GI15853@codeaurora.org> References: <20190829181203.2660-1-ilina@codeaurora.org> <20190829181203.2660-3-ilina@codeaurora.org> <5d71aad9.1c69fb81.f469e.262f@mx.google.com> <20190911161557.GB30053@codeaurora.org> <5d85511e.1c69fb81.98f62.dae0@mx.google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <5d85511e.1c69fb81.98f62.dae0@mx.google.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 20 2019 at 16:22 -0600, Stephen Boyd wrote: >Quoting Lina Iyer (2019-09-11 09:15:57) >> On Thu, Sep 05 2019 at 18:39 -0600, Stephen Boyd wrote: >> >Quoting Lina Iyer (2019-08-29 11:11:51) >> >> When an interrupt is to be serviced, the convention is to mask the >> >> interrupt at the chip and unmask after servicing the interrupt. Enabling >> >> and disabling the interrupt at the PDC irqchip causes an interrupt storm >> >> due to the way dual edge interrupts are handled in hardware. >> >> >> >> Skip configuring the PDC when the IRQ is masked and unmasked, instead >> >> use the irq_enable/irq_disable callbacks to toggle the IRQ_ENABLE >> >> register at the PDC. The PDC's IRQ_ENABLE register is only used during >> >> the monitoring mode when the system is asleep and is not needed for >> >> active mode detection. >> > >> >I think this is saying that we want to always let the line be sent >> >through the PDC to the parent irqchip, in this case GIC, so that we >> >don't get an interrupt storm for dual edge interrupts? Why does dual >> >edge interrupts cause a problem? >> > >> I am not sure about the hardware details, but the PDC designers did not >> expect enable and disable to be called whenever the interrupt is >> handled. This specially becomes a problem for dual edge interrupts which >> seems to generate a interrupt storm when enabled/disabled while handling >> the interrupt. >> > >Ok. I just wanted to confirm that masking "doesn't matter" to the PDC >because it assumes the irqchip closer to the CPU will be able to mask it >anyway. Is that right? > That is correct.