All of lore.kernel.org
 help / color / mirror / Atom feed
* [f2fs-dev] [PATCH] f2fs: always call f2fs_issue_checkpoint() in f2fs_sync_fs()
@ 2021-08-16 13:22 ` Yangtao Li
  0 siblings, 0 replies; 4+ messages in thread
From: Yangtao Li @ 2021-08-16 13:22 UTC (permalink / raw)
  To: jaegeuk, chao; +Cc: Yangtao Li, linux-kernel, linux-f2fs-devel

Sync is always 1, so delete the check of the value.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/f2fs/super.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
index 98727e04d271..b823c7e3f303 100644
--- a/fs/f2fs/super.c
+++ b/fs/f2fs/super.c
@@ -1553,7 +1553,6 @@ static void f2fs_put_super(struct super_block *sb)
 int f2fs_sync_fs(struct super_block *sb, int sync)
 {
 	struct f2fs_sb_info *sbi = F2FS_SB(sb);
-	int err = 0;
 
 	if (unlikely(f2fs_cp_error(sbi)))
 		return 0;
@@ -1565,10 +1564,7 @@ int f2fs_sync_fs(struct super_block *sb, int sync)
 	if (unlikely(is_sbi_flag_set(sbi, SBI_POR_DOING)))
 		return -EAGAIN;
 
-	if (sync)
-		err = f2fs_issue_checkpoint(sbi);
-
-	return err;
+	return f2fs_issue_checkpoint(sbi);
 }
 
 static int f2fs_freeze(struct super_block *sb)
-- 
2.32.0



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] f2fs: always call f2fs_issue_checkpoint() in f2fs_sync_fs()
@ 2021-08-16 13:22 ` Yangtao Li
  0 siblings, 0 replies; 4+ messages in thread
From: Yangtao Li @ 2021-08-16 13:22 UTC (permalink / raw)
  To: jaegeuk, chao; +Cc: linux-f2fs-devel, linux-kernel, Yangtao Li

Sync is always 1, so delete the check of the value.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 fs/f2fs/super.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
index 98727e04d271..b823c7e3f303 100644
--- a/fs/f2fs/super.c
+++ b/fs/f2fs/super.c
@@ -1553,7 +1553,6 @@ static void f2fs_put_super(struct super_block *sb)
 int f2fs_sync_fs(struct super_block *sb, int sync)
 {
 	struct f2fs_sb_info *sbi = F2FS_SB(sb);
-	int err = 0;
 
 	if (unlikely(f2fs_cp_error(sbi)))
 		return 0;
@@ -1565,10 +1564,7 @@ int f2fs_sync_fs(struct super_block *sb, int sync)
 	if (unlikely(is_sbi_flag_set(sbi, SBI_POR_DOING)))
 		return -EAGAIN;
 
-	if (sync)
-		err = f2fs_issue_checkpoint(sbi);
-
-	return err;
+	return f2fs_issue_checkpoint(sbi);
 }
 
 static int f2fs_freeze(struct super_block *sb)
-- 
2.32.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] f2fs: always call f2fs_issue_checkpoint() in f2fs_sync_fs()
  2021-08-16 13:22 ` Yangtao Li
@ 2021-08-17  0:32   ` Jaegeuk Kim
  -1 siblings, 0 replies; 4+ messages in thread
From: Jaegeuk Kim @ 2021-08-17  0:32 UTC (permalink / raw)
  To: Yangtao Li; +Cc: chao, linux-f2fs-devel, linux-kernel

On 08/16, Yangtao Li wrote:
> Sync is always 1, so delete the check of the value.

I don't think so.

> 
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>  fs/f2fs/super.c | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
> index 98727e04d271..b823c7e3f303 100644
> --- a/fs/f2fs/super.c
> +++ b/fs/f2fs/super.c
> @@ -1553,7 +1553,6 @@ static void f2fs_put_super(struct super_block *sb)
>  int f2fs_sync_fs(struct super_block *sb, int sync)
>  {
>  	struct f2fs_sb_info *sbi = F2FS_SB(sb);
> -	int err = 0;
>  
>  	if (unlikely(f2fs_cp_error(sbi)))
>  		return 0;
> @@ -1565,10 +1564,7 @@ int f2fs_sync_fs(struct super_block *sb, int sync)
>  	if (unlikely(is_sbi_flag_set(sbi, SBI_POR_DOING)))
>  		return -EAGAIN;
>  
> -	if (sync)
> -		err = f2fs_issue_checkpoint(sbi);
> -
> -	return err;
> +	return f2fs_issue_checkpoint(sbi);
>  }
>  
>  static int f2fs_freeze(struct super_block *sb)
> -- 
> 2.32.0

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [f2fs-dev] [PATCH] f2fs: always call f2fs_issue_checkpoint() in f2fs_sync_fs()
@ 2021-08-17  0:32   ` Jaegeuk Kim
  0 siblings, 0 replies; 4+ messages in thread
From: Jaegeuk Kim @ 2021-08-17  0:32 UTC (permalink / raw)
  To: Yangtao Li; +Cc: linux-kernel, linux-f2fs-devel

On 08/16, Yangtao Li wrote:
> Sync is always 1, so delete the check of the value.

I don't think so.

> 
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>  fs/f2fs/super.c | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
> index 98727e04d271..b823c7e3f303 100644
> --- a/fs/f2fs/super.c
> +++ b/fs/f2fs/super.c
> @@ -1553,7 +1553,6 @@ static void f2fs_put_super(struct super_block *sb)
>  int f2fs_sync_fs(struct super_block *sb, int sync)
>  {
>  	struct f2fs_sb_info *sbi = F2FS_SB(sb);
> -	int err = 0;
>  
>  	if (unlikely(f2fs_cp_error(sbi)))
>  		return 0;
> @@ -1565,10 +1564,7 @@ int f2fs_sync_fs(struct super_block *sb, int sync)
>  	if (unlikely(is_sbi_flag_set(sbi, SBI_POR_DOING)))
>  		return -EAGAIN;
>  
> -	if (sync)
> -		err = f2fs_issue_checkpoint(sbi);
> -
> -	return err;
> +	return f2fs_issue_checkpoint(sbi);
>  }
>  
>  static int f2fs_freeze(struct super_block *sb)
> -- 
> 2.32.0


_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-08-17  0:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-16 13:22 [f2fs-dev] [PATCH] f2fs: always call f2fs_issue_checkpoint() in f2fs_sync_fs() Yangtao Li
2021-08-16 13:22 ` Yangtao Li
2021-08-17  0:32 ` Jaegeuk Kim
2021-08-17  0:32   ` [f2fs-dev] " Jaegeuk Kim

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.