From: Eric Biggers
xfstest generic/429 sometimes hangs on f2fs, caused by a thread being
unable to take a directory's i_rwsem for write in vfs_rmdir(). In the
test, one thread repeatedly creates and removes a directory, and other
threads repeatedly look up a file in the
Currently, fscrypt provides fscrypt_decrypt_bio_pages() which decrypts a
bio's pages asynchronously, then unlocks them afterwards. But, this
assumes that decryption is the last "postprocessing step" for the bio,
so it's incompatible with additional postprocessing steps such as
authenticity
Currently f2fs's ->readpage() and ->readpages() assume that either the
data undergoes no postprocessing, or decryption only. But with
fs-verity, there will be an additional authenticity verification step,
and it may be needed either by itself, or combined with decryption.
To support this, store
Hello,
These two patches restructure f2fs's read path to allow the data to go
through multiple postprocessing steps, rather than just decryption as is
implemented currently. This is mainly in preparation for doing
authenticity verification of data via fs-verity, though this change
might also be
On 04/18, Eric Biggers wrote:
> Hi Chao,
>
> On Wed, Apr 18, 2018 at 02:27:32PM +0800, Chao Yu wrote:
> > Hi Eric,
> >
> > On 2018/4/18 1:42, Eric Biggers wrote:
> > > Hi Chao,
> > >
> > > On Tue, Apr 17, 2018 at 05:13:12PM +0800, Chao Yu wrote:
> > >>> +
> > >>> +static void
Hi Chao,
On Wed, Apr 18, 2018 at 02:27:32PM +0800, Chao Yu wrote:
> Hi Eric,
>
> On 2018/4/18 1:42, Eric Biggers wrote:
> > Hi Chao,
> >
> > On Tue, Apr 17, 2018 at 05:13:12PM +0800, Chao Yu wrote:
> >>> +
> >>> +static void bio_post_read_processing(struct bio_post_read_ctx *ctx);
> >>> +
> >>>
Hi all,
Please ignore this patch, I just sent this before, sorry.
Thanks,
On 2018/4/18 17:45, Chao Yu wrote:
> ThreadGC thread
> - f2fs_ioc_start_atomic_write
> - get_dirty_pages
> - filemap_write_and_wait_range
> -
Thread AThread BThread C
- f2fs_remount
- stop_gc_thread
- f2fs_sbi_store
- issue_discard_thread
sbi->gc_thread = NULL;
Thread GC thread
- f2fs_ioc_start_atomic_write
- get_dirty_pages
- filemap_write_and_wait_range
- f2fs_gc
- do_garbage_collect
-
In f2fs_ioc_commit_atomic_write, if file is volatile, return -EINVAL to
indicate that commit failure.
Signed-off-by: Chao Yu
---
fs/f2fs/file.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c
index
f2fs doesn't allow abuse on atomic write class interface, so except
limiting in-mem pages' total memory usage capacity, we need to limit
atomic-write usage as well when filesystem is seriously fragmented,
otherwise we may run into infinite loop during foreground GC because
target blocks in victim
This patch adds to show GC failure information in debugfs, now it just
shows count of failure caused by atomic write.
Signed-off-by: Chao Yu
---
fs/f2fs/debug.c | 5 +
fs/f2fs/f2fs.h | 1 +
fs/f2fs/gc.c| 13 +++--
fs/f2fs/gc.h| 2 +-
4 files changed,
Thread AThread BThread C
- f2fs_remount
- stop_gc_thread
- f2fs_sbi_store
- issue_discard_thread
sbi->gc_thread = NULL;
On 2018/4/18 11:06, Yunlei He wrote:
> If a file not set type as hot, has dirty pages more than
> threshold 64 before starting atomic write, may be lose hot
> flag.
>
> v1->v2: move set FI_ATOMIC_FILE flag behind flush dirty pages too,
> in case of dirty pages before starting atomic use atomic
Hi Eric,
On 2018/4/18 1:42, Eric Biggers wrote:
> Hi Chao,
>
> On Tue, Apr 17, 2018 at 05:13:12PM +0800, Chao Yu wrote:
>>> +
>>> +static void bio_post_read_processing(struct bio_post_read_ctx *ctx);
>>> +
>>> +static void decrypt_work(struct work_struct *work)
>>> +{
>>> + struct
15 matches
Mail list logo