summaryrefslogtreecommitdiff
path: root/drivers/base/power
diff options
context:
space:
mode:
authorChen Yu <yu.c.chen@intel.com>2020-10-23 19:02:54 +0800
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2020-11-10 19:41:40 +0100
commitf39ee99f5118a71ea162f8f66d743a8c4c401540 (patch)
treed8de873a129ad95d33f7f449703bbc24aee7b5f6 /drivers/base/power
parentf8394f232b1eab649ce2df5c5f15b0e528c92091 (diff)
PM: sleep: Print driver flags for all devices during suspend/resume
Currently there are 4 driver flags to control system suspend/resume behavior: DPM_FLAG_NO_DIRECT_COMPLETE, DPM_FLAG_SMART_PREPARE, DPM_FLAG_SMART_SUSPEND and DPM_FLAG_MAY_SKIP_RESUME. Print these flags during suspend/resume so as to get a brief understanding of the expected behavior of each device, and to facilitate suspend/resume debugging/tuning. To enable this tracing: echo 'file drivers/base/power/main.c +p' > /sys/kernel/debug/dynamic_debug/control Signed-off-by: Chen Yu <yu.c.chen@intel.com> [ rjw: Subject and changelog edits ] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/base/power')
-rw-r--r--drivers/base/power/main.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c
index c7ac49042cee..2b4255dc101e 100644
--- a/drivers/base/power/main.c
+++ b/drivers/base/power/main.c
@@ -441,9 +441,9 @@ static pm_callback_t pm_noirq_op(const struct dev_pm_ops *ops, pm_message_t stat
static void pm_dev_dbg(struct device *dev, pm_message_t state, const char *info)
{
- dev_dbg(dev, "%s%s%s\n", info, pm_verb(state.event),
+ dev_dbg(dev, "%s%s%s driver flags: %x\n", info, pm_verb(state.event),
((state.event & PM_EVENT_SLEEP) && device_may_wakeup(dev)) ?
- ", may wakeup" : "");
+ ", may wakeup" : "", dev->power.driver_flags);
}
static void pm_dev_err(struct device *dev, pm_message_t state, const char *info,