diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2007-11-19 23:46:16 +0100 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2008-02-01 18:30:54 -0500 |
commit | 90dda1cb6ace6abd777f84bf051c4f86fa58986a (patch) | |
tree | b53a566118e5e130a55707bea6d01e112508c8df /kernel/power | |
parent | ce2b7147bb83b7d729b17c1638f092a1bcba4981 (diff) | |
download | blackbird-obmc-linux-90dda1cb6ace6abd777f84bf051c4f86fa58986a.tar.gz blackbird-obmc-linux-90dda1cb6ace6abd777f84bf051c4f86fa58986a.zip |
PM: Make PM_TRACE more architecture independent
When trying to debug a suspend failure I started implementing
PM_TRACE for powerpc. I then noticed that I'm debugging a suspend
failure and so PM_TRACE isn't useful at all, but thought that
nonetheless this could be useful in the future.
Basically, to support PM_TRACE, you add a Kconfig option that
selects PM_TRACE and provides the infrastructure as per the
help text of PM_TRACE.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'kernel/power')
-rw-r--r-- | kernel/power/Kconfig | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/kernel/power/Kconfig b/kernel/power/Kconfig index 8e186c678149..06a08f7cebda 100644 --- a/kernel/power/Kconfig +++ b/kernel/power/Kconfig @@ -44,9 +44,30 @@ config PM_VERBOSE ---help--- This option enables verbose messages from the Power Management code. +config CAN_PM_TRACE + def_bool y + depends on PM_DEBUG && PM_SLEEP && EXPERIMENTAL + config PM_TRACE + bool + help + This enables code to save the last PM event point across + reboot. The architecture needs to support this, x86 for + example does by saving things in the RTC, see below. + + The architecture specific code must provide the extern + functions from <linux/resume-trace.h> as well as the + <asm/resume-trace.h> header with a TRACE_RESUME() macro. + + The way the information is presented is architecture- + dependent, x86 will print the information during a + late_initcall. + +config PM_TRACE_RTC bool "Suspend/resume event tracing" - depends on PM_DEBUG && X86 && PM_SLEEP && EXPERIMENTAL + depends on CAN_PM_TRACE + depends on X86 + select PM_TRACE default n ---help--- This enables some cheesy code to save the last PM event point in the |