lkml.org 
[lkml]   [2015]   [Jul]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: question about drivers/dma/dma-jz4780.c
On Wed, Jul 22, 2015 at 03:26:01PM +0100, Alex Smith wrote:

> >>>I think the explicit devm_free_irq() here is unnecessary, as when remove is
> >>>called there should be no remaining users of the DMA controller and therefore
> >>>no chance of an IRQ occurring between the controller being unregistered and an
> >>>implicit IRQ release afterwards.
> >Are you ensuring that device can no longer sent interrupts and all instances
> >of tasklet running or either completed are terminated and no further tasklet
> >can be spawned?
>
> Hi Vinod,
>
> If I understand correctly, when remove() is called, there should be
> no more users of the DMA controller, enforced by the module
> reference count.
>
> Wouldn't that guarantee that there are no more transactions running
> and therefore no chance of an interrupt from the controller or a
> tasklet still running?

That will only guarantee no new requests are recieved, but you may have
tasklet already scheduled or irq sent from HW how do you prevent that?

--
~Vinod



\
 
 \ /
  Last update: 2015-07-23 19:41    [W:0.112 / U:1.480 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site