From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.3 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1A5E5C433E2 for ; Fri, 5 Jun 2020 10:51:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E838F2067B for ; Fri, 5 Jun 2020 10:51:06 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726894AbgFEKvG (ORCPT ); Fri, 5 Jun 2020 06:51:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44268 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726637AbgFEKvE (ORCPT ); Fri, 5 Jun 2020 06:51:04 -0400 X-Greylist: delayed 109823 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Fri, 05 Jun 2020 03:51:03 PDT Received: from bmailout1.hostsharing.net (bmailout1.hostsharing.net [IPv6:2a01:37:1000::53df:5f64:0]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 76D81C08C5C2; Fri, 5 Jun 2020 03:51:03 -0700 (PDT) Received: from h08.hostsharing.net (h08.hostsharing.net [83.223.95.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.hostsharing.net", Issuer "COMODO RSA Domain Validation Secure Server CA" (not verified)) by bmailout1.hostsharing.net (Postfix) with ESMTPS id 04986300020AA; Fri, 5 Jun 2020 12:51:01 +0200 (CEST) Received: by h08.hostsharing.net (Postfix, from userid 100393) id C284822B009; Fri, 5 Jun 2020 12:51:00 +0200 (CEST) Date: Fri, 5 Jun 2020 12:51:00 +0200 From: Lukas Wunner To: Florian Fainelli Cc: linux-kernel@vger.kernel.org, Mark Brown , Rob Herring , Nicolas Saenz Julienne , Ray Jui , Scott Branden , "maintainer:BROADCOM BCM281XX/BCM11XXX/BCM216XX ARM ARCHITE..." , "open list:SPI SUBSYSTEM" , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "moderated list:BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE" , "moderated list:BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE" , Martin Sperl Subject: Re: [PATCH v2] spi: bcm2835: Enable shared interrupt support Message-ID: <20200605105100.kxe6wgh5itmhrgl2@wunner.de> References: <20200604212819.715-1-f.fainelli@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200604212819.715-1-f.fainelli@gmail.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jun 04, 2020 at 02:28:19PM -0700, Florian Fainelli wrote: > The 4 SPI controller instances added in BCM2711 and BCM7211 SoCs (SPI3, > SPI4, SPI5 and SPI6) share the same interrupt line with SPI0. > > For the BCM2835 case which is deemed performance critical, we would like > to continue using an interrupt handler which does not have the extra > comparison on BCM2835_SPI_CS_INTR. > > To support that requirement the common interrupt handling code between > the shared and non-shared interrupt paths is split into a > bcm2835_spi_interrupt_common() and both bcm2835_spi_interrupt() as well > as bcm2835_spi_shared_interrupt() make use of it. > > During probe, we determine if there is at least another instance of this > SPI controller, and if there is, then we install a shared interrupt > handler. > > Signed-off-by: Florian Fainelli Reviewed-by: Lukas Wunner