Re: [patch] entry.S calling schedule() with interrupts disabled, 2.2.2

Alan Cox (alan@lxorguk.ukuu.org.uk)
Mon, 1 Mar 1999 19:35:57 +0000 (GMT)


> schedule() with interrupts disabled, and remove that __sti() from the
> context switch path :) After changing sleep_on* and ret_from_irq i can see
> no other places that call schedule() with interrupts disabled.

Look harder, lots of drivers and net stuff does. Its a standard scheme to
avoid races

cli();
while(foo)
{
if(something_case)
break;
sleep_on*(&blah);
}
restore_flags(flags);

Alan

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/