commit 0b04ce1ec5309002b5990e300c46a806421a8503 Author: Andrew Price Date: Tue Jun 4 17:16:18 2019 +0100 fsck.gfs2: Disambiguate 'check_data' Having several functions with this name confuses profiling tools and makes reports difficult to read. Give the different check_data functions better names. Signed-off-by: Andrew Price diff --git a/gfs2/fsck/metawalk.c b/gfs2/fsck/metawalk.c index 4d6dcfae..a334180f 100644 --- a/gfs2/fsck/metawalk.c +++ b/gfs2/fsck/metawalk.c @@ -1390,7 +1390,7 @@ error_undo: /* undo what we've done so far for this block */ * 1 if errors were found and corrected * 2 (ENOENT) is there were too many bad pointers */ -static int check_data(struct gfs2_inode *ip, struct metawalk_fxns *pass, +static int metawalk_check_data(struct gfs2_inode *ip, struct metawalk_fxns *pass, struct gfs2_buffer_head *bh, int head_size, uint64_t *blks_checked, struct error_block *error_blk) { @@ -1589,7 +1589,7 @@ int check_metatree(struct gfs2_inode *ip, struct metawalk_fxns *pass) continue; if (pass->check_data) - error = check_data(ip, pass, bh, head_size, + error = metawalk_check_data(ip, pass, bh, head_size, &blks_checked, &error_blk); if (pass->big_file_msg && ip->i_di.di_blocks > COMFORTABLE_BLKS) pass->big_file_msg(ip, blks_checked); diff --git a/gfs2/fsck/pass1.c b/gfs2/fsck/pass1.c index 6f04109b..c7de3e39 100644 --- a/gfs2/fsck/pass1.c +++ b/gfs2/fsck/pass1.c @@ -44,7 +44,7 @@ static int check_metalist(struct gfs2_inode *ip, uint64_t block, int *was_duplicate, void *private); static int undo_check_metalist(struct gfs2_inode *ip, uint64_t block, int h, void *private); -static int check_data(struct gfs2_inode *ip, uint64_t metablock, +static int pass1_check_data(struct gfs2_inode *ip, uint64_t metablock, uint64_t block, void *private, struct gfs2_buffer_head *bh, uint64_t *ptr); static int undo_check_data(struct gfs2_inode *ip, uint64_t block, @@ -192,7 +192,7 @@ struct metawalk_fxns pass1_fxns = { .private = NULL, .check_leaf = p1check_leaf, .check_metalist = check_metalist, - .check_data = check_data, + .check_data = pass1_check_data, .check_eattr_indir = check_eattr_indir, .check_eattr_leaf = check_eattr_leaf, .check_dentry = NULL, @@ -542,7 +542,7 @@ out: return error; } -static int check_data(struct gfs2_inode *ip, uint64_t metablock, +static int pass1_check_data(struct gfs2_inode *ip, uint64_t metablock, uint64_t block, void *private, struct gfs2_buffer_head *bbh, uint64_t *ptr) {