cvs commit: src/sys/kern kern_switch.c sched_4bsd.c

Stephan Uphoff ups at freebsd.org
Fri Jun 10 01:20:52 GMT 2005


On Thu, 2005-06-09 at 19:25, John Baldwin wrote:
> On Jun 9, 2005, at 12:43 PM, Stephan Uphoff wrote:
> 
> > ups         2005-06-09 19:43:08 UTC
> >
> >   FreeBSD src repository
> >
> >   Modified files:
> >     sys/kern             kern_switch.c sched_4bsd.c
> >   Log:
> >   Lots of whitespace cleanup.
> >   Fix for broken if condition.
> >
> >   Submitted by:   nate@
> 
> What was broken about the if test?  The intention was that when 
> FULL_PREEMPTION was off, we only preempt if the destination thread is 
> an ithread or if the current thread is an idle priority thread. 

I was under the impression that we never preempt the idle thread but did
not investigate closer.

Is it save to preempt the idle thread on x86 when it does its ACPI
C-state magic?

> I think you've changed it so that we never preempt if the current thread 
> is an idle thread now, which is very bad.  I took out explicit calls to 
> mi_switch() in the page zeroing thread in reliance on the behavior that 
> we always preempt an idle priority thread.

I will take a look later today.
If we can preempt the idle thread I am all for it.

Stephan



More information about the cvs-src mailing list