Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael...
authorLinus Torvalds <torvalds@linux-foundation.org>
Mon, 25 May 2009 02:38:25 +0000 (19:38 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Mon, 25 May 2009 02:38:25 +0000 (19:38 -0700)
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6:
  PM: Do not hold dpm_list_mtx while disabling/enabling nonboot CPUs

init/main.c
kernel/async.c

index 3bbf93be744cf8be8614ca92c32b01181bf58a4f..d721dad05dd722fa065170e9f573a4f74c49d38d 100644 (file)
@@ -566,8 +566,7 @@ asmlinkage void __init start_kernel(void)
        tick_init();
        boot_cpu_init();
        page_address_init();
-       printk(KERN_NOTICE);
-       printk(linux_banner);
+       printk(KERN_NOTICE "%s", linux_banner);
        setup_arch(&command_line);
        mm_init_owner(&init_mm, &init_task);
        setup_command_line(command_line);
index 968ef9457d4ec90aeb5148695c31ae02b68d33bb..50540301ed0f2d5308ab15a012715bd0b53f0a04 100644 (file)
@@ -92,19 +92,23 @@ extern int initcall_debug;
 static async_cookie_t  __lowest_in_progress(struct list_head *running)
 {
        struct async_entry *entry;
+       async_cookie_t ret = next_cookie; /* begin with "infinity" value */
+
        if (!list_empty(running)) {
                entry = list_first_entry(running,
                        struct async_entry, list);
-               return entry->cookie;
-       } else if (!list_empty(&async_pending)) {
-               entry = list_first_entry(&async_pending,
-                       struct async_entry, list);
-               return entry->cookie;
-       } else {
-               /* nothing in progress... next_cookie is "infinity" */
-               return next_cookie;
+               ret = entry->cookie;
        }
 
+       if (!list_empty(&async_pending)) {
+               list_for_each_entry(entry, &async_pending, list)
+                       if (entry->running == running) {
+                               ret = entry->cookie;
+                               break;
+                       }
+       }
+
+       return ret;
 }
 
 static async_cookie_t  lowest_in_progress(struct list_head *running)