]> git.hungrycats.org Git - linux/commitdiff
[PATCH] Kill early might_sleep warnings
authorAndrew Morton <akpm@osdl.org>
Wed, 22 Oct 2003 01:21:05 +0000 (18:21 -0700)
committerLinus Torvalds <torvalds@home.osdl.org>
Wed, 22 Oct 2003 01:21:05 +0000 (18:21 -0700)
OK, I give up.  Kill all the might_sleep warnings from the early boot
process.

kernel/sched.c

index afdac563aed8af6286a05071203f6b9a0c4e8360..7a13a492c62d509178d1c5687ba88b2bc7c886cd 100644 (file)
@@ -2848,7 +2848,7 @@ void __might_sleep(char *file, int line)
 #if defined(in_atomic)
        static unsigned long prev_jiffy;        /* ratelimiting */
 
-       if (in_atomic() || irqs_disabled()) {
+       if ((in_atomic() || irqs_disabled()) && system_running) {
                if (time_before(jiffies, prev_jiffy + HZ) && prev_jiffy)
                        return;
                prev_jiffy = jiffies;