Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1499031

Re: [PATCH 4/7] f2fs: show pending allocated nids count in debugfs

From Jaegeuk Kim <jaegeuk@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH 4/7] f2fs: show pending allocated nids count in debugfs
Date 2016-10-11 19:30 +0200
Message-ID <sr92h-15w-5@gated-at.bofh.it> (permalink)
References <sr6nL-7Uu-3@gated-at.bofh.it> <sr6nL-7Uu-21@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Chao,

This must be merged into original split patch (maybe representing a list array).

Thanks,

On Tue, Oct 11, 2016 at 10:31:33PM +0800, Chao Yu wrote:
> From: Chao Yu <yuchao0@huawei.com>
> 
> Add to show pending allocated nids count in debugfs.
> 
> Signed-off-by: Chao Yu <yuchao0@huawei.com>
> ---
>  fs/f2fs/debug.c | 7 ++++---
>  fs/f2fs/f2fs.h  | 2 +-
>  2 files changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/fs/f2fs/debug.c b/fs/f2fs/debug.c
> index 9789138..05a70b4 100644
> --- a/fs/f2fs/debug.c
> +++ b/fs/f2fs/debug.c
> @@ -74,7 +74,8 @@ static void update_general_status(struct f2fs_sb_info *sbi)
>  	si->dirty_nats = NM_I(sbi)->dirty_nat_cnt;
>  	si->sits = MAIN_SEGS(sbi);
>  	si->dirty_sits = SIT_I(sbi)->dirty_sentries;
> -	si->fnids = NM_I(sbi)->free_nid_cnt;
> +	si->free_nids = NM_I(sbi)->free_nid_cnt;
> +	si->alloc_nids = NM_I(sbi)->alloc_nid_cnt;
>  	si->bg_gc = sbi->bg_gc;
>  	si->util_free = (int)(free_user_blocks(sbi) >> sbi->log_blocks_per_seg)
>  		* 100 / (int)(sbi->user_block_count >> sbi->log_blocks_per_seg)
> @@ -325,8 +326,8 @@ static int stat_show(struct seq_file *s, void *v)
>  			   si->ndirty_imeta);
>  		seq_printf(s, "  - NATs: %9d/%9d\n  - SITs: %9d/%9d\n",
>  			   si->dirty_nats, si->nats, si->dirty_sits, si->sits);
> -		seq_printf(s, "  - free_nids: %9d\n",
> -			   si->fnids);
> +		seq_printf(s, "  - free_nids: %9d, alloc_nids: %9d\n",
> +			   si->free_nids, si->alloc_nids);
>  		seq_puts(s, "\nDistribution of User Blocks:");
>  		seq_puts(s, " [ valid | invalid | free ]\n");
>  		seq_puts(s, "  [");
> diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h
> index d6dff15..a726e47 100644
> --- a/fs/f2fs/f2fs.h
> +++ b/fs/f2fs/f2fs.h
> @@ -2206,7 +2206,7 @@ struct f2fs_stat_info {
>  	s64 ndirty_node, ndirty_dent, ndirty_meta, ndirty_data, ndirty_imeta;
>  	s64 inmem_pages;
>  	unsigned int ndirty_dirs, ndirty_files, ndirty_all;
> -	int nats, dirty_nats, sits, dirty_sits, fnids;
> +	int nats, dirty_nats, sits, dirty_sits, free_nids, alloc_nids;
>  	int total_count, utilization;
>  	int bg_gc, wb_bios;
>  	int inline_xattr, inline_inode, inline_dir, orphans;
> -- 
> 2.10.1

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH 4/7] f2fs: show pending allocated nids count in debugfs Chao Yu <chao@kernel.org> - 2016-10-11 16:40 +0200
  Re: [PATCH 4/7] f2fs: show pending allocated nids count in debugfs Jaegeuk Kim <jaegeuk@kernel.org> - 2016-10-11 19:30 +0200

csiph-web