提交 938cfed1 编写于 作者: J Jean Pihet 提交者: Ingo Molnar

perf: Add calls to suspend trace point

Uses the machine_suspend trace point, called from the
generic kernel suspend_devices_and_enter function.
Signed-off-by: NJean Pihet <j-pihet@ti.com>
Acked-by: NRafael J. Wysocki <rjw@sisk.pl>
Cc: Arjan van de Ven <arjan@linux.intel.com>
CC: Thomas Renninger <trenn@suse.de>
Cc: Len Brown <len.brown@intel.com>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: linux-pm@lists.linux-foundation.org
LKML-Reference: <1294253342-29056-2-git-send-email-j-pihet@ti.com>
Signed-off-by: NIngo Molnar <mingo@elte.hu>
上级 eccdfe2d
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include <linux/mm.h> #include <linux/mm.h>
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/suspend.h> #include <linux/suspend.h>
#include <trace/events/power.h>
#include "power.h" #include "power.h"
...@@ -201,6 +202,7 @@ int suspend_devices_and_enter(suspend_state_t state) ...@@ -201,6 +202,7 @@ int suspend_devices_and_enter(suspend_state_t state)
if (!suspend_ops) if (!suspend_ops)
return -ENOSYS; return -ENOSYS;
trace_machine_suspend(state);
if (suspend_ops->begin) { if (suspend_ops->begin) {
error = suspend_ops->begin(state); error = suspend_ops->begin(state);
if (error) if (error)
...@@ -229,6 +231,7 @@ int suspend_devices_and_enter(suspend_state_t state) ...@@ -229,6 +231,7 @@ int suspend_devices_and_enter(suspend_state_t state)
Close: Close:
if (suspend_ops->end) if (suspend_ops->end)
suspend_ops->end(); suspend_ops->end();
trace_machine_suspend(PWR_EVENT_EXIT);
return error; return error;
Recover_platform: Recover_platform:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册