blob: 6797b9de90edeac929c5c234558434cc16d1d877 [file] [log] [blame]
Lukas Czerner785c4bc2011-05-23 18:33:01 +02001#undef TRACE_SYSTEM
2#define TRACE_SYSTEM ext3
3
4#if !defined(_TRACE_EXT3_H) || defined(TRACE_HEADER_MULTI_READ)
5#define _TRACE_EXT3_H
6
7#include <linux/tracepoint.h>
8
9TRACE_EVENT(ext3_free_inode,
10 TP_PROTO(struct inode *inode),
11
12 TP_ARGS(inode),
13
14 TP_STRUCT__entry(
15 __field( dev_t, dev )
16 __field( ino_t, ino )
17 __field( umode_t, mode )
18 __field( uid_t, uid )
19 __field( gid_t, gid )
20 __field( blkcnt_t, blocks )
21 ),
22
23 TP_fast_assign(
24 __entry->dev = inode->i_sb->s_dev;
25 __entry->ino = inode->i_ino;
26 __entry->mode = inode->i_mode;
Eric W. Biederman15232992012-02-07 15:41:24 -080027 __entry->uid = i_uid_read(inode);
28 __entry->gid = i_gid_read(inode);
Lukas Czerner785c4bc2011-05-23 18:33:01 +020029 __entry->blocks = inode->i_blocks;
30 ),
31
32 TP_printk("dev %d,%d ino %lu mode 0%o uid %u gid %u blocks %lu",
33 MAJOR(__entry->dev), MINOR(__entry->dev),
34 (unsigned long) __entry->ino,
35 __entry->mode, __entry->uid, __entry->gid,
36 (unsigned long) __entry->blocks)
37);
38
39TRACE_EVENT(ext3_request_inode,
40 TP_PROTO(struct inode *dir, int mode),
41
42 TP_ARGS(dir, mode),
43
44 TP_STRUCT__entry(
45 __field( dev_t, dev )
46 __field( ino_t, dir )
47 __field( umode_t, mode )
48 ),
49
50 TP_fast_assign(
51 __entry->dev = dir->i_sb->s_dev;
52 __entry->dir = dir->i_ino;
53 __entry->mode = mode;
54 ),
55
56 TP_printk("dev %d,%d dir %lu mode 0%o",
57 MAJOR(__entry->dev), MINOR(__entry->dev),
58 (unsigned long) __entry->dir, __entry->mode)
59);
60
61TRACE_EVENT(ext3_allocate_inode,
62 TP_PROTO(struct inode *inode, struct inode *dir, int mode),
63
64 TP_ARGS(inode, dir, mode),
65
66 TP_STRUCT__entry(
67 __field( dev_t, dev )
68 __field( ino_t, ino )
69 __field( ino_t, dir )
70 __field( umode_t, mode )
71 ),
72
73 TP_fast_assign(
74 __entry->dev = inode->i_sb->s_dev;
75 __entry->ino = inode->i_ino;
76 __entry->dir = dir->i_ino;
77 __entry->mode = mode;
78 ),
79
80 TP_printk("dev %d,%d ino %lu dir %lu mode 0%o",
81 MAJOR(__entry->dev), MINOR(__entry->dev),
82 (unsigned long) __entry->ino,
83 (unsigned long) __entry->dir, __entry->mode)
84);
85
86TRACE_EVENT(ext3_evict_inode,
87 TP_PROTO(struct inode *inode),
88
89 TP_ARGS(inode),
90
91 TP_STRUCT__entry(
92 __field( dev_t, dev )
93 __field( ino_t, ino )
94 __field( int, nlink )
95 ),
96
97 TP_fast_assign(
98 __entry->dev = inode->i_sb->s_dev;
99 __entry->ino = inode->i_ino;
100 __entry->nlink = inode->i_nlink;
101 ),
102
103 TP_printk("dev %d,%d ino %lu nlink %d",
104 MAJOR(__entry->dev), MINOR(__entry->dev),
105 (unsigned long) __entry->ino, __entry->nlink)
106);
107
108TRACE_EVENT(ext3_drop_inode,
109 TP_PROTO(struct inode *inode, int drop),
110
111 TP_ARGS(inode, drop),
112
113 TP_STRUCT__entry(
114 __field( dev_t, dev )
115 __field( ino_t, ino )
116 __field( int, drop )
117 ),
118
119 TP_fast_assign(
120 __entry->dev = inode->i_sb->s_dev;
121 __entry->ino = inode->i_ino;
122 __entry->drop = drop;
123 ),
124
125 TP_printk("dev %d,%d ino %lu drop %d",
126 MAJOR(__entry->dev), MINOR(__entry->dev),
127 (unsigned long) __entry->ino, __entry->drop)
128);
129
130TRACE_EVENT(ext3_mark_inode_dirty,
131 TP_PROTO(struct inode *inode, unsigned long IP),
132
133 TP_ARGS(inode, IP),
134
135 TP_STRUCT__entry(
136 __field( dev_t, dev )
137 __field( ino_t, ino )
138 __field(unsigned long, ip )
139 ),
140
141 TP_fast_assign(
142 __entry->dev = inode->i_sb->s_dev;
143 __entry->ino = inode->i_ino;
144 __entry->ip = IP;
145 ),
146
147 TP_printk("dev %d,%d ino %lu caller %pF",
148 MAJOR(__entry->dev), MINOR(__entry->dev),
149 (unsigned long) __entry->ino, (void *)__entry->ip)
150);
151
152TRACE_EVENT(ext3_write_begin,
153 TP_PROTO(struct inode *inode, loff_t pos, unsigned int len,
154 unsigned int flags),
155
156 TP_ARGS(inode, pos, len, flags),
157
158 TP_STRUCT__entry(
159 __field( dev_t, dev )
160 __field( ino_t, ino )
161 __field( loff_t, pos )
162 __field( unsigned int, len )
163 __field( unsigned int, flags )
164 ),
165
166 TP_fast_assign(
167 __entry->dev = inode->i_sb->s_dev;
168 __entry->ino = inode->i_ino;
169 __entry->pos = pos;
170 __entry->len = len;
171 __entry->flags = flags;
172 ),
173
174 TP_printk("dev %d,%d ino %lu pos %llu len %u flags %u",
175 MAJOR(__entry->dev), MINOR(__entry->dev),
176 (unsigned long) __entry->ino,
177 (unsigned long long) __entry->pos, __entry->len,
178 __entry->flags)
179);
180
181DECLARE_EVENT_CLASS(ext3__write_end,
182 TP_PROTO(struct inode *inode, loff_t pos, unsigned int len,
183 unsigned int copied),
184
185 TP_ARGS(inode, pos, len, copied),
186
187 TP_STRUCT__entry(
188 __field( dev_t, dev )
189 __field( ino_t, ino )
190 __field( loff_t, pos )
191 __field( unsigned int, len )
192 __field( unsigned int, copied )
193 ),
194
195 TP_fast_assign(
196 __entry->dev = inode->i_sb->s_dev;
197 __entry->ino = inode->i_ino;
198 __entry->pos = pos;
199 __entry->len = len;
200 __entry->copied = copied;
201 ),
202
203 TP_printk("dev %d,%d ino %lu pos %llu len %u copied %u",
204 MAJOR(__entry->dev), MINOR(__entry->dev),
205 (unsigned long) __entry->ino,
206 (unsigned long long) __entry->pos, __entry->len,
207 __entry->copied)
208);
209
210DEFINE_EVENT(ext3__write_end, ext3_ordered_write_end,
211
212 TP_PROTO(struct inode *inode, loff_t pos, unsigned int len,
213 unsigned int copied),
214
215 TP_ARGS(inode, pos, len, copied)
216);
217
218DEFINE_EVENT(ext3__write_end, ext3_writeback_write_end,
219
220 TP_PROTO(struct inode *inode, loff_t pos, unsigned int len,
221 unsigned int copied),
222
223 TP_ARGS(inode, pos, len, copied)
224);
225
226DEFINE_EVENT(ext3__write_end, ext3_journalled_write_end,
227
228 TP_PROTO(struct inode *inode, loff_t pos, unsigned int len,
229 unsigned int copied),
230
231 TP_ARGS(inode, pos, len, copied)
232);
233
234DECLARE_EVENT_CLASS(ext3__page_op,
235 TP_PROTO(struct page *page),
236
237 TP_ARGS(page),
238
239 TP_STRUCT__entry(
240 __field( dev_t, dev )
241 __field( ino_t, ino )
242 __field( pgoff_t, index )
243
244 ),
245
246 TP_fast_assign(
247 __entry->index = page->index;
248 __entry->ino = page->mapping->host->i_ino;
249 __entry->dev = page->mapping->host->i_sb->s_dev;
250 ),
251
252 TP_printk("dev %d,%d ino %lu page_index %lu",
253 MAJOR(__entry->dev), MINOR(__entry->dev),
254 (unsigned long) __entry->ino, __entry->index)
255);
256
257DEFINE_EVENT(ext3__page_op, ext3_ordered_writepage,
258
259 TP_PROTO(struct page *page),
260
261 TP_ARGS(page)
262);
263
264DEFINE_EVENT(ext3__page_op, ext3_writeback_writepage,
265
266 TP_PROTO(struct page *page),
267
268 TP_ARGS(page)
269);
270
271DEFINE_EVENT(ext3__page_op, ext3_journalled_writepage,
272
273 TP_PROTO(struct page *page),
274
275 TP_ARGS(page)
276);
277
278DEFINE_EVENT(ext3__page_op, ext3_readpage,
279
280 TP_PROTO(struct page *page),
281
282 TP_ARGS(page)
283);
284
285DEFINE_EVENT(ext3__page_op, ext3_releasepage,
286
287 TP_PROTO(struct page *page),
288
289 TP_ARGS(page)
290);
291
292TRACE_EVENT(ext3_invalidatepage,
Lukas Czernerd8c89002013-05-21 23:26:36 -0400293 TP_PROTO(struct page *page, unsigned int offset, unsigned int length),
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200294
Lukas Czernerd8c89002013-05-21 23:26:36 -0400295 TP_ARGS(page, offset, length),
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200296
297 TP_STRUCT__entry(
298 __field( pgoff_t, index )
Lukas Czernerd8c89002013-05-21 23:26:36 -0400299 __field( unsigned int, offset )
300 __field( unsigned int, length )
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200301 __field( ino_t, ino )
302 __field( dev_t, dev )
303
304 ),
305
306 TP_fast_assign(
307 __entry->index = page->index;
308 __entry->offset = offset;
Lukas Czernerd8c89002013-05-21 23:26:36 -0400309 __entry->length = length;
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200310 __entry->ino = page->mapping->host->i_ino;
311 __entry->dev = page->mapping->host->i_sb->s_dev;
312 ),
313
Lukas Czernerd8c89002013-05-21 23:26:36 -0400314 TP_printk("dev %d,%d ino %lu page_index %lu offset %u length %u",
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200315 MAJOR(__entry->dev), MINOR(__entry->dev),
316 (unsigned long) __entry->ino,
Lukas Czernerd8c89002013-05-21 23:26:36 -0400317 __entry->index, __entry->offset, __entry->length)
Lukas Czerner785c4bc2011-05-23 18:33:01 +0200318);
319
320TRACE_EVENT(ext3_discard_blocks,
321 TP_PROTO(struct super_block *sb, unsigned long blk,
322 unsigned long count),
323
324 TP_ARGS(sb, blk, count),
325
326 TP_STRUCT__entry(
327 __field( dev_t, dev )
328 __field( unsigned long, blk )
329 __field( unsigned long, count )
330
331 ),
332
333 TP_fast_assign(
334 __entry->dev = sb->s_dev;
335 __entry->blk = blk;
336 __entry->count = count;
337 ),
338
339 TP_printk("dev %d,%d blk %lu count %lu",
340 MAJOR(__entry->dev), MINOR(__entry->dev),
341 __entry->blk, __entry->count)
342);
343
344TRACE_EVENT(ext3_request_blocks,
345 TP_PROTO(struct inode *inode, unsigned long goal,
346 unsigned long count),
347
348 TP_ARGS(inode, goal, count),
349
350 TP_STRUCT__entry(
351 __field( dev_t, dev )
352 __field( ino_t, ino )
353 __field( unsigned long, count )
354 __field( unsigned long, goal )
355 ),
356
357 TP_fast_assign(
358 __entry->dev = inode->i_sb->s_dev;
359 __entry->ino = inode->i_ino;
360 __entry->count = count;
361 __entry->goal = goal;
362 ),
363
364 TP_printk("dev %d,%d ino %lu count %lu goal %lu ",
365 MAJOR(__entry->dev), MINOR(__entry->dev),
366 (unsigned long) __entry->ino,
367 __entry->count, __entry->goal)
368);
369
370TRACE_EVENT(ext3_allocate_blocks,
371 TP_PROTO(struct inode *inode, unsigned long goal,
372 unsigned long count, unsigned long block),
373
374 TP_ARGS(inode, goal, count, block),
375
376 TP_STRUCT__entry(
377 __field( dev_t, dev )
378 __field( ino_t, ino )
379 __field( unsigned long, block )
380 __field( unsigned long, count )
381 __field( unsigned long, goal )
382 ),
383
384 TP_fast_assign(
385 __entry->dev = inode->i_sb->s_dev;
386 __entry->ino = inode->i_ino;
387 __entry->block = block;
388 __entry->count = count;
389 __entry->goal = goal;
390 ),
391
392 TP_printk("dev %d,%d ino %lu count %lu block %lu goal %lu",
393 MAJOR(__entry->dev), MINOR(__entry->dev),
394 (unsigned long) __entry->ino,
395 __entry->count, __entry->block,
396 __entry->goal)
397);
398
399TRACE_EVENT(ext3_free_blocks,
400 TP_PROTO(struct inode *inode, unsigned long block,
401 unsigned long count),
402
403 TP_ARGS(inode, block, count),
404
405 TP_STRUCT__entry(
406 __field( dev_t, dev )
407 __field( ino_t, ino )
408 __field( umode_t, mode )
409 __field( unsigned long, block )
410 __field( unsigned long, count )
411 ),
412
413 TP_fast_assign(
414 __entry->dev = inode->i_sb->s_dev;
415 __entry->ino = inode->i_ino;
416 __entry->mode = inode->i_mode;
417 __entry->block = block;
418 __entry->count = count;
419 ),
420
421 TP_printk("dev %d,%d ino %lu mode 0%o block %lu count %lu",
422 MAJOR(__entry->dev), MINOR(__entry->dev),
423 (unsigned long) __entry->ino,
424 __entry->mode, __entry->block, __entry->count)
425);
426
427TRACE_EVENT(ext3_sync_file_enter,
428 TP_PROTO(struct file *file, int datasync),
429
430 TP_ARGS(file, datasync),
431
432 TP_STRUCT__entry(
433 __field( dev_t, dev )
434 __field( ino_t, ino )
435 __field( ino_t, parent )
436 __field( int, datasync )
437 ),
438
439 TP_fast_assign(
440 struct dentry *dentry = file->f_path.dentry;
441
442 __entry->dev = dentry->d_inode->i_sb->s_dev;
443 __entry->ino = dentry->d_inode->i_ino;
444 __entry->datasync = datasync;
445 __entry->parent = dentry->d_parent->d_inode->i_ino;
446 ),
447
448 TP_printk("dev %d,%d ino %lu parent %ld datasync %d ",
449 MAJOR(__entry->dev), MINOR(__entry->dev),
450 (unsigned long) __entry->ino,
451 (unsigned long) __entry->parent, __entry->datasync)
452);
453
454TRACE_EVENT(ext3_sync_file_exit,
455 TP_PROTO(struct inode *inode, int ret),
456
457 TP_ARGS(inode, ret),
458
459 TP_STRUCT__entry(
460 __field( int, ret )
461 __field( ino_t, ino )
462 __field( dev_t, dev )
463 ),
464
465 TP_fast_assign(
466 __entry->ret = ret;
467 __entry->ino = inode->i_ino;
468 __entry->dev = inode->i_sb->s_dev;
469 ),
470
471 TP_printk("dev %d,%d ino %lu ret %d",
472 MAJOR(__entry->dev), MINOR(__entry->dev),
473 (unsigned long) __entry->ino,
474 __entry->ret)
475);
476
477TRACE_EVENT(ext3_sync_fs,
478 TP_PROTO(struct super_block *sb, int wait),
479
480 TP_ARGS(sb, wait),
481
482 TP_STRUCT__entry(
483 __field( dev_t, dev )
484 __field( int, wait )
485
486 ),
487
488 TP_fast_assign(
489 __entry->dev = sb->s_dev;
490 __entry->wait = wait;
491 ),
492
493 TP_printk("dev %d,%d wait %d",
494 MAJOR(__entry->dev), MINOR(__entry->dev),
495 __entry->wait)
496);
497
498TRACE_EVENT(ext3_rsv_window_add,
499 TP_PROTO(struct super_block *sb,
500 struct ext3_reserve_window_node *rsv_node),
501
502 TP_ARGS(sb, rsv_node),
503
504 TP_STRUCT__entry(
505 __field( unsigned long, start )
506 __field( unsigned long, end )
507 __field( dev_t, dev )
508 ),
509
510 TP_fast_assign(
511 __entry->dev = sb->s_dev;
512 __entry->start = rsv_node->rsv_window._rsv_start;
513 __entry->end = rsv_node->rsv_window._rsv_end;
514 ),
515
516 TP_printk("dev %d,%d start %lu end %lu",
517 MAJOR(__entry->dev), MINOR(__entry->dev),
518 __entry->start, __entry->end)
519);
520
521TRACE_EVENT(ext3_discard_reservation,
522 TP_PROTO(struct inode *inode,
523 struct ext3_reserve_window_node *rsv_node),
524
525 TP_ARGS(inode, rsv_node),
526
527 TP_STRUCT__entry(
528 __field( unsigned long, start )
529 __field( unsigned long, end )
530 __field( ino_t, ino )
531 __field( dev_t, dev )
532 ),
533
534 TP_fast_assign(
535 __entry->start = rsv_node->rsv_window._rsv_start;
536 __entry->end = rsv_node->rsv_window._rsv_end;
537 __entry->ino = inode->i_ino;
538 __entry->dev = inode->i_sb->s_dev;
539 ),
540
541 TP_printk("dev %d,%d ino %lu start %lu end %lu",
542 MAJOR(__entry->dev), MINOR(__entry->dev),
543 (unsigned long)__entry->ino, __entry->start,
544 __entry->end)
545);
546
547TRACE_EVENT(ext3_alloc_new_reservation,
548 TP_PROTO(struct super_block *sb, unsigned long goal),
549
550 TP_ARGS(sb, goal),
551
552 TP_STRUCT__entry(
553 __field( dev_t, dev )
554 __field( unsigned long, goal )
555 ),
556
557 TP_fast_assign(
558 __entry->dev = sb->s_dev;
559 __entry->goal = goal;
560 ),
561
562 TP_printk("dev %d,%d goal %lu",
563 MAJOR(__entry->dev), MINOR(__entry->dev),
564 __entry->goal)
565);
566
567TRACE_EVENT(ext3_reserved,
568 TP_PROTO(struct super_block *sb, unsigned long block,
569 struct ext3_reserve_window_node *rsv_node),
570
571 TP_ARGS(sb, block, rsv_node),
572
573 TP_STRUCT__entry(
574 __field( unsigned long, block )
575 __field( unsigned long, start )
576 __field( unsigned long, end )
577 __field( dev_t, dev )
578 ),
579
580 TP_fast_assign(
581 __entry->block = block;
582 __entry->start = rsv_node->rsv_window._rsv_start;
583 __entry->end = rsv_node->rsv_window._rsv_end;
584 __entry->dev = sb->s_dev;
585 ),
586
587 TP_printk("dev %d,%d block %lu, start %lu end %lu",
588 MAJOR(__entry->dev), MINOR(__entry->dev),
589 __entry->block, __entry->start, __entry->end)
590);
591
592TRACE_EVENT(ext3_forget,
593 TP_PROTO(struct inode *inode, int is_metadata, unsigned long block),
594
595 TP_ARGS(inode, is_metadata, block),
596
597 TP_STRUCT__entry(
598 __field( dev_t, dev )
599 __field( ino_t, ino )
600 __field( umode_t, mode )
601 __field( int, is_metadata )
602 __field( unsigned long, block )
603 ),
604
605 TP_fast_assign(
606 __entry->dev = inode->i_sb->s_dev;
607 __entry->ino = inode->i_ino;
608 __entry->mode = inode->i_mode;
609 __entry->is_metadata = is_metadata;
610 __entry->block = block;
611 ),
612
613 TP_printk("dev %d,%d ino %lu mode 0%o is_metadata %d block %lu",
614 MAJOR(__entry->dev), MINOR(__entry->dev),
615 (unsigned long) __entry->ino,
616 __entry->mode, __entry->is_metadata, __entry->block)
617);
618
619TRACE_EVENT(ext3_read_block_bitmap,
620 TP_PROTO(struct super_block *sb, unsigned int group),
621
622 TP_ARGS(sb, group),
623
624 TP_STRUCT__entry(
625 __field( dev_t, dev )
626 __field( __u32, group )
627
628 ),
629
630 TP_fast_assign(
631 __entry->dev = sb->s_dev;
632 __entry->group = group;
633 ),
634
635 TP_printk("dev %d,%d group %u",
636 MAJOR(__entry->dev), MINOR(__entry->dev),
637 __entry->group)
638);
639
640TRACE_EVENT(ext3_direct_IO_enter,
641 TP_PROTO(struct inode *inode, loff_t offset, unsigned long len, int rw),
642
643 TP_ARGS(inode, offset, len, rw),
644
645 TP_STRUCT__entry(
646 __field( ino_t, ino )
647 __field( dev_t, dev )
648 __field( loff_t, pos )
649 __field( unsigned long, len )
650 __field( int, rw )
651 ),
652
653 TP_fast_assign(
654 __entry->ino = inode->i_ino;
655 __entry->dev = inode->i_sb->s_dev;
656 __entry->pos = offset;
657 __entry->len = len;
658 __entry->rw = rw;
659 ),
660
661 TP_printk("dev %d,%d ino %lu pos %llu len %lu rw %d",
662 MAJOR(__entry->dev), MINOR(__entry->dev),
663 (unsigned long) __entry->ino,
664 (unsigned long long) __entry->pos, __entry->len,
665 __entry->rw)
666);
667
668TRACE_EVENT(ext3_direct_IO_exit,
669 TP_PROTO(struct inode *inode, loff_t offset, unsigned long len,
670 int rw, int ret),
671
672 TP_ARGS(inode, offset, len, rw, ret),
673
674 TP_STRUCT__entry(
675 __field( ino_t, ino )
676 __field( dev_t, dev )
677 __field( loff_t, pos )
678 __field( unsigned long, len )
679 __field( int, rw )
680 __field( int, ret )
681 ),
682
683 TP_fast_assign(
684 __entry->ino = inode->i_ino;
685 __entry->dev = inode->i_sb->s_dev;
686 __entry->pos = offset;
687 __entry->len = len;
688 __entry->rw = rw;
689 __entry->ret = ret;
690 ),
691
692 TP_printk("dev %d,%d ino %lu pos %llu len %lu rw %d ret %d",
693 MAJOR(__entry->dev), MINOR(__entry->dev),
694 (unsigned long) __entry->ino,
695 (unsigned long long) __entry->pos, __entry->len,
696 __entry->rw, __entry->ret)
697);
698
699TRACE_EVENT(ext3_unlink_enter,
700 TP_PROTO(struct inode *parent, struct dentry *dentry),
701
702 TP_ARGS(parent, dentry),
703
704 TP_STRUCT__entry(
705 __field( ino_t, parent )
706 __field( ino_t, ino )
707 __field( loff_t, size )
708 __field( dev_t, dev )
709 ),
710
711 TP_fast_assign(
712 __entry->parent = parent->i_ino;
713 __entry->ino = dentry->d_inode->i_ino;
714 __entry->size = dentry->d_inode->i_size;
715 __entry->dev = dentry->d_inode->i_sb->s_dev;
716 ),
717
718 TP_printk("dev %d,%d ino %lu size %lld parent %ld",
719 MAJOR(__entry->dev), MINOR(__entry->dev),
720 (unsigned long) __entry->ino,
721 (unsigned long long)__entry->size,
722 (unsigned long) __entry->parent)
723);
724
725TRACE_EVENT(ext3_unlink_exit,
726 TP_PROTO(struct dentry *dentry, int ret),
727
728 TP_ARGS(dentry, ret),
729
730 TP_STRUCT__entry(
731 __field( ino_t, ino )
732 __field( dev_t, dev )
733 __field( int, ret )
734 ),
735
736 TP_fast_assign(
737 __entry->ino = dentry->d_inode->i_ino;
738 __entry->dev = dentry->d_inode->i_sb->s_dev;
739 __entry->ret = ret;
740 ),
741
742 TP_printk("dev %d,%d ino %lu ret %d",
743 MAJOR(__entry->dev), MINOR(__entry->dev),
744 (unsigned long) __entry->ino,
745 __entry->ret)
746);
747
748DECLARE_EVENT_CLASS(ext3__truncate,
749 TP_PROTO(struct inode *inode),
750
751 TP_ARGS(inode),
752
753 TP_STRUCT__entry(
754 __field( ino_t, ino )
755 __field( dev_t, dev )
756 __field( blkcnt_t, blocks )
757 ),
758
759 TP_fast_assign(
760 __entry->ino = inode->i_ino;
761 __entry->dev = inode->i_sb->s_dev;
762 __entry->blocks = inode->i_blocks;
763 ),
764
765 TP_printk("dev %d,%d ino %lu blocks %lu",
766 MAJOR(__entry->dev), MINOR(__entry->dev),
767 (unsigned long) __entry->ino, (unsigned long) __entry->blocks)
768);
769
770DEFINE_EVENT(ext3__truncate, ext3_truncate_enter,
771
772 TP_PROTO(struct inode *inode),
773
774 TP_ARGS(inode)
775);
776
777DEFINE_EVENT(ext3__truncate, ext3_truncate_exit,
778
779 TP_PROTO(struct inode *inode),
780
781 TP_ARGS(inode)
782);
783
784TRACE_EVENT(ext3_get_blocks_enter,
785 TP_PROTO(struct inode *inode, unsigned long lblk,
786 unsigned long len, int create),
787
788 TP_ARGS(inode, lblk, len, create),
789
790 TP_STRUCT__entry(
791 __field( ino_t, ino )
792 __field( dev_t, dev )
793 __field( unsigned long, lblk )
794 __field( unsigned long, len )
795 __field( int, create )
796 ),
797
798 TP_fast_assign(
799 __entry->ino = inode->i_ino;
800 __entry->dev = inode->i_sb->s_dev;
801 __entry->lblk = lblk;
802 __entry->len = len;
803 __entry->create = create;
804 ),
805
806 TP_printk("dev %d,%d ino %lu lblk %lu len %lu create %u",
807 MAJOR(__entry->dev), MINOR(__entry->dev),
808 (unsigned long) __entry->ino,
809 __entry->lblk, __entry->len, __entry->create)
810);
811
812TRACE_EVENT(ext3_get_blocks_exit,
813 TP_PROTO(struct inode *inode, unsigned long lblk,
814 unsigned long pblk, unsigned long len, int ret),
815
816 TP_ARGS(inode, lblk, pblk, len, ret),
817
818 TP_STRUCT__entry(
819 __field( ino_t, ino )
820 __field( dev_t, dev )
821 __field( unsigned long, lblk )
822 __field( unsigned long, pblk )
823 __field( unsigned long, len )
824 __field( int, ret )
825 ),
826
827 TP_fast_assign(
828 __entry->ino = inode->i_ino;
829 __entry->dev = inode->i_sb->s_dev;
830 __entry->lblk = lblk;
831 __entry->pblk = pblk;
832 __entry->len = len;
833 __entry->ret = ret;
834 ),
835
836 TP_printk("dev %d,%d ino %lu lblk %lu pblk %lu len %lu ret %d",
837 MAJOR(__entry->dev), MINOR(__entry->dev),
838 (unsigned long) __entry->ino,
839 __entry->lblk, __entry->pblk,
840 __entry->len, __entry->ret)
841);
842
843TRACE_EVENT(ext3_load_inode,
844 TP_PROTO(struct inode *inode),
845
846 TP_ARGS(inode),
847
848 TP_STRUCT__entry(
849 __field( ino_t, ino )
850 __field( dev_t, dev )
851 ),
852
853 TP_fast_assign(
854 __entry->ino = inode->i_ino;
855 __entry->dev = inode->i_sb->s_dev;
856 ),
857
858 TP_printk("dev %d,%d ino %lu",
859 MAJOR(__entry->dev), MINOR(__entry->dev),
860 (unsigned long) __entry->ino)
861);
862
863#endif /* _TRACE_EXT3_H */
864
865/* This part must be outside protection */
866#include <trace/define_trace.h>