From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
Andrew Morton <akpm@osdl.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
mdz@canonical.com, janitor@sternwelten.at
Subject: Re: [PATCH] Use msleep_interruptible for therm_adt7467.c kernel thread
Date: Wed, 29 Sep 2004 14:12:43 +1000 [thread overview]
Message-ID: <1096431162.17114.10.camel@gaston> (raw)
In-Reply-To: <1096421071.14637.6.camel@localhost.localdomain>
On Wed, 2004-09-29 at 11:24, Alan Cox wrote:
> On Mer, 2004-09-29 at 02:58, Herbert Xu wrote:
> > > A more interesting question is why this isn't being driven off a
> > > timer ?
> >
> > It probably could if the stuff afterwards doesn't sleep.
>
> schedule_work() ?
I don't like that. I wrote the g5 therm driver (from which this one is
derivated) as a kernel thread because, at least on the g5, I do a lot of
i2c accesses. If I were to do that in schedule_work, I would "hog" keventd
a very long time each time, which is bad.
schedule_work() is always way too much abused in this way, thus beeing
a source of latencies.
Creating my own work queue would have been silly since (at least back
then), it would have meant creating one additional kernel thread on every
CPU... so I decided just to create my own kernel thread and be done with
it.
Now, using a timer and waiting on it would eventually work too, but the
way it is now just works so ...
Ben.
next prev parent reply other threads:[~2004-09-29 4:15 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-27 10:25 [PATCH] Use msleep_interruptible for therm_adt7467.c kernel thread Herbert Xu
2004-09-27 12:51 ` Alan Cox
2004-09-29 1:58 ` Herbert Xu
2004-09-29 1:24 ` Alan Cox
2004-09-29 4:12 ` Benjamin Herrenschmidt [this message]
2004-09-29 4:13 ` Benjamin Herrenschmidt
2004-09-30 4:40 ` Andrew Morton
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=1096431162.17114.10.camel@gaston \
--to=benh@kernel.crashing.org \
--cc=akpm@osdl.org \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=herbert@gondor.apana.org.au \
--cc=janitor@sternwelten.at \
--cc=linux-kernel@vger.kernel.org \
--cc=mdz@canonical.com \
/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.