[alsa-devel] [PATCH] fm801: move to pcim_* and devm_* functions

Andy Shevchenko andy.shevchenko at gmail.com
Tue Jan 20 14:46:13 CET 2015


On Tue, Jan 20, 2015 at 2:42 PM, Takashi Iwai <tiwai at suse.de> wrote:
> At Wed, 07 Jan 2015 15:59:35 +0100,
> Takashi Iwai wrote:

[]


> I recalled finally why I didn't want this sort of changes.  Namely,
> devm_request_irq() can't be used safely for the shared PCI
> interrupts.
>
> There is a small open window between the driver's remove call
> (i.e. card's private_free or device free calls) and the call of
> devres_release_all().  The registered irq handler still remains during
> this window.  When an irq is triggered from another shared device
> during this, it goes to the remaining irq handler and accesses the
> hardware unexpectedly.  In the case of snd_fm801_interrupt(), it's not
> too bad, though.

Don't we have interrupts disabled on ->remove() stage?

-- 
With Best Regards,
Andy Shevchenko


More information about the Alsa-devel mailing list