]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - kernel/power/main.c
suspend: fix ia64 allmodconfig build
[linux-2.6-omap-h63xx.git] / kernel / power / main.c
index 7fb805de19a85fd6272a6562f0ccc0e9f38fa0e7..050a6077ea454225f7908c11dd170c094ded16e0 100644 (file)
@@ -53,10 +53,6 @@ int pm_notifier_call_chain(unsigned long val)
                        == NOTIFY_BAD) ? -EINVAL : 0;
 }
 
-#endif /* CONFIG_PM_SLEEP */
-
-#ifdef CONFIG_SUSPEND
-
 #ifdef CONFIG_PM_DEBUG
 int pm_test_level = TEST_NONE;
 
@@ -132,6 +128,7 @@ power_attr(pm_test);
 static inline int suspend_test(int level) { return 0; }
 #endif /* !CONFIG_PM_DEBUG */
 
+#endif /* CONFIG_PM_SLEEP */
 
 #ifdef CONFIG_SUSPEND
 
@@ -235,7 +232,7 @@ static int suspend_enter(suspend_state_t state)
        BUG_ON(!irqs_disabled());
 
        if ((error = device_power_down(PMSG_SUSPEND))) {
-               printk(KERN_ERR "Some devices failed to power down\n");
+               printk(KERN_ERR "PM: Some devices failed to power down\n");
                goto Done;
        }
 
@@ -250,8 +247,8 @@ static int suspend_enter(suspend_state_t state)
 }
 
 /**
- *     suspend_devices_and_enter - suspend devices and enter the desired system sleep
- *                       state.
+ *     suspend_devices_and_enter - suspend devices and enter the desired system
+ *                                 sleep state.
  *     @state:           state to enter
  */
 int suspend_devices_and_enter(suspend_state_t state)
@@ -269,7 +266,7 @@ int suspend_devices_and_enter(suspend_state_t state)
        suspend_console();
        error = device_suspend(PMSG_SUSPEND);
        if (error) {
-               printk(KERN_ERR "Some devices failed to suspend\n");
+               printk(KERN_ERR "PM: Some devices failed to suspend\n");
                goto Resume_console;
        }
 
@@ -352,7 +349,7 @@ static int enter_state(suspend_state_t state)
        if (!mutex_trylock(&pm_mutex))
                return -EBUSY;
 
-       printk("Syncing filesystems ... ");
+       printk(KERN_INFO "PM: Syncing filesystems ... ");
        sys_sync();
        printk("done.\n");
 
@@ -495,7 +492,7 @@ static struct attribute * g[] = {
 #ifdef CONFIG_PM_TRACE
        &pm_trace_attr.attr,
 #endif
-#ifdef CONFIG_PM_DEBUG
+#if defined(CONFIG_PM_SLEEP) && defined(CONFIG_PM_DEBUG)
        &pm_test_attr.attr,
 #endif
        NULL,