All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] f2fs: don't trigger recovery for normal umount image
@ 2015-01-31  8:59 Chao Yu
  2015-02-02 23:31 ` Jaegeuk Kim
  0 siblings, 1 reply; 3+ messages in thread
From: Chao Yu @ 2015-01-31  8:59 UTC (permalink / raw)
  To: Jaegeuk Kim, Changman Lee; +Cc: linux-f2fs-devel, linux-kernel

Our recovery option is on by default, so we will try to recover data for
a normally umounted image when mounting it, but no data will be recovered.

So it'd be better to skip the recovery for above condition.

Signed-off-by: Chao Yu <chao2.yu@samsung.com>
---
 fs/f2fs/recovery.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c
index 188a034..c80c286 100644
--- a/fs/f2fs/recovery.c
+++ b/fs/f2fs/recovery.c
@@ -500,6 +500,9 @@ int recover_fsync_data(struct f2fs_sb_info *sbi)
 	int err;
 	bool need_writecp = false;
 
+	if (is_set_ckpt_flags(sbi->ckpt, CP_UMOUNT_FLAG))
+		return 0;
+
 	fsync_entry_slab = f2fs_kmem_cache_create("f2fs_fsync_inode_entry",
 			sizeof(struct fsync_inode_entry));
 	if (!fsync_entry_slab)
-- 
2.2.1



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

* Re: [PATCH 1/2] f2fs: don't trigger recovery for normal umount image
  2015-01-31  8:59 [PATCH 1/2] f2fs: don't trigger recovery for normal umount image Chao Yu
@ 2015-02-02 23:31 ` Jaegeuk Kim
  2015-02-05  8:18   ` Chao Yu
  0 siblings, 1 reply; 3+ messages in thread
From: Jaegeuk Kim @ 2015-02-02 23:31 UTC (permalink / raw)
  To: Chao Yu; +Cc: Changman Lee, linux-f2fs-devel, linux-kernel

Hi Chao,

On Sat, Jan 31, 2015 at 04:59:49PM +0800, Chao Yu wrote:
> Our recovery option is on by default, so we will try to recover data for
> a normally umounted image when mounting it, but no data will be recovered.
> 
> So it'd be better to skip the recovery for above condition.

No.
We should consider the existing UMOUNT flag written by old f2fs.

Thanks,

> 
> Signed-off-by: Chao Yu <chao2.yu@samsung.com>
> ---
>  fs/f2fs/recovery.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c
> index 188a034..c80c286 100644
> --- a/fs/f2fs/recovery.c
> +++ b/fs/f2fs/recovery.c
> @@ -500,6 +500,9 @@ int recover_fsync_data(struct f2fs_sb_info *sbi)
>  	int err;
>  	bool need_writecp = false;
>  
> +	if (is_set_ckpt_flags(sbi->ckpt, CP_UMOUNT_FLAG))
> +		return 0;
> +
>  	fsync_entry_slab = f2fs_kmem_cache_create("f2fs_fsync_inode_entry",
>  			sizeof(struct fsync_inode_entry));
>  	if (!fsync_entry_slab)
> -- 
> 2.2.1

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

* RE: [PATCH 1/2] f2fs: don't trigger recovery for normal umount image
  2015-02-02 23:31 ` Jaegeuk Kim
@ 2015-02-05  8:18   ` Chao Yu
  0 siblings, 0 replies; 3+ messages in thread
From: Chao Yu @ 2015-02-05  8:18 UTC (permalink / raw)
  To: 'Jaegeuk Kim'
  Cc: 'Changman Lee', linux-f2fs-devel, linux-kernel

Hi Jaegeuk,

> -----Original Message-----
> From: Jaegeuk Kim [mailto:jaegeuk@kernel.org]
> Sent: Tuesday, February 03, 2015 7:32 AM
> To: Chao Yu
> Cc: Changman Lee; linux-f2fs-devel@lists.sourceforge.net; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH 1/2] f2fs: don't trigger recovery for normal umount image
> 
> Hi Chao,
> 
> On Sat, Jan 31, 2015 at 04:59:49PM +0800, Chao Yu wrote:
> > Our recovery option is on by default, so we will try to recover data for
> > a normally umounted image when mounting it, but no data will be recovered.
> >
> > So it'd be better to skip the recovery for above condition.
> 
> No.
> We should consider the existing UMOUNT flag written by old f2fs.

You're right, compatibility should be considered, my mistaken.

Please ignore this patch.

Thanks,



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

end of thread, other threads:[~2015-02-05  8:18 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-31  8:59 [PATCH 1/2] f2fs: don't trigger recovery for normal umount image Chao Yu
2015-02-02 23:31 ` Jaegeuk Kim
2015-02-05  8:18   ` Chao Yu

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.