f2fs is focused on flash based storage, so let's enable real-time
discard by default, if user don't want to enable it, 'nodiscard'
mount option should be used on mount.
Signed-off-by: Chao Yu
---
fs/f2fs/super.c | 7 +++
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/fs/f2fs/s
If discard IOs are blocked by user IO, do not skip to select and issue
discard with lower granularity, retry with current granularity.
Signed-off-by: Chao Yu
---
v2:
- fix deadloop.
fs/f2fs/segment.c | 16 +---
1 file changed, 13 insertions(+), 3 deletions(-)
diff --git a/fs/f2fs/se
From: Chao Yu
Some devices has small max_{hw,}discard_sectors, so that in
__blkdev_issue_discard(), one big size discard bio can be split
into multiple small size discard bios, result in heavy load in IO
scheduler and device, which can hang other sync IO for long time.
Now, f2fs is trying to con
From: Chao Yu
If segment type in SSA and SIT is inconsistent, we will encounter below
BUG_ON during GC, to avoid this panic, let's just skip doing GC on such
segment.
The bug is triggered with image reported in below link:
https://bugzilla.kernel.org/show_bug.cgi?id=200223
[ 388.060262] -
From: Chao Yu
This patch add to do sanity check with below field:
- cp_pack_total_block_count
- blkaddr of data/node
- extent info
- Overview
BUG() in verify_block_addr() when writing to a corrupted f2fs image
- Reproduce (4.18 upstream kernel)
- POC (poc.c)
static void activity(char *mpoint)
Hi Xue,
On 2018/7/4 18:46, Liuxue (Alice, Euler Dept seven) wrote:
> Subject: [f2fs-dev] [PATCH 1/2] f2fs: fix to skip GC if type in SSA and SIT
> is inconsistent
> Date: Thu, 28 Jun 2018 18:25:58 +0800
> From: Chao Yu
> To: jaeg...@kernel.org
> CC: linux-ker...@vger.kernel.org, linux-f2fs-devel
Subject: [f2fs-dev] [PATCH 1/2] f2fs: fix to skip GC if type in SSA and SIT is
inconsistent
Date: Thu, 28 Jun 2018 18:25:58 +0800
From: Chao Yu
To: jaeg...@kernel.org
CC: linux-ker...@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net
If segment type in SSA and SIT is inconsistent, we will
In synchronous scenario, like in checkpoint(), we are going to flush
dirty node pages to device synchronously, we can easily failed
writebacking node page due to trylock_page() failure, especially in
condition of intensive lock competition, which can cause long latency
of checkpoint(). So let's use
If the block device is opened by tools, F2FS should not be mounted.
Especially when fsck is running, errors unexpected may happen. So if
tools open a block device, we give it the O_EXCL flag to make sure
the block device is opened exclusivly.
Signed-off-by: Sheng Yong
---
lib/libf2fs.c | 27
f2fs recovery flow is relying on dnode block link list, it means fsynced
file recovery depends on previous dnode's persistence in the list, so
during fsync() we should wait on all regular inode's dnode writebacked
before issuing flush.
By this way, we can avoid dnode block list being broken by out
10 matches
Mail list logo