From: Chao Yu <chao@kernel.org>
To: Julian Sun <sunjunchao2870@gmail.com>,
linux-f2fs-devel@lists.sourceforge.net
Cc: jaegeuk@kernel.org
Subject: Re: [f2fs-dev] [PATCH 2/2] f2fs: fix macro definition stat_inc_cp_count
Date: Mon, 22 Jul 2024 09:33:06 +0800 [thread overview]
Message-ID: <0df662f4-e003-40fb-883d-fab8c21be092@kernel.org> (raw)
In-Reply-To: <20240721131739.260027-2-sunjunchao2870@gmail.com>
On 2024/7/21 21:17, Julian Sun wrote:
> The macro stat_inc_cp_count accepts a parameter si,
> but it was not used, rather the variable sbi was directly used,
> which may be a local variable inside a function that calls the macros.
>
> Signed-off-by: Julian Sun <sunjunchao2870@gmail.com>
> ---
> fs/f2fs/f2fs.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h
> index 8a9d910aa552..c9925d1ca2df 100644
> --- a/fs/f2fs/f2fs.h
> +++ b/fs/f2fs/f2fs.h
> @@ -3987,7 +3987,7 @@ static inline struct f2fs_stat_info *F2FS_STAT(struct f2fs_sb_info *sbi)
>
> #define stat_inc_cp_call_count(sbi, foreground) \
> atomic_inc(&sbi->cp_call_count[(foreground)])
> -#define stat_inc_cp_count(si) (F2FS_STAT(sbi)->cp_count++)
> +#define stat_inc_cp_count(_sbi) (F2FS_STAT(_sbi)->cp_count++)
Let's use sbi instead of _sbi.
Thanks,
> #define stat_io_skip_bggc_count(sbi) ((sbi)->io_skip_bggc++)
> #define stat_other_skip_bggc_count(sbi) ((sbi)->other_skip_bggc++)
> #define stat_inc_dirty_inode(sbi, type) ((sbi)->ndirty_inode[type]++)
_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
next prev parent reply other threads:[~2024-07-22 1:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-21 13:17 [f2fs-dev] [PATCH 1/2] f2fs: fix macro definition on_f2fs_build_free_nids Julian Sun
2024-07-21 13:17 ` [f2fs-dev] [PATCH 2/2] f2fs: fix macro definition stat_inc_cp_count Julian Sun
2024-07-22 1:33 ` Chao Yu [this message]
2024-07-22 1:32 ` [f2fs-dev] [PATCH 1/2] f2fs: fix macro definition on_f2fs_build_free_nids Chao Yu
2024-07-22 2:14 ` Julian Sun
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0df662f4-e003-40fb-883d-fab8c21be092@kernel.org \
--to=chao@kernel.org \
--cc=jaegeuk@kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=sunjunchao2870@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.