aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/resume-trace.h
diff options
context:
space:
mode:
authorSteven Whitehouse <swhiteho@redhat.com>2006-09-28 08:29:59 -0400
committerSteven Whitehouse <swhiteho@redhat.com>2006-09-28 08:29:59 -0400
commit185a257f2f73bcd89050ad02da5bedbc28fc43fa (patch)
tree5e32586114534ed3f2165614cba3d578f5d87307 /include/linux/resume-trace.h
parent3f1a9aaeffd8d1cbc5ab9776c45cbd66af1c9699 (diff)
parenta77c64c1a641950626181b4857abb701d8f38ccc (diff)
Merge branch 'master' into gfs2
Diffstat (limited to 'include/linux/resume-trace.h')
-rw-r--r--include/linux/resume-trace.h24
1 files changed, 14 insertions, 10 deletions
diff --git a/include/linux/resume-trace.h b/include/linux/resume-trace.h
index a376bd4ade39..81e9299ca148 100644
--- a/include/linux/resume-trace.h
+++ b/include/linux/resume-trace.h
@@ -3,21 +3,25 @@
3 3
4#ifdef CONFIG_PM_TRACE 4#ifdef CONFIG_PM_TRACE
5 5
6extern int pm_trace_enabled;
7
6struct device; 8struct device;
7extern void set_trace_device(struct device *); 9extern void set_trace_device(struct device *);
8extern void generate_resume_trace(void *tracedata, unsigned int user); 10extern void generate_resume_trace(void *tracedata, unsigned int user);
9 11
10#define TRACE_DEVICE(dev) set_trace_device(dev) 12#define TRACE_DEVICE(dev) set_trace_device(dev)
11#define TRACE_RESUME(user) do { \ 13#define TRACE_RESUME(user) do { \
12 void *tracedata; \ 14 if (pm_trace_enabled) { \
13 asm volatile("movl $1f,%0\n" \ 15 void *tracedata; \
14 ".section .tracedata,\"a\"\n" \ 16 asm volatile("movl $1f,%0\n" \
15 "1:\t.word %c1\n" \ 17 ".section .tracedata,\"a\"\n" \
16 "\t.long %c2\n" \ 18 "1:\t.word %c1\n" \
17 ".previous" \ 19 "\t.long %c2\n" \
18 :"=r" (tracedata) \ 20 ".previous" \
19 : "i" (__LINE__), "i" (__FILE__)); \ 21 :"=r" (tracedata) \
20 generate_resume_trace(tracedata, user); \ 22 : "i" (__LINE__), "i" (__FILE__)); \
23 generate_resume_trace(tracedata, user); \
24 } \
21} while (0) 25} while (0)
22 26
23#else 27#else