From: Thomas Gleixner <tglx@linutronix.de>
To: Ingo Molnar <mingo@elte.hu>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2.6.10-mm2] Fix preemption race [1/3] (Core)
Date: Mon, 10 Jan 2005 11:14:44 +0100 [thread overview]
Message-ID: <1105352084.3058.5.camel@lap02.tec.linutronix.de> (raw)
In-Reply-To: <20050110091559.GB25034@elte.hu>
On Mon, 2005-01-10 at 10:15, Ingo Molnar wrote:
> * tglx@linutronix.de <tglx@linutronix.de> wrote:
>
> > The idle-thread-preemption-fix.patch introduced a race, which is not
> > critical, but might give us an extra turn through the scheduler. When
> > interrupts are reenabled in entry.c and an interrupt occures before we
> > reach the add_preempt_schedule() in preempt_schedule we get
> > rescheduled again in the return from interrupt path.
>
> i agree that there's a race. I solved this in the -RT patchset a couple
> of weeks ago, but in a different wasy. I introduced the
> preempt_schedule_irq() function and this solves the problem via keeping
> the whole IRQ-preemption path irqs-off. This has the advantage that if
> an IRQ signals preemption of a task and the kernel is immediately
> preemptable then we are able to hit that task atomically without
> re-enabling IRQs again. I'll split out this patch - can you see any
> problems with the preempt_schedule_irq() approach?
No.
I did not look into your RT patch for this, but please have a look at
RMK's ARM code, as he is doing some sanity check on
thread_info->preemption down there.
tglx
next prev parent reply other threads:[~2005-01-10 10:14 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-10 0:35 [PATCH 2.6.10-mm2] Fix preemption race [1/3] (Core) tglx
2005-01-10 0:53 ` [PATCH 2.6.10-mm2] Use the new preemption code [2/3] Thomas Gleixner
2005-01-10 1:06 ` Russell King
2005-01-10 1:18 ` [PATCH 2.6.10-mm2] Use the new preemption code [2/3] Resend Thomas Gleixner
2005-01-10 7:32 ` Andrew Morton
2005-01-10 10:57 ` Thomas Gleixner
2005-01-10 9:46 ` Russell King
2005-01-10 10:12 ` Thomas Gleixner
2005-01-10 11:02 ` Ingo Molnar
2005-01-10 13:46 ` Thomas Gleixner
2005-01-10 1:00 ` [PATCH 2.6.10-mm2] Use the new preemption code [3/3] Thomas Gleixner
2005-01-10 14:56 ` Tom Rini
2005-01-10 15:49 ` tglx
2005-01-10 9:15 ` [PATCH 2.6.10-mm2] Fix preemption race [1/3] (Core) Ingo Molnar
2005-01-10 10:14 ` Thomas Gleixner [this message]
-- strict thread matches above, loose matches on Subject: below --
2005-01-10 0:34 tglx
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=1105352084.3058.5.camel@lap02.tec.linutronix.de \
--to=tglx@linutronix.de \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).