From: Takashi Iwai Subject: Re: [PATCH v4 5/7] ASoC: intel - add Skylake HDA audio driver Date: Tue, 02 Jun 2015 12:48:50 +0200 Message-ID: References: <1431341645-2457-1-git-send-email-vinod.koul@intel.com> <1431341645-2457-6-git-send-email-vinod.koul@intel.com> <20150529174115.GR21577@sirena.org.uk> <20150601051358.GI3140@localhost> <20150602104233.GG14071@sirena.org.uk> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (cantor2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id 05D2F260517 for ; Tue, 2 Jun 2015 12:48:52 +0200 (CEST) In-Reply-To: <20150602104233.GG14071@sirena.org.uk> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org To: Mark Brown Cc: alsa-devel@alsa-project.org, Vinod Koul , liam.r.girdwood@linux.intel.com, patches.audio@intel.com, Jeeja KP , "Subhransu S. Prusty" List-Id: alsa-devel@alsa-project.org At Tue, 2 Jun 2015 11:42:33 +0100, Mark Brown wrote: > > On Mon, Jun 01, 2015 at 07:32:14AM +0200, Takashi Iwai wrote: > > Vinod Koul wrote: > > > > > > + ret = request_threaded_irq(hda->pci->irq, azx_interrupt, > > > > > + azx_threaded_handler, > > > > > + hda->msi ? 0 : IRQF_SHARED, > > > > > + KBUILD_MODNAME, sbus); > > > > > Why not just always request the interrupt as shared - we don't seem to > > > > care in the interrupt handling code? > > > > I think we can move this to shared only > > > MSI is the exclusive irq, thus shouldn't be shared. > > Why does the driver care though? IRQF_SHARED is advertising the > capabilities of the hander, not a requirement on the hardware - if the > interrupt physically can't be shared then the ability to share it will > never get used but that shouldn't matter. Because the kernel doesn't guarantee the exclusiveness of irq handler registration as long as you pass IRQF_SHARED. That is, if we keep IRQF_SHARED and another driver tries to request_irq() for the same irq with again IRQF_SHARED. But this shouldn't happen with MSI. Takashi