swsusp: fix error handling in "not enough swap space"

Pavel Machek
2004-02-29T13:04:18Z

Hi!

Without this, if there's not enough swapspace, suspend fails, but
leaves devices suspended, leading to dead machine. Please apply,

Pavel

--- tmp/linux/kernel/power/swsusp.c 2004-02-29 13:42:02.000000000 +0100
+++ linux/kernel/power/swsusp.c 2004-02-29 00:34:31.000000000 +0100
@@ -683,7 +683,11 @@

free_pages((unsigned long) pagedir_nosave, pagedir_order);
spin_unlock_irq(&suspend_pagedir_lock);
+
+ device_resume();
+ PRINTK( "Fixing swap signatures... " );
mark_swapfiles(((swp_entry_t) {0}), MARK_SWAP_RESUME);
+ PRINTK( "ok\n" );
}

/*

--
When do you have a heart between your knees?
[Johanka's followup: and *two* hearts?]