Date: Sun, 30 Aug 2015 22:09:14 +0300 From: Andriy Gapon <avg@FreeBSD.org> To: Konstantin Belousov <kostikbel@gmail.com> Cc: FreeBSD Current <freebsd-current@FreeBSD.org> Subject: Re: panic: Stray timeout Message-ID: <55E354DA.9030302@FreeBSD.org> In-Reply-To: <20150830161603.GI2072@kib.kiev.ua> References: <55E2DA91.6080206@FreeBSD.org> <20150830161603.GI2072@kib.kiev.ua>
next in thread | previous in thread | raw e-mail | index | archive | help
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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?55E354DA.9030302>