diff options
Diffstat (limited to 'include/trace')
-rw-r--r-- | include/trace/events/asoc.h | 1 | ||||
-rw-r--r-- | include/trace/events/f2fs.h | 51 | ||||
-rw-r--r-- | include/trace/events/kmem.h | 10 | ||||
-rw-r--r-- | include/trace/events/power_cpu_migrate.h | 67 | ||||
-rw-r--r-- | include/trace/events/spi.h | 156 | ||||
-rw-r--r-- | include/trace/events/writeback.h | 6 |
6 files changed, 282 insertions, 9 deletions
diff --git a/include/trace/events/asoc.h b/include/trace/events/asoc.h index 5fc2dcdd21cd..03996b2bb04f 100644 --- a/include/trace/events/asoc.h +++ b/include/trace/events/asoc.h | |||
@@ -14,6 +14,7 @@ struct snd_soc_codec; | |||
14 | struct snd_soc_platform; | 14 | struct snd_soc_platform; |
15 | struct snd_soc_card; | 15 | struct snd_soc_card; |
16 | struct snd_soc_dapm_widget; | 16 | struct snd_soc_dapm_widget; |
17 | struct snd_soc_dapm_path; | ||
17 | 18 | ||
18 | /* | 19 | /* |
19 | * Log register events | 20 | * Log register events |
diff --git a/include/trace/events/f2fs.h b/include/trace/events/f2fs.h index 52ae54828eda..e0dc355fa317 100644 --- a/include/trace/events/f2fs.h +++ b/include/trace/events/f2fs.h | |||
@@ -36,6 +36,11 @@ | |||
36 | { CURSEG_COLD_NODE, "Cold NODE" }, \ | 36 | { CURSEG_COLD_NODE, "Cold NODE" }, \ |
37 | { NO_CHECK_TYPE, "No TYPE" }) | 37 | { NO_CHECK_TYPE, "No TYPE" }) |
38 | 38 | ||
39 | #define show_file_type(type) \ | ||
40 | __print_symbolic(type, \ | ||
41 | { 0, "FILE" }, \ | ||
42 | { 1, "DIR" }) | ||
43 | |||
39 | #define show_gc_type(type) \ | 44 | #define show_gc_type(type) \ |
40 | __print_symbolic(type, \ | 45 | __print_symbolic(type, \ |
41 | { FG_GC, "Foreground GC" }, \ | 46 | { FG_GC, "Foreground GC" }, \ |
@@ -623,6 +628,52 @@ TRACE_EVENT(f2fs_do_submit_bio, | |||
623 | __entry->size) | 628 | __entry->size) |
624 | ); | 629 | ); |
625 | 630 | ||
631 | DECLARE_EVENT_CLASS(f2fs__page, | ||
632 | |||
633 | TP_PROTO(struct page *page, int type), | ||
634 | |||
635 | TP_ARGS(page, type), | ||
636 | |||
637 | TP_STRUCT__entry( | ||
638 | __field(dev_t, dev) | ||
639 | __field(ino_t, ino) | ||
640 | __field(int, type) | ||
641 | __field(int, dir) | ||
642 | __field(pgoff_t, index) | ||
643 | __field(int, dirty) | ||
644 | ), | ||
645 | |||
646 | TP_fast_assign( | ||
647 | __entry->dev = page->mapping->host->i_sb->s_dev; | ||
648 | __entry->ino = page->mapping->host->i_ino; | ||
649 | __entry->type = type; | ||
650 | __entry->dir = S_ISDIR(page->mapping->host->i_mode); | ||
651 | __entry->index = page->index; | ||
652 | __entry->dirty = PageDirty(page); | ||
653 | ), | ||
654 | |||
655 | TP_printk("dev = (%d,%d), ino = %lu, %s, %s, index = %lu, dirty = %d", | ||
656 | show_dev_ino(__entry), | ||
657 | show_block_type(__entry->type), | ||
658 | show_file_type(__entry->dir), | ||
659 | (unsigned long)__entry->index, | ||
660 | __entry->dirty) | ||
661 | ); | ||
662 | |||
663 | DEFINE_EVENT(f2fs__page, f2fs_set_page_dirty, | ||
664 | |||
665 | TP_PROTO(struct page *page, int type), | ||
666 | |||
667 | TP_ARGS(page, type) | ||
668 | ); | ||
669 | |||
670 | DEFINE_EVENT(f2fs__page, f2fs_vm_page_mkwrite, | ||
671 | |||
672 | TP_PROTO(struct page *page, int type), | ||
673 | |||
674 | TP_ARGS(page, type) | ||
675 | ); | ||
676 | |||
626 | TRACE_EVENT(f2fs_submit_write_page, | 677 | TRACE_EVENT(f2fs_submit_write_page, |
627 | 678 | ||
628 | TP_PROTO(struct page *page, block_t blk_addr, int type), | 679 | TP_PROTO(struct page *page, block_t blk_addr, int type), |
diff --git a/include/trace/events/kmem.h b/include/trace/events/kmem.h index d0c613476620..aece1346ceb7 100644 --- a/include/trace/events/kmem.h +++ b/include/trace/events/kmem.h | |||
@@ -267,14 +267,12 @@ DEFINE_EVENT_PRINT(mm_page, mm_page_pcpu_drain, | |||
267 | TRACE_EVENT(mm_page_alloc_extfrag, | 267 | TRACE_EVENT(mm_page_alloc_extfrag, |
268 | 268 | ||
269 | TP_PROTO(struct page *page, | 269 | TP_PROTO(struct page *page, |
270 | int alloc_order, int fallback_order, | 270 | int alloc_order, int fallback_order, |
271 | int alloc_migratetype, int fallback_migratetype, | 271 | int alloc_migratetype, int fallback_migratetype, int new_migratetype), |
272 | int change_ownership), | ||
273 | 272 | ||
274 | TP_ARGS(page, | 273 | TP_ARGS(page, |
275 | alloc_order, fallback_order, | 274 | alloc_order, fallback_order, |
276 | alloc_migratetype, fallback_migratetype, | 275 | alloc_migratetype, fallback_migratetype, new_migratetype), |
277 | change_ownership), | ||
278 | 276 | ||
279 | TP_STRUCT__entry( | 277 | TP_STRUCT__entry( |
280 | __field( struct page *, page ) | 278 | __field( struct page *, page ) |
@@ -291,7 +289,7 @@ TRACE_EVENT(mm_page_alloc_extfrag, | |||
291 | __entry->fallback_order = fallback_order; | 289 | __entry->fallback_order = fallback_order; |
292 | __entry->alloc_migratetype = alloc_migratetype; | 290 | __entry->alloc_migratetype = alloc_migratetype; |
293 | __entry->fallback_migratetype = fallback_migratetype; | 291 | __entry->fallback_migratetype = fallback_migratetype; |
294 | __entry->change_ownership = change_ownership; | 292 | __entry->change_ownership = (new_migratetype == alloc_migratetype); |
295 | ), | 293 | ), |
296 | 294 | ||
297 | TP_printk("page=%p pfn=%lu alloc_order=%d fallback_order=%d pageblock_order=%d alloc_migratetype=%d fallback_migratetype=%d fragmenting=%d change_ownership=%d", | 295 | TP_printk("page=%p pfn=%lu alloc_order=%d fallback_order=%d pageblock_order=%d alloc_migratetype=%d fallback_migratetype=%d fragmenting=%d change_ownership=%d", |
diff --git a/include/trace/events/power_cpu_migrate.h b/include/trace/events/power_cpu_migrate.h new file mode 100644 index 000000000000..f76dd4de625e --- /dev/null +++ b/include/trace/events/power_cpu_migrate.h | |||
@@ -0,0 +1,67 @@ | |||
1 | #undef TRACE_SYSTEM | ||
2 | #define TRACE_SYSTEM power | ||
3 | |||
4 | #if !defined(_TRACE_POWER_CPU_MIGRATE_H) || defined(TRACE_HEADER_MULTI_READ) | ||
5 | #define _TRACE_POWER_CPU_MIGRATE_H | ||
6 | |||
7 | #include <linux/tracepoint.h> | ||
8 | |||
9 | #define __cpu_migrate_proto \ | ||
10 | TP_PROTO(u64 timestamp, \ | ||
11 | u32 cpu_hwid) | ||
12 | #define __cpu_migrate_args \ | ||
13 | TP_ARGS(timestamp, \ | ||
14 | cpu_hwid) | ||
15 | |||
16 | DECLARE_EVENT_CLASS(cpu_migrate, | ||
17 | |||
18 | __cpu_migrate_proto, | ||
19 | __cpu_migrate_args, | ||
20 | |||
21 | TP_STRUCT__entry( | ||
22 | __field(u64, timestamp ) | ||
23 | __field(u32, cpu_hwid ) | ||
24 | ), | ||
25 | |||
26 | TP_fast_assign( | ||
27 | __entry->timestamp = timestamp; | ||
28 | __entry->cpu_hwid = cpu_hwid; | ||
29 | ), | ||
30 | |||
31 | TP_printk("timestamp=%llu cpu_hwid=0x%08lX", | ||
32 | (unsigned long long)__entry->timestamp, | ||
33 | (unsigned long)__entry->cpu_hwid | ||
34 | ) | ||
35 | ); | ||
36 | |||
37 | #define __define_cpu_migrate_event(name) \ | ||
38 | DEFINE_EVENT(cpu_migrate, cpu_migrate_##name, \ | ||
39 | __cpu_migrate_proto, \ | ||
40 | __cpu_migrate_args \ | ||
41 | ) | ||
42 | |||
43 | __define_cpu_migrate_event(begin); | ||
44 | __define_cpu_migrate_event(finish); | ||
45 | __define_cpu_migrate_event(current); | ||
46 | |||
47 | #undef __define_cpu_migrate | ||
48 | #undef __cpu_migrate_proto | ||
49 | #undef __cpu_migrate_args | ||
50 | |||
51 | /* This file can get included multiple times, TRACE_HEADER_MULTI_READ at top */ | ||
52 | #ifndef _PWR_CPU_MIGRATE_EVENT_AVOID_DOUBLE_DEFINING | ||
53 | #define _PWR_CPU_MIGRATE_EVENT_AVOID_DOUBLE_DEFINING | ||
54 | |||
55 | /* | ||
56 | * Set from_phys_cpu and to_phys_cpu to CPU_MIGRATE_ALL_CPUS to indicate | ||
57 | * a whole-cluster migration: | ||
58 | */ | ||
59 | #define CPU_MIGRATE_ALL_CPUS 0x80000000U | ||
60 | #endif | ||
61 | |||
62 | #endif /* _TRACE_POWER_CPU_MIGRATE_H */ | ||
63 | |||
64 | /* This part must be outside protection */ | ||
65 | #undef TRACE_INCLUDE_FILE | ||
66 | #define TRACE_INCLUDE_FILE power_cpu_migrate | ||
67 | #include <trace/define_trace.h> | ||
diff --git a/include/trace/events/spi.h b/include/trace/events/spi.h new file mode 100644 index 000000000000..7e02c983bbe2 --- /dev/null +++ b/include/trace/events/spi.h | |||
@@ -0,0 +1,156 @@ | |||
1 | #undef TRACE_SYSTEM | ||
2 | #define TRACE_SYSTEM spi | ||
3 | |||
4 | #if !defined(_TRACE_SPI_H) || defined(TRACE_HEADER_MULTI_READ) | ||
5 | #define _TRACE_SPI_H | ||
6 | |||
7 | #include <linux/ktime.h> | ||
8 | #include <linux/tracepoint.h> | ||
9 | |||
10 | DECLARE_EVENT_CLASS(spi_master, | ||
11 | |||
12 | TP_PROTO(struct spi_master *master), | ||
13 | |||
14 | TP_ARGS(master), | ||
15 | |||
16 | TP_STRUCT__entry( | ||
17 | __field( int, bus_num ) | ||
18 | ), | ||
19 | |||
20 | TP_fast_assign( | ||
21 | __entry->bus_num = master->bus_num; | ||
22 | ), | ||
23 | |||
24 | TP_printk("spi%d", (int)__entry->bus_num) | ||
25 | |||
26 | ); | ||
27 | |||
28 | DEFINE_EVENT(spi_master, spi_master_idle, | ||
29 | |||
30 | TP_PROTO(struct spi_master *master), | ||
31 | |||
32 | TP_ARGS(master) | ||
33 | |||
34 | ); | ||
35 | |||
36 | DEFINE_EVENT(spi_master, spi_master_busy, | ||
37 | |||
38 | TP_PROTO(struct spi_master *master), | ||
39 | |||
40 | TP_ARGS(master) | ||
41 | |||
42 | ); | ||
43 | |||
44 | DECLARE_EVENT_CLASS(spi_message, | ||
45 | |||
46 | TP_PROTO(struct spi_message *msg), | ||
47 | |||
48 | TP_ARGS(msg), | ||
49 | |||
50 | TP_STRUCT__entry( | ||
51 | __field( int, bus_num ) | ||
52 | __field( int, chip_select ) | ||
53 | __field( struct spi_message *, msg ) | ||
54 | ), | ||
55 | |||
56 | TP_fast_assign( | ||
57 | __entry->bus_num = msg->spi->master->bus_num; | ||
58 | __entry->chip_select = msg->spi->chip_select; | ||
59 | __entry->msg = msg; | ||
60 | ), | ||
61 | |||
62 | TP_printk("spi%d.%d %p", (int)__entry->bus_num, | ||
63 | (int)__entry->chip_select, | ||
64 | (struct spi_message *)__entry->msg) | ||
65 | ); | ||
66 | |||
67 | DEFINE_EVENT(spi_message, spi_message_submit, | ||
68 | |||
69 | TP_PROTO(struct spi_message *msg), | ||
70 | |||
71 | TP_ARGS(msg) | ||
72 | |||
73 | ); | ||
74 | |||
75 | DEFINE_EVENT(spi_message, spi_message_start, | ||
76 | |||
77 | TP_PROTO(struct spi_message *msg), | ||
78 | |||
79 | TP_ARGS(msg) | ||
80 | |||
81 | ); | ||
82 | |||
83 | TRACE_EVENT(spi_message_done, | ||
84 | |||
85 | TP_PROTO(struct spi_message *msg), | ||
86 | |||
87 | TP_ARGS(msg), | ||
88 | |||
89 | TP_STRUCT__entry( | ||
90 | __field( int, bus_num ) | ||
91 | __field( int, chip_select ) | ||
92 | __field( struct spi_message *, msg ) | ||
93 | __field( unsigned, frame ) | ||
94 | __field( unsigned, actual ) | ||
95 | ), | ||
96 | |||
97 | TP_fast_assign( | ||
98 | __entry->bus_num = msg->spi->master->bus_num; | ||
99 | __entry->chip_select = msg->spi->chip_select; | ||
100 | __entry->msg = msg; | ||
101 | __entry->frame = msg->frame_length; | ||
102 | __entry->actual = msg->actual_length; | ||
103 | ), | ||
104 | |||
105 | TP_printk("spi%d.%d %p len=%u/%u", (int)__entry->bus_num, | ||
106 | (int)__entry->chip_select, | ||
107 | (struct spi_message *)__entry->msg, | ||
108 | (unsigned)__entry->actual, (unsigned)__entry->frame) | ||
109 | ); | ||
110 | |||
111 | DECLARE_EVENT_CLASS(spi_transfer, | ||
112 | |||
113 | TP_PROTO(struct spi_message *msg, struct spi_transfer *xfer), | ||
114 | |||
115 | TP_ARGS(msg, xfer), | ||
116 | |||
117 | TP_STRUCT__entry( | ||
118 | __field( int, bus_num ) | ||
119 | __field( int, chip_select ) | ||
120 | __field( struct spi_transfer *, xfer ) | ||
121 | __field( int, len ) | ||
122 | ), | ||
123 | |||
124 | TP_fast_assign( | ||
125 | __entry->bus_num = msg->spi->master->bus_num; | ||
126 | __entry->chip_select = msg->spi->chip_select; | ||
127 | __entry->xfer = xfer; | ||
128 | __entry->len = xfer->len; | ||
129 | ), | ||
130 | |||
131 | TP_printk("spi%d.%d %p len=%d", (int)__entry->bus_num, | ||
132 | (int)__entry->chip_select, | ||
133 | (struct spi_message *)__entry->xfer, | ||
134 | (int)__entry->len) | ||
135 | ); | ||
136 | |||
137 | DEFINE_EVENT(spi_transfer, spi_transfer_start, | ||
138 | |||
139 | TP_PROTO(struct spi_message *msg, struct spi_transfer *xfer), | ||
140 | |||
141 | TP_ARGS(msg, xfer) | ||
142 | |||
143 | ); | ||
144 | |||
145 | DEFINE_EVENT(spi_transfer, spi_transfer_stop, | ||
146 | |||
147 | TP_PROTO(struct spi_message *msg, struct spi_transfer *xfer), | ||
148 | |||
149 | TP_ARGS(msg, xfer) | ||
150 | |||
151 | ); | ||
152 | |||
153 | #endif /* _TRACE_POWER_H */ | ||
154 | |||
155 | /* This part must be outside protection */ | ||
156 | #include <trace/define_trace.h> | ||
diff --git a/include/trace/events/writeback.h b/include/trace/events/writeback.h index 464ea82e10db..c7bbbe794e65 100644 --- a/include/trace/events/writeback.h +++ b/include/trace/events/writeback.h | |||
@@ -287,11 +287,11 @@ TRACE_EVENT(writeback_queue_io, | |||
287 | __field(int, reason) | 287 | __field(int, reason) |
288 | ), | 288 | ), |
289 | TP_fast_assign( | 289 | TP_fast_assign( |
290 | unsigned long *older_than_this = work->older_than_this; | 290 | unsigned long older_than_this = work->older_than_this; |
291 | strncpy(__entry->name, dev_name(wb->bdi->dev), 32); | 291 | strncpy(__entry->name, dev_name(wb->bdi->dev), 32); |
292 | __entry->older = older_than_this ? *older_than_this : 0; | 292 | __entry->older = older_than_this; |
293 | __entry->age = older_than_this ? | 293 | __entry->age = older_than_this ? |
294 | (jiffies - *older_than_this) * 1000 / HZ : -1; | 294 | (jiffies - older_than_this) * 1000 / HZ : -1; |
295 | __entry->moved = moved; | 295 | __entry->moved = moved; |
296 | __entry->reason = work->reason; | 296 | __entry->reason = work->reason; |
297 | ), | 297 | ), |