From: Tejun Heo <tj@kernel.org>
To: David Howells <dhowells@redhat.com>
Cc: Arjan van de Ven <arjan@linux.intel.com>,
Frederic Weisbecker <fweisbec@gmail.com>,
torvalds@linux-foundation.org, mingo@elte.hu,
linux-kernel@vger.kernel.org, jeff@garzik.org,
akpm@linux-foundation.org, rusty@rustcorp.com.au,
cl@linux-foundation.org, oleg@redhat.com, axboe@kernel.dk,
dwalker@codeaurora.org, stefanr@s5r6.in-berlin.de,
florian@mickler.org, andi@firstfloor.org, mst@redhat.com,
randy.dunlap@oracle.com, Arjan van de Ven <arjan@infradead.org>
Subject: Re: [PATCHSET] workqueue: implement and use WQ_UNBOUND
Date: Wed, 21 Jul 2010 17:31:00 +0200 [thread overview]
Message-ID: <4C4712B4.9040706@kernel.org> (raw)
In-Reply-To: <15189.1279725944@redhat.com>
Hello,
On 07/21/2010 05:25 PM, David Howells wrote:
>> Each gcwq keeps track of currently running works in a hash table and looks
>> whether the work in question is already executing before starting executing
>> it. It's a bit complex but as a work_struct may be freed once execution
>> starts, the status needs to be tracked outside.
>
> Thanks, that's what I wanted to know.
>
> I presume this survives an executing work_struct being freed, reallocated and
> requeued before the address of the work_struct is removed from the hash table?
It will unnecessarily stall the execution of the new work if the last
work is still running but nothing will be broken correctness-wise.
> I can see at least one way of doing this: marking the work_struct address in
> the hash when the address becomes pending again so that the process of hash
> removal will cause the work_struct to be requeued automatically.
If I'm correctly understanding what you're saying, the code already
does about the same thing.
Thanks.
--
tejun
next prev parent reply other threads:[~2010-07-21 15:32 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-20 22:39 [PATCHSET] workqueue: implement and use WQ_UNBOUND Tejun Heo
2010-07-21 13:08 ` David Howells
2010-07-21 14:59 ` Tejun Heo
2010-07-21 15:03 ` Tejun Heo
2010-07-21 15:25 ` David Howells
2010-07-21 15:31 ` Tejun Heo [this message]
2010-07-21 15:38 ` David Howells
2010-07-21 15:42 ` Tejun Heo
2010-07-21 15:45 ` David Howells
2010-07-21 15:51 ` Tejun Heo
-- strict thread matches above, loose matches on Subject: below --
2010-06-29 16:59 [PATCH 34/35] async: use workqueue for worker pool Tejun Heo
2010-06-28 21:03 ` [PATCHSET] workqueue: concurrency managed workqueue, take#6 Tejun Heo
2010-06-28 21:04 ` [PATCH 34/35] async: use workqueue for worker pool Tejun Heo
2010-06-28 22:55 ` Frederic Weisbecker
2010-06-29 7:25 ` Tejun Heo
2010-06-29 12:18 ` Frederic Weisbecker
2010-06-29 15:46 ` Tejun Heo
2010-06-29 15:52 ` Frederic Weisbecker
2010-06-29 15:55 ` Tejun Heo
2010-06-29 16:40 ` Arjan van de Ven
2010-06-29 21:37 ` David Howells
2010-07-02 9:17 ` [PATCHSET] workqueue: implement and use WQ_UNBOUND Tejun Heo
2010-07-02 9:32 ` Tejun Heo
2010-07-07 5:41 ` Tejun Heo
2010-07-14 9:39 ` Tejun Heo
2010-07-20 22:01 ` David Howells
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4C4712B4.9040706@kernel.org \
--to=tj@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=andi@firstfloor.org \
--cc=arjan@infradead.org \
--cc=arjan@linux.intel.com \
--cc=axboe@kernel.dk \
--cc=cl@linux-foundation.org \
--cc=dhowells@redhat.com \
--cc=dwalker@codeaurora.org \
--cc=florian@mickler.org \
--cc=fweisbec@gmail.com \
--cc=jeff@garzik.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=mst@redhat.com \
--cc=oleg@redhat.com \
--cc=randy.dunlap@oracle.com \
--cc=rusty@rustcorp.com.au \
--cc=stefanr@s5r6.in-berlin.de \
--cc=torvalds@linux-foundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.