2009-02-08 05:16:12 +08:00
|
|
|
#ifndef _TRACE_POWER_H
|
|
|
|
#define _TRACE_POWER_H
|
|
|
|
|
|
|
|
#include <linux/ktime.h>
|
2009-02-12 02:57:25 +08:00
|
|
|
#include <linux/tracepoint.h>
|
2009-02-08 05:16:12 +08:00
|
|
|
|
|
|
|
enum {
|
|
|
|
POWER_NONE = 0,
|
|
|
|
POWER_CSTATE = 1,
|
|
|
|
POWER_PSTATE = 2,
|
|
|
|
};
|
|
|
|
|
|
|
|
struct power_trace {
|
|
|
|
ktime_t stamp;
|
|
|
|
ktime_t end;
|
|
|
|
int type;
|
|
|
|
int state;
|
|
|
|
};
|
|
|
|
|
2009-02-12 02:57:25 +08:00
|
|
|
DECLARE_TRACE(power_start,
|
|
|
|
TPPROTO(struct power_trace *it, unsigned int type, unsigned int state),
|
|
|
|
TPARGS(it, type, state));
|
|
|
|
|
|
|
|
DECLARE_TRACE(power_mark,
|
|
|
|
TPPROTO(struct power_trace *it, unsigned int type, unsigned int state),
|
|
|
|
TPARGS(it, type, state));
|
|
|
|
|
|
|
|
DECLARE_TRACE(power_end,
|
|
|
|
TPPROTO(struct power_trace *it),
|
|
|
|
TPARGS(it));
|
2009-02-08 05:16:12 +08:00
|
|
|
|
|
|
|
#endif /* _TRACE_POWER_H */
|