aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/base/power/suspend.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/base/power/suspend.c')
-rw-r--r--drivers/base/power/suspend.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/base/power/suspend.c b/drivers/base/power/suspend.c
index ece136bf97e3..42d2b86ba765 100644
--- a/drivers/base/power/suspend.c
+++ b/drivers/base/power/suspend.c
@@ -78,6 +78,18 @@ int suspend_device(struct device * dev, pm_message_t state)
78 suspend_report_result(dev->class->suspend, error); 78 suspend_report_result(dev->class->suspend, error);
79 } 79 }
80 80
81 if (!error && dev->type && dev->type->suspend && !dev->power.power_state.event) {
82 dev_dbg(dev, "%s%s\n",
83 suspend_verb(state.event),
84 ((state.event == PM_EVENT_SUSPEND)
85 && device_may_wakeup(dev))
86 ? ", may wakeup"
87 : ""
88 );
89 error = dev->type->suspend(dev, state);
90 suspend_report_result(dev->type->suspend, error);
91 }
92
81 if (!error && dev->bus && dev->bus->suspend && !dev->power.power_state.event) { 93 if (!error && dev->bus && dev->bus->suspend && !dev->power.power_state.event) {
82 dev_dbg(dev, "%s%s\n", 94 dev_dbg(dev, "%s%s\n",
83 suspend_verb(state.event), 95 suspend_verb(state.event),