linux-mips
[Top] [All Lists]

Re: 2.6 preemptive kernel on mips

To: Tom Rini <trini@kernel.crashing.org>
Subject: Re: 2.6 preemptive kernel on mips
From: Jun Sun <jsun@mvista.com>
Date: Wed, 4 Aug 2004 15:25:06 -0700
Cc: Song Wang <wsonguci@yahoo.com>, linux-mips@linux-mips.org, jsun@mvista.com
In-reply-to: <20040804215140.GP9235@smtp.west.cox.net>; from trini@kernel.crashing.org on Wed, Aug 04, 2004 at 02:51:40PM -0700
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <20040803192244.5889.qmail@web40002.mail.yahoo.com> <20040803124048.C1926@mvista.com> <20040804215140.GP9235@smtp.west.cox.net>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.2.5i
On Wed, Aug 04, 2004 at 02:51:40PM -0700, Tom Rini wrote:
> On Tue, Aug 03, 2004 at 12:40:48PM -0700, Jun Sun wrote:
> 
> > On Tue, Aug 03, 2004 at 12:22:44PM -0700, Song Wang wrote:
> > > Hi,
> > > 
> > > Has anyone tried to enable kernel preemption on
> > > Linux mips 2.6 kernel (mips32) and test it? If
> > > so, which version does it work?
> > > 
> > > I tried on 2.6.3 and it didn't work.
> > > 
> > 
> > Try the latest kernel.  I checked preemption around 2.6.5 time
> > and I believe all the obvious problems are fixed then.
> > 
> > There are still some issues with both SMP and PREEMPT, but most
> > people won't see them in normal cases.
> 
> MIPS or generic?  It's claimed, at least, that SMP&&PREEMPT have no
> fatal, generic, issues now (I forget if that was the case around 2.6.5).
> 

It is MIPS specific problems I was referring to (such as unsafe 
smp_processor_id() reference etc).

If you think about it the real problem is that kernel has non-migratable
regions, a section where process should not migrate from one CPU to
another.  Before preemtible kernel is introduced such non-migratable
regions are not a problem because they can't migrate during those
regions.

So a potentially better solution is to introduce non-migratable
regions during which scheduler promises not to migrate the processes.
Under such promises a process can actually be preempted while
it is in such a region.

Jun

<Prev in Thread] Current Thread [Next in Thread>