Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Nov 2013 11:47:52 +0200
From:      Andriy Gapon <avg@FreeBSD.org>
To:        Adrian Chadd <adrian@FreeBSD.org>
Cc:        Luigi Rizzo <luigi@FreeBSD.org>, Bernhard Schmidt <bschmidt@FreeBSD.org>, "freebsd-hackers@freebsd.org" <freebsd-hackers@FreeBSD.org>, Aleksandr Rybalko <ray@FreeBSD.org>, Andrew Thompson <thompsa@FreeBSD.org>, Pyun YongHyeon <yongari@FreeBSD.org>
Subject:   Re: taskqueue_block
Message-ID:  <5295BFC8.6030404@FreeBSD.org>
In-Reply-To: <CAJ-Vmon6F6JaSPrxht8AUsEwHmVwZDoS%2BszNEtFm-X%2BRACLqYA@mail.gmail.com>
References:  <5287BDB9.10201@FreeBSD.org>	<528B7681.6090806@FreeBSD.org>	<CAJ-Vmon5AuBDO8q3uddSnvqBTq71r9vW66DAk9oVpLKUUbX0mA@mail.gmail.com>	<201311211414.06849.jhb@freebsd.org>	<5294BDCF.1050702@FreeBSD.org> <CAJ-Vmon6F6JaSPrxht8AUsEwHmVwZDoS%2BszNEtFm-X%2BRACLqYA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
on 26/11/2013 23:42 Adrian Chadd said the following:
> Hi,
> 
> the net80211 semantics are:
> 
> * all those tasks have to have finished;

taskqueue_drain ensures this.

> * no new tasks should've been started whilst we're draining those tasks.

This is impossible to ensure by anything inside taskqueue implementation.

> waitfor_parent wants to block until all the pending update tasks are
> done. Ideally it would then stay blocked until the caller does their
> thing and then unblocks the taskqueue.

As I explained in my original email, these requirements are contradictory.  You
can not drain pending tasks having disallowed them to be run.

Something like this can not be done by means of taskqueue itself.

-- 
Andriy Gapon



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