Suspend2 merge: 1/51: Device trees
Subsystems (4)
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi!
Quoted 10 lines
This patch allows the device tree to be split up into multiple trees. I don't really expect it to be merged, but it is an important part of suspend at the moment, and I certainly want to see something like it that will allow us to suspend some parts of the device tree and not others. Suspend2 uses it to keep alive the hard drive (or equivalent) that we're writing the image to while suspending other devices, thus improving the consistency of the image written.
I remember from last time this was posted that someone commented on exporting the default device tree; I haven't changed that yet.
Q: I do not understand why you have such strong objections to idea of selective suspend.
A: Do selective suspend during runtime power managment, that's okay. But
its useless for suspend-to-disk. (And I do not see how you could use it for suspend-to-ram, I hope you do not want that).
Lets see, so you suggest to
* SUSPEND all but swap device and parents
* Snapshot
* Write image to disk
* SUSPEND swap device and parents
* Powerdown
Oh no, that does not work, if swap device or its parents uses DMA, you've corrupted data. You'd have to do
* SUSPEND all but swap device and parents
* FREEZE swap device and parents
* Snapshot
* UNFREEZE swap device and parents
* Write
* SUSPEND swap device and parents
Which means that you still need that FREEZE state, and you get more complicated code. (And I have not yet introduce details like system devices).
Pavel
Signature · 2 lines
People were complaining that M$ turns users into beta-testers... ...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
Hi.
Quoted 39 lines · Pavel Machek
Hi!
Quoted 10 lines
This patch allows the device tree to be split up into multiple trees. I don't really expect it to be merged, but it is an important part of suspend at the moment, and I certainly want to see something like it that will allow us to suspend some parts of the device tree and not others. Suspend2 uses it to keep alive the hard drive (or equivalent) that we're writing the image to while suspending other devices, thus improving the consistency of the image written.
I remember from last time this was posted that someone commented on exporting the default device tree; I haven't changed that yet.
Q: I do not understand why you have such strong objections to idea of selective suspend.
A: Do selective suspend during runtime power managment, that's okay. But
its useless for suspend-to-disk. (And I do not see how you could use it for suspend-to-ram, I hope you do not want that).Lets see, so you suggest to
* SUSPEND all but swap device and parents
* Snapshot
* Write image to disk
* SUSPEND swap device and parents
* PowerdownOh no, that does not work, if swap device or its parents uses DMA, you've corrupted data. You'd have to do
* SUSPEND all but swap device and parents
* FREEZE swap device and parents
* Snapshot
* UNFREEZE swap device and parents
* Write
* SUSPEND swap device and parents
Quoted 3 lines
Which means that you still need that FREEZE state, and you get more complicated code. (And I have not yet introduce details like system devices).
There's obviously a misunderstanding here. What I do is:
SUSPEND all but swap device and parents
WRITE LRU pages
SUSPEND swap device and parents (+sysdev)
Snapshot
RESUME swap device and parents (+sysdev)
WRITE snapshot
SUSPEND swap device and parents
POWERDOWN everything
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Regards,
Nigel
Signature · 7 lines
Nigel Cunningham Pastoral Worker Christian Reformed Church of Tuggeranong PO Box 1004, Tuggeranong, ACT 2901 You see, at just the right time, when we were still powerless, Christ died for the ungodly. -- Romans 5:6
Hi!
Quoted 37 lines
Quoted 37 lines
Quoted 10 lines
This patch allows the device tree to be split up into multiple trees. I don't really expect it to be merged, but it is an important part of suspend at the moment, and I certainly want to see something like it that will allow us to suspend some parts of the device tree and not others. Suspend2 uses it to keep alive the hard drive (or equivalent) that we're writing the image to while suspending other devices, thus improving the consistency of the image written.
I remember from last time this was posted that someone commented on exporting the default device tree; I haven't changed that yet.
Q: I do not understand why you have such strong objections to idea of selective suspend.
A: Do selective suspend during runtime power managment, that's okay. But
its useless for suspend-to-disk. (And I do not see how you could use it for suspend-to-ram, I hope you do not want that).Lets see, so you suggest to
* SUSPEND all but swap device and parents
* Snapshot
* Write image to disk
* SUSPEND swap device and parents
* PowerdownOh no, that does not work, if swap device or its parents uses DMA, you've corrupted data. You'd have to do
* SUSPEND all but swap device and parents
* FREEZE swap device and parents
* Snapshot
* UNFREEZE swap device and parents
* Write
* SUSPEND swap device and parents
Quoted 5 lines
Quoted 3 lines
Which means that you still need that FREEZE state, and you get more complicated code. (And I have not yet introduce details like system devices).
There's obviously a misunderstanding here. What I do is:
Ok, sorry, this was from another flamewar ;).
Quoted 9 lines
SUSPEND all but swap device and parents
WRITE LRU pages
SUSPEND swap device and parents (+sysdev)
Snapshot
RESUME swap device and parents (+sysdev)
WRITE snapshot
SUSPEND swap device and parents
POWERDOWN everything
Quoted 9 lines
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Uh... It seems like quite a lot of work. Would not reserving few more pages help here? Or perhaps right solution is to fix "broken" drivers that need too much memory...
...because you loose anyway if that "broken" driver is between swap device and root.
Pavel
Signature · 2 lines
People were complaining that M$ turns users into beta-testers... ...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
Hi.
Quoted 10 lines · Pavel Machek
Quoted 9 lines
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Quoted 3 lines
Uh... It seems like quite a lot of work. Would not reserving few more pages help here? Or perhaps right solution is to fix "broken" drivers that need too much memory...
I'd agree, except that I don't know how many to allocate. It makes getting a reliable suspend the result of guess work and favourable circumstances. Fixing 'broken' drivers by really suspending them seems to me to be the right solution. Make their memory requirements perfectly predictable.
Regards,
Nigel
Signature · 7 lines
Nigel Cunningham Pastoral Worker Christian Reformed Church of Tuggeranong PO Box 1004, Tuggeranong, ACT 2901 You see, at just the right time, when we were still powerless, Christ died for the ungodly. -- Romans 5:6
Hi!
Quoted 14 lines
Quoted 10 lines
Quoted 9 lines
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Quoted 3 lines
Uh... It seems like quite a lot of work. Would not reserving few more pages help here? Or perhaps right solution is to fix "broken" drivers that need too much memory...
Quoted 5 lines
I'd agree, except that I don't know how many to allocate. It makes getting a reliable suspend the result of guess work and favourable circumstances. Fixing 'broken' drivers by really suspending them seems to me to be the right solution. Make their memory requirements perfectly predictable.
Except for the few drivers that are between suspend device and root. So you still have the same problem, and still need to guess. Plus you get complex changes to driver model.
Pavel
Signature · 2 lines
People were complaining that M$ turns users into beta-testers... ...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
Hi.
Quoted 20 lines · Pavel Machek
Quoted 14 lines
Quoted 10 lines
Quoted 9 lines
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Quoted 3 lines
Uh... It seems like quite a lot of work. Would not reserving few more pages help here? Or perhaps right solution is to fix "broken" drivers that need too much memory...
Quoted 5 lines
I'd agree, except that I don't know how many to allocate. It makes getting a reliable suspend the result of guess work and favourable circumstances. Fixing 'broken' drivers by really suspending them seems to me to be the right solution. Make their memory requirements perfectly predictable.
Quoted 3 lines
Except for the few drivers that are between suspend device and root. So you still have the same problem, and still need to guess. Plus you get complex changes to driver model.
I think you're overstating your case. All we're talking about doing is quiescing the same drivers that would be quiesced later, in the same way, but earlier in the process. Apart from the code I already have in that patch, nothing else is needed. The changes aren't that complex, either.
Signature · 7 lines
Nigel Cunningham Pastoral Worker Christian Reformed Church of Tuggeranong PO Box 1004, Tuggeranong, ACT 2901 You see, at just the right time, when we were still powerless, Christ died for the ungodly. -- Romans 5:6
Hi!
Quoted 10 lines
Quoted 9 lines
Quoted 5 lines
I'd agree, except that I don't know how many to allocate. It makes getting a reliable suspend the result of guess work and favourable circumstances. Fixing 'broken' drivers by really suspending them seems to me to be the right solution. Make their memory requirements perfectly predictable.
Except for the few drivers that are between suspend device and root. So you still have the same problem, and still need to guess. Plus you get complex changes to driver model.
Quoted 5 lines
I think you're overstating your case. All we're talking about doing is quiescing the same drivers that would be quiesced later, in the same way, but earlier in the process. Apart from the code I already have in that patch, nothing else is needed. The changes aren't that complex, either.
Driver model now needs to know how to handle tree where some parts are suspended and some are not, and I think that's quite a big change.
Pavel
Signature · 2 lines
People were complaining that M$ turns users into beta-testers... ...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
Quoted 2 lines · Nigel Cunningham
Hi.
.......
Quoted 12 lines
There's obviously a misunderstanding here. What I do is:
SUSPEND all but swap device and parents
WRITE LRU pages
SUSPEND swap device and parents (+sysdev)
Snapshot
RESUME swap device and parents (+sysdev)
WRITE snapshot
SUSPEND swap device and parents
POWERDOWN everything
Quoted 10 lines
I thought I wrote - perhaps I'm wrong here - that I understand that your new work in this area might make this unnecessary. I really only want to do it this way because I don't know what other drivers might be doing while we're writing the LRU pages. I'm not worried about them touching LRU. What I am worried about is them allocating memory and starving suspend so that we get hangs due to being oom. If they're suspended, we have more certainty as to how memory is being used. I don't remember what prompted me to do this in the first place, but I'm pretty sure it would have been a real observed issue.
Here is a patch make swsusp1 follow above safe LRU saving, :), Most code merge from suspend2, still relative with pavel's big patch.
-core.diff-
kernel/power/disk.c +18 -49
@@ -16,10 +16,11 @@#include <linux/device.h> #include <linux/delay.h> #include <linux/fs.h> +#include <linux/reboot.h> #include <linux/device.h> #include "power.h" - +extern struct partial_device_tree *swsusp_dev_tree;extern suspend_disk_method_t pm_disk_mode;extern struct pm_ops * pm_ops;
@@ -29,6 +30,8 @@ extern int swsusp_read(void);extern int swsusp_resume (void );extern int swsusp_free (void ); +extern int swsusp_prepare_suspend (void ); +extern int swsusp_post_resume (void );static int noresume =0 ;char resume_file[256 ] =CONFIG_PM_STD_PARTITION ;
@@ -48,19 +51,20 @@ static void power_down(suspend_disk_methunsigned long flags;int error =0 ; -local_irq_save (flags);switch (mode) {case PM_DISK_PLATFORM : -device_power_down (PMSG_SUSPEND ); +local_irq_save (flags); error = pm_ops->enter (PM_SUSPEND_DISK ); +local_irq_restore (flags);break ;case PM_DISK_SHUTDOWN :printk ("Powering off system\n" ); -device_shutdown (); +notifier_call_chain (&reboot_notifier_list,SYS_POWER_OFF ,NULL ); +device_suspend_tree (PMSG_FREEZE , swsusp_dev_tree);machine_power_off ();break ;case PM_DISK_REBOOT : -device_shutdown (); +device_suspend_tree (PMSG_FREEZE , swsusp_dev_tree);machine_restart (NULL );break ; }
@@ -74,38 +78,6 @@ static void power_down(suspend_disk_meth static int in_suspend __nosavedata = 0; - -/** -* free_some_memory - Try to free as much memory as possible -* -* ... but do not OOM-kill anyone -* -* Notice: all userland should be stopped at this point, or -* livelock is possible. -*/ - -static void free_some_memory (void ) -{ -int i; -for (i=0 ; i<5 ; i++) { -int i =0 , tmp; -long pages =0 ; -char *p ="-\\|/" ; - -printk ("Freeing memory... " ); -while ((tmp =shrink_all_memory (10000 ))) { - pages += tmp; -printk ("\b%c" , p[i]); - i++; -if (i >3 ) - i =0 ; - } -printk ("\bdone (%li pages freed)\n" , pages); - current->state =TASK_INTERRUPTIBLE ; -schedule_timeout (HZ /5 ); - } -} -static inline void platform_finish (void ) {if (pm_disk_mode ==PM_DISK_PLATFORM ) {
@@ -116,7 +88,7 @@ static inline void platform_finish(void)static void finish (void ) { -device_resume (); +swsusp_post_resume ();platform_finish ();enable_nonboot_cpus ();thaw_processes ();
@@ -124,7 +96,7 @@ static void finish(void) } -static int prepare (void ) +static int prepare (int resume) {int error;
@@ -143,14 +115,11 @@ static int prepare(void) } } -/* Free memory before shutting down devices. */ -free_some_memory (); -disable_nonboot_cpus (); -if ((error =device_suspend (PMSG_FREEZE ))) { -printk ("Some devices failed to suspend\n" ); - goto Finish; - } +if (!resume) +if ((error =swsusp_prepare_suspend ())) { + goto Finish; + }return 0 ; Finish:
@@ -176,7 +145,7 @@ int pm_suspend_disk(void) {int error; -if ((error =prepare ())) +if ((error =prepare (0 )))return error;pr_debug ("PM: Attempting to suspend to disk.\n" );
@@ -233,7 +202,7 @@ static int software_resume(void)pr_debug ("PM: Preparing system for restore.\n" ); -if ((error =prepare ())) +if ((error =prepare (1 ))) goto Free;barrier ();
@@ -241,7 +210,7 @@ static int software_resume(void)pr_debug ("PM: Restoring saved image.\n" );swsusp_resume (); -pr_debug ("PM: Restore failed, recovering.n" ); +pr_debug ("PM: Restore failed, recovering.\n" );finish (); Free:swsusp_free ();
kernel/power/main.c +1 -1
@@ -4,7 +4,7 @@* Copyright (c) 2003 Patrick Mochel * Copyright (c) 2003 Open Source Development Lab * -* This file is release under the GPLv2 +* This file is released under the GPLv2 * */
kernel/power/swsusp.c +905 -308
1,514 lines not on this page · raw message
--
Hu Gang / Steve
Linux Registered User 204016
GPG Public Key: http://soulinfo.com/~hugang/hugang.asc
Quoted 10 lines
SUSPEND all but swap device and parents
WRITE LRU pages
SUSPEND swap device and parents (+sysdev)
Snapshot
RESUME swap device and parents (+sysdev)
WRITE snapshot
SUSPEND swap device and parents
POWERDOWN everything
-device-tree.diff-
drivers/base/class.c +21 -0
@@ -465,6 +465,25 @@ void class_device_put(struct class_devickobject_put (&class_dev->kobj); } +struct class *class_find (char * name) +{ +struct class * this_class; + +if (!name) +return NULL ; + +down_read (&class_subsys.rwsem); +list_for_each_entry (this_class, &class_subsys.kset.list, subsys.kset.kobj.entry) { +if (!(strcmp (this_class->name, name))) { +class_get (this_class); +up_read (&class_subsys.rwsem); +return this_class; + } + } +up_read (&class_subsys.rwsem); + +return NULL ; +}int class_interface_register (struct class_interface *class_intf) {
@@ -547,3 +566,5 @@ EXPORT_SYMBOL(class_device_remove_file);EXPORT_SYMBOL (class_interface_register);EXPORT_SYMBOL (class_interface_unregister); + +EXPORT_SYMBOL (class_find);
drivers/base/power/main.c +19 -5
@@ -4,6 +4,9 @@* Copyright (c) 2003 Patrick Mochel * Copyright (c) 2003 Open Source Development Lab * +* Partial tree additions +* Copyright (c) 2004 Nigel Cunningham +* * This file is released under the GPLv2 * *
@@ -23,10 +26,18 @@#include <linux/device.h> #include "power.h" -LIST_HEAD (dpm_active); -LIST_HEAD (dpm_off); -LIST_HEAD (dpm_off_irq); - +struct partial_device_tree default_device_tree = +{ + .dpm_active =LIST_HEAD_INIT (default_device_tree.dpm_active), + .dpm_off =LIST_HEAD_INIT (default_device_tree.dpm_off), + .dpm_off_irq =LIST_HEAD_INIT (default_device_tree.dpm_off_irq), +}; +EXPORT_SYMBOL (default_device_tree); + +/* +* One mutex for all trees because we can be moving items +* between trees. +*/ DECLARE_MUTEX (dpm_sem);/*
@@ -76,7 +87,9 @@ int device_pm_add(struct device * dev) dev->bus ? dev->bus->name : "No Bus", dev->kobj.name);atomic_set (&dev->power.pm_users,0 );down (&dpm_sem); -list_add_tail (&dev->power.entry, &dpm_active); +list_add_tail (&dev->power.entry, &default_device_tree.dpm_active); + dev->current_list =DEVICE_LIST_DPM_ACTIVE ; + dev->tree = &default_device_tree;device_pm_set_parent (dev, dev->parent);if ((error =dpm_sysfs_add (dev)))list_del (&dev->power.entry);
@@ -92,6 +105,7 @@ void device_pm_remove(struct device * dedpm_sysfs_remove (dev);device_pm_release (dev->power.pm_parent);list_del (&dev->power.entry); + dev->current_list =DEVICE_LIST_NONE ;up (&dpm_sem); }
drivers/base/power/Makefile +1 -1
@@ -1,5 +1,5 @@ obj-y := shutdown.o -obj-$(CONFIG_PM) += main.o suspend.o resume.o runtime.o sysfs.o +obj-$(CONFIG_PM) += main.o suspend.o resume.o runtime.o sysfs.o tree.o ifeq ($(CONFIG_DEBUG_DRIVER),y) EXTRA_CFLAGS += -DDEBUG
drivers/base/power/power.h +17 -3
@@ -30,10 +30,22 @@ extern struct semaphore dpm_sem;/* * The PM lists. */ -extern struct list_head dpm_active; -extern struct list_head dpm_off; -extern struct list_head dpm_off_irq; +struct partial_device_tree +{ +struct list_head dpm_active; +struct list_head dpm_off; +struct list_head dpm_off_irq; +}; + +enum { +DEVICE_LIST_NONE , +DEVICE_LIST_DPM_ACTIVE , +DEVICE_LIST_DPM_OFF , +DEVICE_LIST_DPM_OFF_IRQ , +}; + +extern struct partial_device_tree default_device_tree;static inline struct dev_pm_info *to_pm_info (struct list_head * entry) {
@@ -59,7 +71,9 @@ extern void dpm_sysfs_remove(struct devi* resume.c */ +extern void dpm_resume_tree (struct partial_device_tree * tree);extern void dpm_resume (void ); +extern void dpm_power_up_tree (struct partial_device_tree * tree);extern void dpm_power_up (void );extern int resume_device (struct device *);
drivers/base/power/resume.c +81 -9
129 lines not on this page · raw message
drivers/base/power/shutdown.c +1 -0
@@ -66,3 +66,4 @@ void device_shutdown(void)sysdev_shutdown (); } +EXPORT_SYMBOL (device_shutdown);
drivers/base/power/suspend.c +27 -13
@@ -51,7 +51,7 @@ int suspend_device(struct device * dev,/** -* device_suspend - Save state and stop all devices in system. +* device_suspend_tree - Save state and stop all devices in system. * @state: Power state to put each device in. * * Walk the dpm_active list, call ->suspend() for each device, and move
@@ -60,7 +60,7 @@ int suspend_device(struct device * dev,* the device to the dpm_off list. If it returns -EAGAIN, we move it to * the dpm_off_irq list. If we get a different error, try and back out. * -* If we hit a failure with any of the devices, call device_resume() +* If we hit a failure with any of the devices, call device_resume_tree() * above to bring the suspended devices back to life. * * Note this function leaves dpm_sem held to
@@ -70,22 +70,24 @@ int suspend_device(struct device * dev,* */ -int device_suspend (pm_message_t state) +int device_suspend_tree (pm_message_t state,struct partial_device_tree * tree) {int error =0 ;down (&dpm_sem); -while (!list_empty (&dpm_active)) { -struct list_head * entry = dpm_active.prev; +while (!list_empty (&tree->dpm_active)) { +struct list_head * entry = tree->dpm_active.prev;struct device * dev =to_device (entry); error =suspend_device (dev, state);if (!error) {list_del (&dev->power.entry); -list_add (&dev->power.entry, &dpm_off); +list_add (&dev->power.entry, &tree->dpm_off); + dev->current_list =DEVICE_LIST_DPM_OFF ; }else if (error == -EAGAIN ) {list_del (&dev->power.entry); -list_add (&dev->power.entry, &dpm_off_irq); +list_add (&dev->power.entry, &tree->dpm_off_irq); + dev->current_list =DEVICE_LIST_DPM_OFF_IRQ ; }else {printk (KERN_ERR "Could not suspend device %s: " "error %d\n" ,kobject_name (&dev->kobj), error);
@@ -96,10 +98,15 @@ int device_suspend(pm_message_t state)up (&dpm_sem);return error; Error: -dpm_resume (); +dpm_resume_tree (tree); goto Done; } +EXPORT_SYMBOL (device_suspend_tree); +int device_suspend (pm_message_t state) +{ +return device_suspend_tree (state, &default_device_tree); +}EXPORT_SYMBOL (device_suspend);
@@ -112,19 +119,17 @@ EXPORT_SYMBOL(device_suspend);* done, power down system devices. */ -int device_power_down (pm_message_t state) +int device_power_down_tree (pm_message_t state,struct partial_device_tree * tree) {int error =0 ;struct device * dev; -list_for_each_entry_reverse (dev, &dpm_off_irq, power.entry) { +list_for_each_entry_reverse (dev, &tree->dpm_off_irq, power.entry) {if ((error =suspend_device (dev, state)))break ; }if (error) goto Error; -if ((error =sysdev_suspend (state))) - goto Error; Done:return error; Error:
@@ -132,5 +137,14 @@ int device_power_down(pm_message_t state goto Done; } -EXPORT_SYMBOL (device_power_down); +EXPORT_SYMBOL (device_power_down_tree); +int device_power_down (pm_message_t state) +{ +int error; + +if (!(error =device_power_down_tree (state, &default_device_tree))) + error =sysdev_suspend (state); +return error; +} +EXPORT_SYMBOL (device_power_down);
Only in 2.6.9/drivers/base/power: tree.c
drivers/base/sys.c +2 -1
@@ -337,7 +337,7 @@ int sysdev_suspend(u32 state) }return 0 ; } - +EXPORT_SYMBOL (sysdev_suspend);/** * sysdev_resume - Bring system devices back to life.
@@ -384,6 +384,7 @@ int sysdev_resume(void) }return 0 ; } +EXPORT_SYMBOL (sysdev_resume);int __init system_bus_init (void )
Signature · 4 lines
-- Hu Gang / Steve Linux Registered User 204016 GPG Public Key: http://soulinfo.com/~hugang/hugang.asc
Hi!
Quoted 10 lines
Quoted 9 lines
SUSPEND all but swap device and parents
WRITE LRU pages
SUSPEND swap device and parents (+sysdev)
Snapshot
RESUME swap device and parents (+sysdev)
WRITE snapshot
SUSPEND swap device and parents
POWERDOWN everything-device-tree.diff-
(snipped 420 lines of diff)
No, this one should not be neccessary. It is there only to solve some memory problems, and it does not solve them anyway.
Pavel
Signature · 2 lines
People were complaining that M$ turns users into beta-testers... ...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!