|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [PATCH] pvops: Make suspend work when CONFIG_SUSPEND=n
Recent pvops kernel fails on suspending some of devices on the
following configuration:
CONFIG_SUSPEND=n
CONFIG_PM_SLEEP=y
Command suspend on control/shutdown is recognized when
CONFIG_PM_SLEEP=y. This indicates the device suspend logic should also
be enabled on this configuration.
The following patch works.
---
linux-2.6-xen/drivers/base/power/main.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/linux-2.6-xen/drivers/base/power/main.c
b/linux-2.6-xen/drivers/base/power/main.c
index 8aa2443..4d40fc4 100644
--- a/linux-2.6-xen/drivers/base/power/main.c
+++ b/linux-2.6-xen/drivers/base/power/main.c
@@ -174,7 +174,7 @@ static int pm_op(struct device *dev,
int error = 0;
switch (state.event) {
-#ifdef CONFIG_SUSPEND
+#if defined(CONFIG_SUSPEND) || defined(CONFIG_XEN_SAVE_RESTORE)
case PM_EVENT_SUSPEND:
if (ops->suspend) {
error = ops->suspend(dev);
@@ -238,7 +238,7 @@ static int pm_noirq_op(struct device *dev,
int error = 0;
switch (state.event) {
-#ifdef CONFIG_SUSPEND
+#if defined(CONFIG_SUSPEND) || defined(CONFIG_XEN_SAVE_RESTORE)
case PM_EVENT_SUSPEND:
if (ops->suspend_noirq) {
error = ops->suspend_noirq(dev);
--
1.7.0.4
--
潘震皓, Frank Pan
Computer Science and Technology
Tsinghua University
0001-Make-suspend-work-when-CONFIG_SUSPEND-n.patch
Description: Text Data
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [Xen-devel] [PATCH] pvops: Make suspend work when CONFIG_SUSPEND=n,
Frank Pan <=
|
|
|
|
|