aboutsummaryrefslogtreecommitdiffstats
path: root/include/trace
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-04-04 18:39:39 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-04 18:39:39 -0400
commit24e7ea3bea94fe05eae5019f5f12bcdc98fc5157 (patch)
tree6e527053ad73b737b5450c52d14ddf53ad4ba9a2 /include/trace
parent8e343c8b5c2e3c93d9eebea7702c89d81753c495 (diff)
parentad6599ab3ac98a4474544086e048ce86ec15a4d1 (diff)
Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4
Pull ext4 updates from Ted Ts'o: "Major changes for 3.14 include support for the newly added ZERO_RANGE and COLLAPSE_RANGE fallocate operations, and scalability improvements in the jbd2 layer and in xattr handling when the extended attributes spill over into an external block. Other than that, the usual clean ups and minor bug fixes" * tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4: (42 commits) ext4: fix premature freeing of partial clusters split across leaf blocks ext4: remove unneeded test of ret variable ext4: fix comment typo ext4: make ext4_block_zero_page_range static ext4: atomically set inode->i_flags in ext4_set_inode_flags() ext4: optimize Hurd tests when reading/writing inodes ext4: kill i_version support for Hurd-castrated file systems ext4: each filesystem creates and uses its own mb_cache fs/mbcache.c: doucple the locking of local from global data fs/mbcache.c: change block and index hash chain to hlist_bl_node ext4: Introduce FALLOC_FL_ZERO_RANGE flag for fallocate ext4: refactor ext4_fallocate code ext4: Update inode i_size after the preallocation ext4: fix partial cluster handling for bigalloc file systems ext4: delete path dealloc code in ext4_ext_handle_uninitialized_extents ext4: only call sync_filesystm() when remounting read-only fs: push sync_filesystem() down to the file system's remount_fs() jbd2: improve error messages for inconsistent journal heads jbd2: minimize region locked by j_list_lock in jbd2_journal_forget() jbd2: minimize region locked by j_list_lock in journal_get_create_access() ...
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/ext4.h102
1 files changed, 70 insertions, 32 deletions
diff --git a/include/trace/events/ext4.h b/include/trace/events/ext4.h
index 197d3125df2a..010ea89eeb0e 100644
--- a/include/trace/events/ext4.h
+++ b/include/trace/events/ext4.h
@@ -16,6 +16,15 @@ struct mpage_da_data;
16struct ext4_map_blocks; 16struct ext4_map_blocks;
17struct extent_status; 17struct extent_status;
18 18
19/* shim until we merge in the xfs_collapse_range branch */
20#ifndef FALLOC_FL_COLLAPSE_RANGE
21#define FALLOC_FL_COLLAPSE_RANGE 0x08
22#endif
23
24#ifndef FALLOC_FL_ZERO_RANGE
25#define FALLOC_FL_ZERO_RANGE 0x10
26#endif
27
19#define EXT4_I(inode) (container_of(inode, struct ext4_inode_info, vfs_inode)) 28#define EXT4_I(inode) (container_of(inode, struct ext4_inode_info, vfs_inode))
20 29
21#define show_mballoc_flags(flags) __print_flags(flags, "|", \ 30#define show_mballoc_flags(flags) __print_flags(flags, "|", \
@@ -68,6 +77,13 @@ struct extent_status;
68 { EXTENT_STATUS_DELAYED, "D" }, \ 77 { EXTENT_STATUS_DELAYED, "D" }, \
69 { EXTENT_STATUS_HOLE, "H" }) 78 { EXTENT_STATUS_HOLE, "H" })
70 79
80#define show_falloc_mode(mode) __print_flags(mode, "|", \
81 { FALLOC_FL_KEEP_SIZE, "KEEP_SIZE"}, \
82 { FALLOC_FL_PUNCH_HOLE, "PUNCH_HOLE"}, \
83 { FALLOC_FL_NO_HIDE_STALE, "NO_HIDE_STALE"}, \
84 { FALLOC_FL_COLLAPSE_RANGE, "COLLAPSE_RANGE"}, \
85 { FALLOC_FL_ZERO_RANGE, "ZERO_RANGE"})
86
71 87
72TRACE_EVENT(ext4_free_inode, 88TRACE_EVENT(ext4_free_inode,
73 TP_PROTO(struct inode *inode), 89 TP_PROTO(struct inode *inode),
@@ -1328,7 +1344,7 @@ TRACE_EVENT(ext4_direct_IO_exit,
1328 __entry->rw, __entry->ret) 1344 __entry->rw, __entry->ret)
1329); 1345);
1330 1346
1331TRACE_EVENT(ext4_fallocate_enter, 1347DECLARE_EVENT_CLASS(ext4__fallocate_mode,
1332 TP_PROTO(struct inode *inode, loff_t offset, loff_t len, int mode), 1348 TP_PROTO(struct inode *inode, loff_t offset, loff_t len, int mode),
1333 1349
1334 TP_ARGS(inode, offset, len, mode), 1350 TP_ARGS(inode, offset, len, mode),
@@ -1336,23 +1352,45 @@ TRACE_EVENT(ext4_fallocate_enter,
1336 TP_STRUCT__entry( 1352 TP_STRUCT__entry(
1337 __field( dev_t, dev ) 1353 __field( dev_t, dev )
1338 __field( ino_t, ino ) 1354 __field( ino_t, ino )
1339 __field( loff_t, pos ) 1355 __field( loff_t, offset )
1340 __field( loff_t, len ) 1356 __field( loff_t, len )
1341 __field( int, mode ) 1357 __field( int, mode )
1342 ), 1358 ),
1343 1359
1344 TP_fast_assign( 1360 TP_fast_assign(
1345 __entry->dev = inode->i_sb->s_dev; 1361 __entry->dev = inode->i_sb->s_dev;
1346 __entry->ino = inode->i_ino; 1362 __entry->ino = inode->i_ino;
1347 __entry->pos = offset; 1363 __entry->offset = offset;
1348 __entry->len = len; 1364 __entry->len = len;
1349 __entry->mode = mode; 1365 __entry->mode = mode;
1350 ), 1366 ),
1351 1367
1352 TP_printk("dev %d,%d ino %lu pos %lld len %lld mode %d", 1368 TP_printk("dev %d,%d ino %lu offset %lld len %lld mode %s",
1353 MAJOR(__entry->dev), MINOR(__entry->dev), 1369 MAJOR(__entry->dev), MINOR(__entry->dev),
1354 (unsigned long) __entry->ino, __entry->pos, 1370 (unsigned long) __entry->ino,
1355 __entry->len, __entry->mode) 1371 __entry->offset, __entry->len,
1372 show_falloc_mode(__entry->mode))
1373);
1374
1375DEFINE_EVENT(ext4__fallocate_mode, ext4_fallocate_enter,
1376
1377 TP_PROTO(struct inode *inode, loff_t offset, loff_t len, int mode),
1378
1379 TP_ARGS(inode, offset, len, mode)
1380);
1381
1382DEFINE_EVENT(ext4__fallocate_mode, ext4_punch_hole,
1383
1384 TP_PROTO(struct inode *inode, loff_t offset, loff_t len, int mode),
1385
1386 TP_ARGS(inode, offset, len, mode)
1387);
1388
1389DEFINE_EVENT(ext4__fallocate_mode, ext4_zero_range,
1390
1391 TP_PROTO(struct inode *inode, loff_t offset, loff_t len, int mode),
1392
1393 TP_ARGS(inode, offset, len, mode)
1356); 1394);
1357 1395
1358TRACE_EVENT(ext4_fallocate_exit, 1396TRACE_EVENT(ext4_fallocate_exit,
@@ -1384,31 +1422,6 @@ TRACE_EVENT(ext4_fallocate_exit,
1384 __entry->ret) 1422 __entry->ret)
1385); 1423);
1386 1424
1387TRACE_EVENT(ext4_punch_hole,
1388 TP_PROTO(struct inode *inode, loff_t offset, loff_t len),
1389
1390 TP_ARGS(inode, offset, len),
1391
1392 TP_STRUCT__entry(
1393 __field( dev_t, dev )
1394 __field( ino_t, ino )
1395 __field( loff_t, offset )
1396 __field( loff_t, len )
1397 ),
1398
1399 TP_fast_assign(
1400 __entry->dev = inode->i_sb->s_dev;
1401 __entry->ino = inode->i_ino;
1402 __entry->offset = offset;
1403 __entry->len = len;
1404 ),
1405
1406 TP_printk("dev %d,%d ino %lu offset %lld len %lld",
1407 MAJOR(__entry->dev), MINOR(__entry->dev),
1408 (unsigned long) __entry->ino,
1409 __entry->offset, __entry->len)
1410);
1411
1412TRACE_EVENT(ext4_unlink_enter, 1425TRACE_EVENT(ext4_unlink_enter,
1413 TP_PROTO(struct inode *parent, struct dentry *dentry), 1426 TP_PROTO(struct inode *parent, struct dentry *dentry),
1414 1427
@@ -2410,6 +2423,31 @@ TRACE_EVENT(ext4_es_shrink_exit,
2410 __entry->shrunk_nr, __entry->cache_cnt) 2423 __entry->shrunk_nr, __entry->cache_cnt)
2411); 2424);
2412 2425
2426TRACE_EVENT(ext4_collapse_range,
2427 TP_PROTO(struct inode *inode, loff_t offset, loff_t len),
2428
2429 TP_ARGS(inode, offset, len),
2430
2431 TP_STRUCT__entry(
2432 __field(dev_t, dev)
2433 __field(ino_t, ino)
2434 __field(loff_t, offset)
2435 __field(loff_t, len)
2436 ),
2437
2438 TP_fast_assign(
2439 __entry->dev = inode->i_sb->s_dev;
2440 __entry->ino = inode->i_ino;
2441 __entry->offset = offset;
2442 __entry->len = len;
2443 ),
2444
2445 TP_printk("dev %d,%d ino %lu offset %lld len %lld",
2446 MAJOR(__entry->dev), MINOR(__entry->dev),
2447 (unsigned long) __entry->ino,
2448 __entry->offset, __entry->len)
2449);
2450
2413#endif /* _TRACE_EXT4_H */ 2451#endif /* _TRACE_EXT4_H */
2414 2452
2415/* This part must be outside protection */ 2453/* This part must be outside protection */