From: almoeli@gmx•de
Cc: linuxppc-embedded@ozlabs•org
Subject: Re: Linux kernel thread with Linux 2.6.x
Date: Tue, 30 May 2006 15:17:56 +0200 [thread overview]
Message-ID: <447C4604.7020109@gmx.de> (raw)
In-Reply-To: <20060530112343.GB24129@wohnheim.fh-wedel.de>
Hi,
do you have to use the semaphore or does a spinlock also meet your needs?
If you are in kernel 2.4 you can use one of the task_queues (e.g the
scheduler queue, timer and immediate queue also run at irq context) but
that won't have a better speed than your solution because it also gets
the processor when tasks are scheduled (all 10ms I think). In 2.6 it
would be the work_queue (schedule_work()).
So the best way is to use spinlocks and do the work in a tasklet at
interrupt context.
Oliver
Jörn Engel schrieb:
> On Tue, 30 May 2006 11:46:09 +0200, Laurent Lagrange wrote:
>> Thanks for your answer, but a tasklet runs in interrupt context
>> (in_interrupt() != 0) so it doesn't support schedule() call
>> included in "down" semaphore function.
>
> Do you have code you can show?
>
> Jörn
>
next prev parent reply other threads:[~2006-05-30 13:18 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-04-11 16:31 NAND and JFFS2 supports in Linux 2.4 Laurent Lagrange
2006-04-11 20:06 ` Jaap-Jan Boor
2006-04-11 21:19 ` Josh Boyer
2006-04-13 14:49 ` Laurent Lagrange
2006-04-13 15:03 ` Jörn Engel
2006-05-29 15:35 ` Linux kernel thread with Linux 2.6.x Laurent Lagrange
2006-05-29 17:13 ` Thiago Galesi
2006-05-30 9:46 ` Laurent Lagrange
2006-05-30 11:23 ` Jörn Engel
2006-05-30 13:17 ` almoeli [this message]
2006-05-30 22:10 ` Andy Fleming
-- strict thread matches above, loose matches on Subject: below --
2006-06-06 13:39 Laurent Lagrange
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=447C4604.7020109@gmx.de \
--to=almoeli@gmx$(echo .)de \
--cc=linuxppc-embedded@ozlabs$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox