Re: panic: Stray timeout

From: Andriy Gapon <avg_at_FreeBSD.org>
Date: Sun, 30 Aug 2015 22:09:14 +0300
On 30/08/2015 19:16, Konstantin Belousov wrote:
> This is strange, I do not think that could be a right explanation of this
> issue.  The taskqueue callout is initialized with the mutex, which means
> that the callout_stop() caller
> - must own the mutex;
> - is synchronous with the callout.
> In other words, callout cannot be running when taskqueue_cancel_timeout()
> calls callout_stop(), it only can be dequeued but the callout function
> is not yet called.  If callout_stop() is performed meantime, between
> dropping callout_cpu lock, and locking the mutex, it must be not run.

Thank you for the explanation.  I am not familiar with the code and I
misinterpreted the manual page and thought that callout_stop() might be unable
to stop the callout even if it was initialized with the mutex.  I see my mistake
now.

-- 
Andriy Gapon
Received on Sun Aug 30 2015 - 17:10:13 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:59 UTC