Fix sleep_on functions
PATCH 1/1 Fix sleep_on functions
There is a problem with *_sleep_on() functions when they call schedule() . Interrupts should be enabled , but they aren't. So a warning message is printed letting everyone know that your calling schedule() from an invalid context.
Signed-off-by Daniel Walker <[email protected]>
kernel/sched.c +1 -1
@@ -3417,7 +3417,7 @@#define SLEEP_ON_HEAD \ spin_lock_irqsave(&q->lock,flags); \ __add_wait_queue(q, &wait); \ - spin_unlock(&q->lock); + spin_unlock_irq(&q->lock);#define SLEEP_ON_TAIL \ spin_lock_irq(&q->lock); \