From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Brown Subject: Re: [PATCH] spi: bcm2835aux: ensure interrupts are enabled for shared handler Date: Fri, 4 May 2018 08:06:02 +0900 Message-ID: <20180503230602.GA13402@sirena.org.uk> References: <20180503180945.3502-1-robh@kernel.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8034675562318730107==" Cc: Stefan Wahren , Florian Fainelli , Scott Branden , Marc Zyngier , Ray Jui , Alexander Graf , linux-spi@vger.kernel.org, Eric Anholt , bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org To: Rob Herring Return-path: In-Reply-To: <20180503180945.3502-1-robh@kernel.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=m.gmane.org@lists.infradead.org List-Id: linux-spi.vger.kernel.org --===============8034675562318730107== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="UlVJffcvxoiEqYs2" Content-Disposition: inline --UlVJffcvxoiEqYs2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, May 03, 2018 at 01:09:44PM -0500, Rob Herring wrote: > The root cause however is a bug in the shared handler. Shared handlers > must check that interrupts are actually enabled before servicing the > interrupt. Add a check that the TXEMPTY or IDLE interrupts are enabled. The requirement is more that the handler should correctly identify if it actually handled an interrupt - especially if the driver doesn't enable and disable the interrupt at runtime it's not going to upset anything to always run the interrupt handling (and of course some hardware can't disable things anyway) but if nohing happened then the handler needs to return IRQ_NONE. --UlVJffcvxoiEqYs2 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAlrrldoACgkQJNaLcl1U h9AFWAf+KJ2Ahu1SNg0uzFnkUt5jMQuqT918CVCyQudsarzgqDIfjNUM1si677MQ yfiLVaV2FV3ReozK512CnUNAwhGG8ktTYBepOolU+wryZwTbBhFUOF6w2KQQJgm8 E9Cph4D4E8xN4aJ5T3b3po34igFrZSFlasooCw3MfjyXCLPyHY6XDs9znNbpR1QN g1qayP1SW/PIXS4AqQDO9b4OSJ1e2hnLHh7gnNGfhcOczD8zk2Miol6g/95iexJm Xf0Yu/I0fTUjQPovnGEhjfxcnF03tt3hVbQEWh1UCQ0RTjJWUcm9IsPghXgbMd3G 7K8quUUIvcpXzODZd+5pkodFUNQuPQ== =y+hq -----END PGP SIGNATURE----- --UlVJffcvxoiEqYs2-- --===============8034675562318730107== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============8034675562318730107==-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: broonie@kernel.org (Mark Brown) Date: Fri, 4 May 2018 08:06:02 +0900 Subject: [PATCH] spi: bcm2835aux: ensure interrupts are enabled for shared handler In-Reply-To: <20180503180945.3502-1-robh@kernel.org> References: <20180503180945.3502-1-robh@kernel.org> Message-ID: <20180503230602.GA13402@sirena.org.uk> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On Thu, May 03, 2018 at 01:09:44PM -0500, Rob Herring wrote: > The root cause however is a bug in the shared handler. Shared handlers > must check that interrupts are actually enabled before servicing the > interrupt. Add a check that the TXEMPTY or IDLE interrupts are enabled. The requirement is more that the handler should correctly identify if it actually handled an interrupt - especially if the driver doesn't enable and disable the interrupt at runtime it's not going to upset anything to always run the interrupt handling (and of course some hardware can't disable things anyway) but if nohing happened then the handler needs to return IRQ_NONE. -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 488 bytes Desc: not available URL: