Add tracepoints for ext3/jbd
cover Add tracepoints for ext3/jbd
This patch series adds fixed tracepoints into ext3 a nd jbd code. It has been based on ext4 and jbd2 tracepoints and contains most of them. However due to the differences in the code there are some tracepoint missing (all multi-block allocation in ext4) and there are some added (inode reservation windows in ext3).
Regarding jbd, there is not the code for collecting statistics and appropriate tracepoints. That's because this code is little bit more intrusive, so I think it deserves its own commit, hence can be added later if someone needs it.
The reason for those tracepoints is that our customer intend to use it for monitoring and data collecting from servers running ext3. There is no plan to migrate to ext4 any time soon.
These patches are as little intrusive as it can be, pretty straightforward and should not change the behaviour at all.
Thanks!
-Lukas
---
[PATCH 1/2] ext3: Add fixed tracepoints
fs/ext3/balloc.c | 34 +- fs/ext3/fsync.c | 15 +- fs/ext3/ialloc.c | 4 + fs/ext3/inode.c | 29 ++ fs/ext3/namei.c | 3 + fs/ext3/super.c | 13 + include/trace/events/ext3.h | 888 +++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 970 insertions(+), 16 deletions(-) create mode 100644 include/trace/events/ext3.h [PATCH 2/2] jbd: Add fixed tracepoints fs/jbd/checkpoint.c | 4 + fs/jbd/commit.c | 11 +++ fs/jbd/journal.c | 4 + include/trace/events/jbd.h | 203 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 222 insertions(+), 0 deletions(-) create mode 100644 include/trace/events/jbd.h
PATCH 1/2 ext3: Add fixed tracepoints
This commit adds fixed tracepoints to the ext3 code. It is based on ext4 tracepoints, however due to the differences of both file systems, there are some tracepoints missing (those for delaloc and for multi-block allocator) and there are some ext3 specific as well (for reservation windows).
Here is a list:
ext3_free_inodeext3_request_inodeext3_allocate_inodeext3_evict_inodeext3_drop_inodeext3_mark_inode_dirtyext3_write_beginext3_ordered_write_endext3_writeback_write_endext3_journalled_write_endext3_ordered_writepageext3_writeback_writepageext3_journalled_writepageext3_readpageext3_releasepageext3_invalidatepageext3_discard_blocksext3_request_blocksext3_allocate_blocksext3_free_blocksext3_sync_file_enterext3_sync_file_exitext3_sync_fsext3_rsv_window_addext3_discard_reservationext3_alloc_new_reservationext3_reservedext3_forgetext3_read_block_bitmapext3_direct_IO_enterext3_direct_IO_exitext3_unlink_enterext3_unlink_exitext3_truncate_enterext3_truncate_exitext3_get_blocks_enterext3_get_blocks_exitext3_load_inode
--- fs/ext3/balloc.c | 34 +- fs/ext3/fsync.c | 15 +- fs/ext3/ialloc.c | 4 + fs/ext3/inode.c | 29 ++ fs/ext3/namei.c | 3 + fs/ext3/super.c | 13 + include/trace/events/ext3.h | 888 +++++++++++++++++++++++++++++++++++++++++++ 7 files changed, 970 insertions(+), 16 deletions(-) create mode 100644 include/trace/events/ext3.h
fs/ext3/balloc.c +21 -13
@@ -21,6 +21,7 @@#include <linux/quotaops.h> #include <linux/buffer_head.h> #include <linux/blkdev.h> +#include <trace/events/ext3.h> /* * balloc.c contains the blocks allocation and deallocation routines
@@ -161,6 +162,7 @@ read_block_bitmap(struct super_block *sb, unsigned int block_group) desc =ext3_get_group_desc (sb, block_group,NULL );if (!desc)return NULL ; +trace_ext3_read_block_bitmap (sb, block_group); bitmap_blk =le32_to_cpu (desc->bg_block_bitmap); bh =sb_getblk (sb, bitmap_blk);if (unlikely (!bh)) {
@@ -351,6 +353,7 @@ void ext3_rsv_window_add(struct super_block *sb,struct rb_node * parent =NULL ;struct ext3_reserve_window_node *this; +trace_ext3_rsv_window_add (sb, rsv);while (*p) { parent = *p;
@@ -476,8 +479,10 @@ void ext3_discard_reservation(struct inode *inode) rsv = &block_i->rsv_window_node;if (!rsv_is_empty (&rsv->rsv_window)) {spin_lock (rsv_lock); -if (!rsv_is_empty (&rsv->rsv_window)) +if (!rsv_is_empty (&rsv->rsv_window)) { +trace_ext3_discard_reservation (inode, rsv);rsv_window_remove (inode->i_sb, rsv); + }spin_unlock (rsv_lock); } }
@@ -683,14 +688,10 @@ error_return:void ext3_free_blocks (handle_t *handle,struct inode *inode,ext3_fsblk_t block,unsigned long count) { -struct super_block * sb; +struct super_block *sb = inode->i_sb;unsigned long dquot_freed_blocks; - sb = inode->i_sb; -if (!sb) { -printk ("ext3_free_blocks: nonexistent device" ); -return ; - } +trace_ext3_free_blocks (inode, block, count);ext3_free_blocks_sb (handle, sb, block, count, &dquot_freed_blocks);if (dquot_freed_blocks)dquot_free_block (inode, dquot_freed_blocks);
@@ -1136,6 +1137,7 @@ static int alloc_new_reservation(struct ext3_reserve_window_node *my_rsv,else start_block = grp_goal + group_first_block; +trace_ext3_alloc_new_reservation (sb, start_block); size = my_rsv->rsv_goal_size;if (!rsv_is_empty (&my_rsv->rsv_window)) {
@@ -1230,8 +1232,11 @@ retry:* check if the first free block is within the * free space we just reserved */ -if (start_block >= my_rsv->rsv_start && start_block <= my_rsv->rsv_end) +if (start_block >= my_rsv->rsv_start && + start_block <= my_rsv->rsv_end) { +trace_ext3_reserved (sb, start_block, my_rsv);return 0 ;/* success */ + }/* * if the first free bit we found is out of the reservable space * continue search for next reservable space,
@@ -1514,10 +1519,6 @@ ext3_fsblk_t ext3_new_blocks(handle_t *handle, struct inode *inode, *errp = -ENOSPC ; sb = inode->i_sb; -if (!sb) { -printk ("ext3_new_block: nonexistent device" ); -return 0 ; - }/* * Check quota for allocation of this block.
@@ -1528,8 +1529,10 @@ ext3_fsblk_t ext3_new_blocks(handle_t *handle, struct inode *inode,return 0 ; } +trace_ext3_request_blocks (inode, goal, num); + sbi =EXT3_SB (sb); - es =EXT3_SB (sb)->s_es; + es = sbi->s_es;ext3_debug ("goal=%lu.\n" , goal);/* * Allocate a block from reservation only when
@@ -1742,6 +1745,10 @@ allocated:brelse (bitmap_bh);dquot_free_block (inode, *count-num); *count = num; + +trace_ext3_allocate_blocks (inode, goal, num, + (unsigned long long )ret_block); +return ret_block; io_error:
@@ -1996,6 +2003,7 @@ ext3_grpblk_t ext3_trim_all_free(struct super_block *sb, unsigned int group,if ((next - start) < minblocks) goto free_extent; +trace_ext3_discard_blocks (sb, discard_block, next - start);/* Send the TRIM command down to the device */ err =sb_issue_discard (sb, discard_block, next - start,GFP_NOFS ,0 );
fs/ext3/fsync.c +12 -3
@@ -30,6 +30,7 @@#include <linux/jbd.h> #include <linux/ext3_fs.h> #include <linux/ext3_jbd.h> +#include <trace/events/ext3.h> /* * akpm: A new design for ext3_sync_file().
@@ -51,10 +52,13 @@ int ext3_sync_file(struct file *file, int datasync)int ret, needs_barrier =0 ;tid_t commit_tid; +J_ASSERT (ext3_journal_current_handle () ==NULL ); + +trace_ext3_sync_file_enter (file, datasync); +if (inode->i_sb->s_flags &MS_RDONLY )return 0 ; -J_ASSERT (ext3_journal_current_handle () ==NULL );/* * data=writeback,ordered:
@@ -70,8 +74,10 @@ int ext3_sync_file(struct file *file, int datasync)* (they were dirtied by commit). But that's OK - the blocks are * safe in-journal, which is all fsync() needs to ensure. */ -if (ext3_should_journal_data (inode)) -return ext3_force_commit (inode->i_sb); +if (ext3_should_journal_data (inode)) { + ret =ext3_force_commit (inode->i_sb); + goto out; + }if (datasync) commit_tid =atomic_read (&ei->i_datasync_tid);
@@ -91,5 +97,8 @@ int ext3_sync_file(struct file *file, int datasync)*/ if (needs_barrier)blkdev_issue_flush (inode->i_sb->s_bdev,GFP_KERNEL ,NULL ); + +out: +trace_ext3_sync_file_exit (inode, ret);return ret; }
fs/ext3/ialloc.c +4 -0
@@ -23,6 +23,7 @@#include <linux/buffer_head.h> #include <linux/random.h> #include <linux/bitops.h> +#include <trace/events/ext3.h> #include <asm/byteorder.h>
@@ -118,6 +119,7 @@ void ext3_free_inode (handle_t *handle, struct inode * inode) ino = inode->i_ino;ext3_debug ("freeing inode %lu\n" , ino); +trace_ext3_free_inode (inode); is_directory =S_ISDIR (inode->i_mode);
@@ -426,6 +428,7 @@ struct inode *ext3_new_inode(handle_t *handle, struct inode * dir,return ERR_PTR (-EPERM ); sb = dir->i_sb; +trace_ext3_request_inode (dir, mode); inode =new_inode (sb);if (!inode)return ERR_PTR (-ENOMEM );
@@ -601,6 +604,7 @@ got: }ext3_debug ("allocating inode %lu\n" , inode->i_ino); +trace_ext3_allocate_inode (inode, dir, mode); goto really_out; fail:ext3_std_error (sb, err);
fs/ext3/inode.c +29 -0
@@ -38,6 +38,7 @@#include <linux/bio.h> #include <linux/fiemap.h> #include <linux/namei.h> +#include <trace/events/ext3.h> #include "xattr.h" #include "acl.h"
@@ -70,6 +71,7 @@ int ext3_forget(handle_t *handle, int is_metadata, struct inode *inode,might_sleep (); +trace_ext3_forget (inode, is_metadata, blocknr);BUFFER_TRACE (bh,"enter" ); jbd_debug(4, "forgetting bh %p: is_metadata = %d, mode %o, "
@@ -198,6 +200,7 @@ void ext3_evict_inode (struct inode *inode)handle_t *handle;int want_delete =0 ; +trace_ext3_evict_inode (inode);if (!inode->i_nlink && !is_bad_inode (inode)) {dquot_initialize (inode); want_delete =1 ;
@@ -842,6 +845,7 @@ int ext3_get_blocks_handle(handle_t *handle, struct inode *inode,ext3_fsblk_t first_block =0 ; +trace_ext3_get_blocks_enter (inode, iblock, maxblocks, create);J_ASSERT (handle !=NULL || create ==0 ); depth =ext3_block_to_path (inode,iblock,offsets,&blocks_to_boundary);
@@ -970,6 +974,9 @@ cleanup: }BUFFER_TRACE (bh_result,"returned" ); out: +trace_ext3_get_blocks_exit (inode, iblock, +le32_to_cpu (chain[depth-1 ].key), + count, err);return err; }
@@ -1217,6 +1224,8 @@ static int ext3_write_begin(struct file *file, struct address_space *mapping,* we allocate blocks but write fails for some reason */ int needed_blocks =ext3_writepage_trans_blocks (inode) +1 ; +trace_ext3_write_begin (inode, pos, len, flags); + index = pos >>PAGE_CACHE_SHIFT ; from = pos & (PAGE_CACHE_SIZE -1 ); to = from + len;
@@ -1332,6 +1341,7 @@ static int ext3_ordered_write_end(struct file *file,unsigned from, to;int ret =0 , ret2; +trace_ext3_ordered_write_end (inode, pos, len, copied); copied =block_write_end (file, mapping, pos, len, copied, page, fsdata); from = pos & (PAGE_CACHE_SIZE -1 );
@@ -1367,6 +1377,7 @@ static int ext3_writeback_write_end(struct file *file,struct inode *inode = file->f_mapping->host;int ret; +trace_ext3_writeback_write_end (inode, pos, len, copied); copied =block_write_end (file, mapping, pos, len, copied, page, fsdata);update_file_sizes (inode, pos, copied);/*
@@ -1395,6 +1406,7 @@ static int ext3_journalled_write_end(struct file *file,int partial =0 ;unsigned from, to; +trace_ext3_journalled_write_end (inode, pos, len, copied); from = pos & (PAGE_CACHE_SIZE -1 ); to = from + len;
@@ -1577,6 +1589,7 @@ static int ext3_ordered_writepage(struct page *page,if (ext3_journal_current_handle ()) goto out_fail; +trace_ext3_ordered_writepage (inode, page);if (!page_has_buffers (page)) {create_empty_buffers (page, inode->i_sb->s_blocksize, (1 << BH_Dirty)|(1 << BH_Uptodate));
@@ -1647,6 +1660,7 @@ static int ext3_writeback_writepage(struct page *page,if (ext3_journal_current_handle ()) goto out_fail; +trace_ext3_writeback_writepage (inode, page);if (page_has_buffers (page)) {if (!walk_page_buffers (NULL ,page_buffers (page),0 ,PAGE_CACHE_SIZE ,NULL , buffer_unmapped)) {
@@ -1689,6 +1703,7 @@ static int ext3_journalled_writepage(struct page *page,if (ext3_journal_current_handle ()) goto no_write; +trace_ext3_journalled_writepage (inode, page); handle =ext3_journal_start (inode,ext3_writepage_trans_blocks (inode));if (IS_ERR (handle)) { ret =PTR_ERR (handle);
@@ -1739,6 +1754,7 @@ out_unlock:static int ext3_readpage (struct file *file,struct page *page) { +trace_ext3_readpage (page);return mpage_readpage (page, ext3_get_block); }
@@ -1753,6 +1769,8 @@ static void ext3_invalidatepage(struct page *page, unsigned long offset) {journal_t *journal =EXT3_JOURNAL (page->mapping->host); +trace_ext3_invalidatepage (page, offset); +/* * If it's a full truncate we just forget about the pending dirtying */
@@ -1766,6 +1784,7 @@ static int ext3_releasepage(struct page *page, gfp_t wait) {journal_t *journal =EXT3_JOURNAL (page->mapping->host); +trace_ext3_releasepage (page);WARN_ON (PageChecked (page));if (!page_has_buffers (page))return 0 ;
@@ -1794,6 +1813,8 @@ static ssize_t ext3_direct_IO(int rw, struct kiocb *iocb,size_t count =iov_length (iov, nr_segs);int retries =0 ; +trace_ext3_direct_IO_enter (inode, offset,iov_length (iov, nr_segs), rw); +if (rw ==WRITE ) {loff_t final_size = offset + count;
@@ -1868,6 +1889,8 @@ retry: ret = err; } out: +trace_ext3_direct_IO_exit (inode, offset, +iov_length (iov, nr_segs), rw, ret);return ret; }
@@ -2446,6 +2469,8 @@ void ext3_truncate(struct inode *inode)unsigned blocksize = inode->i_sb->s_blocksize;struct page *page; +trace_ext3_truncate_enter (inode); +if (!ext3_can_truncate (inode)) goto out_notrans;
@@ -2597,6 +2622,7 @@ out_stop:ext3_orphan_del (handle, inode);ext3_journal_stop (handle); +trace_ext3_truncate_exit (inode);return ; out_notrans:/*
@@ -2605,6 +2631,7 @@ out_notrans:*/ if (inode->i_nlink)ext3_orphan_del (NULL , inode); +trace_ext3_truncate_exit (inode); } static ext3_fsblk_t ext3_get_inode_block(struct super_block *sb,
@@ -2746,6 +2773,7 @@ make_io:* has in-inode xattrs, or we don't have this inode in memory. * Read the block from disk. */ +trace_ext3_load_inode (inode);get_bh (bh); bh->b_end_io = end_buffer_read_sync;submit_bh (READ_META , bh);
@@ -3372,6 +3400,7 @@ int ext3_mark_inode_dirty(handle_t *handle, struct inode *inode)int err;might_sleep (); +trace_ext3_mark_inode_dirty (inode, _RET_IP_); err =ext3_reserve_inode_write (handle, inode, &iloc);if (!err) err =ext3_mark_iloc_dirty (handle, inode, &iloc);
fs/ext3/namei.c +3 -0
@@ -36,6 +36,7 @@#include <linux/quotaops.h> #include <linux/buffer_head.h> #include <linux/bio.h> +#include <trace/events/ext3.h> #include "namei.h" #include "xattr.h"
@@ -2135,6 +2136,7 @@ static int ext3_unlink(struct inode * dir, struct dentry *dentry)struct ext3_dir_entry_2 * de;handle_t *handle; +trace_ext3_unlink_enter (dir, dentry);/* Initialize quotas before so that eventual writes go * in separate transaction */ dquot_initialize (dir);
@@ -2180,6 +2182,7 @@ static int ext3_unlink(struct inode * dir, struct dentry *dentry) end_unlink:ext3_journal_stop (handle);brelse (bh); +trace_ext3_unlink_exit (dentry, retval);return retval; }
fs/ext3/super.c +13 -0
@@ -43,6 +43,9 @@#include "acl.h" #include "namei.h" +#define CREATE_TRACE_POINTS +#include <trace/events/ext3.h> +#ifdef CONFIG_EXT3_DEFAULTS_TO_ORDERED #define EXT3_MOUNT_DEFAULT_DATA_MODE EXT3_MOUNT_ORDERED_DATA#else
@@ -496,6 +499,14 @@ static struct inode *ext3_alloc_inode(struct super_block *sb)return &ei->vfs_inode; } +static int ext3_drop_inode (struct inode *inode) +{ +int drop =generic_drop_inode (inode); + +trace_ext3_drop_inode (inode, drop); +return drop; +} +static void ext3_i_callback (struct rcu_head *head) { struct inode *inode = container_of(head, struct inode, i_rcu);
@@ -787,6 +798,7 @@ static const struct super_operations ext3_sops = { .destroy_inode = ext3_destroy_inode, .write_inode = ext3_write_inode, .dirty_inode = ext3_dirty_inode, + .drop_inode = ext3_drop_inode, .evict_inode = ext3_evict_inode, .put_super = ext3_put_super, .sync_fs = ext3_sync_fs,
@@ -2505,6 +2517,7 @@ static int ext3_sync_fs(struct super_block *sb, int wait) {tid_t target; +trace_ext3_sync_fs (sb, wait);if (journal_start_commit (EXT3_SB (sb)->s_journal, &target)) {if (wait)log_wait_commit (EXT3_SB (sb)->s_journal, target);
include/trace/events/ext3.h new file +888 -0
888 lines not on this page · raw message
Signature · 1 line
1.7.4.4
PATCH 2/2 jbd: Add fixed tracepoints
In reply to Lukas CzernerThis commit adds fixed tracepoint for jbd. It has been based on fixed tracepoints for jbd2, however there are missing those for collecting statistics, since I think that it will require more intrusive patch so I should have its own commit, if someone decide that it is needed. Also there are new tracepoints in __journal_drop_transaction() and journal_update_superblock().
The list of jbd tracepoints:
jbd_checkpointjbd_start_commitjbd_commit_lockingjbd_commit_flushingjbd_commit_loggingjbd_drop_transactionjbd_end_commitjbd_do_submit_datajbd_cleanup_journal_tailjbd_update_superblock_end
--- fs/jbd/checkpoint.c | 4 + fs/jbd/commit.c | 11 +++ fs/jbd/journal.c | 4 + include/trace/events/jbd.h | 203 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 222 insertions(+), 0 deletions(-) create mode 100644 include/trace/events/jbd.h
fs/jbd/checkpoint.c +4 -0
@@ -22,6 +22,7 @@#include <linux/jbd.h> #include <linux/errno.h> #include <linux/slab.h> +#include <trace/events/jbd.h> /* * Unlink a buffer from a transaction checkpoint list.
@@ -358,6 +359,7 @@ int log_do_checkpoint(journal_t *journal)* journal straight away. */ result =cleanup_journal_tail (journal); +trace_jbd_checkpoint (journal, result);jbd_debug (1 ,"cleanup_journal_tail returned %d\n" , result);if (result <=0 )return result;
@@ -503,6 +505,7 @@ int cleanup_journal_tail(journal_t *journal)if (blocknr < journal->j_tail) freed = freed + journal->j_last - journal->j_first; +trace_jbd_cleanup_journal_tail (journal, first_tid, blocknr, freed); jbd_debug(1, "Cleaning journal tail from %d to %d (offset %u), " "freeing %u\n",
@@ -752,6 +755,7 @@ void __journal_drop_transaction(journal_t *journal, transaction_t *transaction)J_ASSERT (journal->j_committing_transaction != transaction);J_ASSERT (journal->j_running_transaction != transaction); +trace_jbd_drop_transaction (journal, transaction);jbd_debug (1 ,"Dropping transaction %d, all done\n" , transaction->t_tid);kfree (transaction); }
fs/jbd/commit.c +11 -0
@@ -21,6 +21,7 @@#include <linux/pagemap.h> #include <linux/bio.h> #include <linux/blkdev.h> +#include <trace/events/jbd.h> /* * Default IO end handler for temporary BJ_IO buffer_heads.
@@ -204,6 +205,8 @@ write_out_data:if (!trylock_buffer (bh)) {BUFFER_TRACE (bh,"needs blocking lock" );spin_unlock (&journal->j_list_lock); +trace_jbd_do_submit_data (journal, + commit_transaction);/* Write out all data to prevent deadlocks */ journal_do_submit_data (wbuf, bufs, write_op); bufs =0 ;
@@ -236,6 +239,8 @@ write_out_data:jbd_unlock_bh_state (bh);if (bufs == journal->j_wbufsize) {spin_unlock (&journal->j_list_lock); +trace_jbd_do_submit_data (journal, + commit_transaction);journal_do_submit_data (wbuf, bufs, write_op); bufs =0 ; goto write_out_data;
@@ -266,6 +271,7 @@ write_out_data: } }spin_unlock (&journal->j_list_lock); +trace_jbd_do_submit_data (journal, commit_transaction);journal_do_submit_data (wbuf, bufs, write_op);return err;
@@ -322,12 +328,14 @@ void journal_commit_transaction(journal_t *journal) commit_transaction = journal->j_running_transaction;J_ASSERT (commit_transaction->t_state ==T_RUNNING ); +trace_jbd_start_commit (journal, commit_transaction);jbd_debug (1 ,"JBD: starting commit of transaction %d\n" , commit_transaction->t_tid);spin_lock (&journal->j_state_lock); commit_transaction->t_state =T_LOCKED ; +trace_jbd_commit_locking (journal, commit_transaction);spin_lock (&commit_transaction->t_handle_lock);while (commit_transaction->t_updates) {DEFINE_WAIT (wait);
@@ -398,6 +406,7 @@ void journal_commit_transaction(journal_t *journal)*/ journal_switch_revoke_table (journal); +trace_jbd_commit_flushing (journal, commit_transaction); commit_transaction->t_state =T_FLUSH ; journal->j_committing_transaction = commit_transaction; journal->j_running_transaction =NULL ;
@@ -499,6 +508,7 @@ void journal_commit_transaction(journal_t *journal) commit_transaction->t_state =T_COMMIT ;spin_unlock (&journal->j_state_lock); +trace_jbd_commit_logging (journal, commit_transaction);J_ASSERT (commit_transaction->t_nr_buffers <= commit_transaction->t_outstanding_credits);
@@ -947,6 +957,7 @@ restart_loop: }spin_unlock (&journal->j_list_lock); +trace_jbd_end_commit (journal, commit_transaction);jbd_debug (1 ,"JBD: commit %d complete, head %d\n" , journal->j_commit_sequence, journal->j_tail_sequence);
fs/jbd/journal.c +4 -0
@@ -38,6 +38,9 @@#include <linux/debugfs.h> #include <linux/ratelimit.h> +#define CREATE_TRACE_POINTS +#include <trace/events/jbd.h> +#include <asm/uaccess.h> #include <asm/page.h>
@@ -1055,6 +1058,7 @@ void journal_update_superblock(journal_t *journal, int wait) }else write_dirty_buffer (bh,WRITE ); +trace_jbd_update_superblock_end (journal, wait); out:/* If we have just flushed the log (by marking s_start==0), then * any future commit will have to be careful to update the
include/trace/events/jbd.h new file +203 -0
203 lines not on this page · raw message
Signature · 1 line
1.7.4.4
Re: [PATCH 1/2] ext3: Add fixed tracepoints
In reply to Lukas Czernerfs/ext3/inode.c static int ext3_ordered_writepage(struct page *page, · line 1595
Quoted 8 lines
fs/ext3/inode.c +1
-0@@ -1577,6 +1589,7 @@ static int ext3_ordered_writepage(struct page *page,if (ext3_journal_current_handle ()) goto out_fail; +trace_ext3_ordered_writepage (inode, page);if (!page_has_buffers (page)) {create_empty_buffers (page, inode->i_sb->s_blocksize, (1 << BH_Dirty)|(1 << BH_Uptodate));
Any reason why writepage() takes inode while all other page operations
take only the page pointer? I see ext4 does this as well but still we don't have to be *that* compatible :). Otherwise the patch looks OK.
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Re: [PATCH 2/2] jbd: Add fixed tracepoints
In reply to Lukas CzernerQuoted 20 lines · Lukas Czerner
This commit adds fixed tracepoint for jbd. It has been based on fixed tracepoints for jbd2, however there are missing those for collecting statistics, since I think that it will require more intrusive patch so I should have its own commit, if someone decide that it is needed. Also there are new tracepoints in
__journal_drop_transaction()andjournal_update_superblock().The list of jbd tracepoints:
jbd_checkpointjbd_start_commitjbd_commit_lockingjbd_commit_flushingjbd_commit_loggingjbd_drop_transactionjbd_end_commitjbd_do_submit_datajbd_cleanup_journal_tailjbd_update_superblock_end
Quoted 2 lines
Signed-off-by Lukas Czerner <[email protected]>Cc Jan Kara <[email protected]>
The patch looks OK so I guess I'll take it (when that one minor thing in
the first patch is cleared up).
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Re: [PATCH 1/2] ext3: Add fixed tracepoints
In reply to Jan KaraQuoted 12 lines · Jan Kara
fs/ext3/inode.c static int ext3_ordered_writepage(struct page *page, · line 1595
Quoted 8 lines
fs/ext3/inode.c +1
-0@@ -1577,6 +1589,7 @@ static int ext3_ordered_writepage(struct page *page,if (ext3_journal_current_handle ()) goto out_fail; +trace_ext3_ordered_writepage (inode, page);if (!page_has_buffers (page)) {create_empty_buffers (page, inode->i_sb->s_blocksize, (1 << BH_Dirty)|(1 << BH_Uptodate));Any reason why
writepage()takes inode while all other page operations
take only the page pointer? I see ext4 does this as well but still we don't have to be *that* compatible :). Otherwise the patch looks OK.
Quoted 1 line
Honza
Oh, I did not notice that. Thanks, I'll create just one EVENT_CLASS for page operations.
Thanks!
-Lukas