Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Nov 2013 11:40:46 +0200
From:      Andriy Gapon <avg@FreeBSD.org>
To:        Adrian Chadd <adrian@FreeBSD.org>
Cc:        "freebsd-hackers@freebsd.org" <freebsd-hackers@FreeBSD.org>
Subject:   Re: taskqueue_drain_all
Message-ID:  <5295BE1E.5090401@FreeBSD.org>
In-Reply-To: <CAJ-VmonjLcp4=A%2BdRShaGVXhe67VaVtR5kY2DJcZUBOOYW8KoA@mail.gmail.com>
References:  <525519F1.3050703@FreeBSD.org>	<5295032B.4010200@FreeBSD.org> <CAJ-VmonjLcp4=A%2BdRShaGVXhe67VaVtR5kY2DJcZUBOOYW8KoA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
on 26/11/2013 23:44 Adrian Chadd said the following:
> Hi,
> 
> On 26 November 2013 12:23, Andriy Gapon <avg@freebsd.org> wrote:
>> on 09/10/2013 11:55 Andriy Gapon said the following:
>>>
>>> I would like to propose to extend taskqueue API with taskqueue_drain_all.
>>> A potential use case: I have a private taskqueue, several kinds of tasks get
>>> executed via it and then I want to make sure that all of them are completed.
>>> Obviously, I have a way to ensure that no new ones get enqueued.
>>
>> Provided I do not get any no-s or why-s I am going to commit the following
>> slightly different version soon:
>>
>> http://people.freebsd.org/~avg/taskqueue_drain_all.diff
>>
>> P.S.
>> taskqueue_drain_running introduced in the above patch could also be used to add
>> wait semantics to taskqueue_block.
>>
> 
> So you're going to keep taskqueue_drain() semantics of running the
> tasks if they're queued?

Yes, of course.  Why?

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5295BE1E.5090401>