[f2fs-dev] [PATCH v1] f2fs: fix typo

2022-09-01 Thread Yonggil Song
Fix typo in f2fs.h Detected by Jaeyoon Choi Signed-off-by: Yonggil Song --- 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 eddfd35eadb6..661096be59d1 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -274,7 +274,7 @@

[f2fs-dev] [PATCH 14/23] f2fs: Convert f2fs_write_cache_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted the function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Also modified f2fs_all_cluster_page_ready to take in a folio_batch instead of pagevec. This does NOT support large folios. The function currently only utilizes folios of size 1 so this

[f2fs-dev] [PATCH 12/23] f2fs: Convert f2fs_flush_inline_data() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios. This is in preparation for the removal of find_get_pages_tag(). Does NOT support large folios. Signed-off-by: Vishal Moola (Oracle) --- fs/f2fs/node.c | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/fs/f2fs/node.c

[f2fs-dev] [PATCH 17/23] gfs2: Convert gfs2_write_cache_jdata() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted function to use folios throughout. This is in preparation for the removal of find_get_pgaes_range_tag(). Also had to modify and rename gfs2_write_jdata_pagevec() to take in and utilize folio_batch rather than pagevec and use folios rather than pages. gfs2_write_jdata_batch() now

[f2fs-dev] [PATCH 19/23] nilfs2: Convert nilfs_lookup_dirty_node_buffers() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/nilfs2/segment.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/fs/nilfs2/segment.c

[f2fs-dev] [PATCH 23/23] filemap: Remove find_get_pages_range_tag()

2022-09-01 Thread Vishal Moola (Oracle)
All callers to find_get_pages_range_tag(), find_get_pages_tag(), pagevec_lookup_range_tag(), and pagevec_lookup_tag() have been removed. Signed-off-by: Vishal Moola (Oracle) --- include/linux/pagemap.h | 10 --- include/linux/pagevec.h | 8 -- mm/filemap.c| 60

[f2fs-dev] [PATCH 18/23] nilfs2: Convert nilfs_lookup_dirty_data_buffers() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/nilfs2/segment.c | 29 - 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/fs/nilfs2/segment.c

[f2fs-dev] [PATCH 15/23] f2fs: Convert last_fsync_dnode() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/f2fs/node.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/fs/f2fs/node.c b/fs/f2fs/node.c index

[f2fs-dev] [PATCH 22/23] nilfs2: Convert nilfs_clear_dirty_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/nilfs2/page.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/fs/nilfs2/page.c

[f2fs-dev] [PATCH 00/23] Convert to filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
This patch series replaces find_get_pages_range_tag() with filemap_get_folios_tag(). This also allows the removal of multiple calls to compound_head() throughout. It also makes a good chunk of the straightforward conversions to folios, and takes the opportunity to introduce a function that grabs a

[f2fs-dev] [PATCH 16/23] f2fs: Convert f2fs_sync_meta_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Initially the function was checking if the previous page index is truly the previous page i.e. 1 index behind the current page. To convert to folios and maintain this check we need to make the

[f2fs-dev] [PATCH 03/23] filemap: Convert __filemap_fdatawait_range() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- mm/filemap.c | 24 +--- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/mm/filemap.c b/mm/filemap.c index

[f2fs-dev] [PATCH 21/23] nilfs2: Convert nilfs_copy_dirty_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/nilfs2/page.c | 39 --- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git

[f2fs-dev] [PATCH 07/23] btrfs: Convert extent_write_cache_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Now also supports large folios. Signed-off-by: Vishal Moola (Oracle) --- fs/btrfs/extent_io.c | 38 +++--- 1 file changed, 19 insertions(+), 19

[f2fs-dev] [PATCH 13/23] f2fs: Convert f2fs_sync_node_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Does NOT support large folios. Signed-off-by: Vishal Moola (Oracle) --- fs/f2fs/node.c | 17 + 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/fs/f2fs/node.c

[f2fs-dev] [PATCH 05/23] afs: Convert afs_writepages_region() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert to use folios throughout. This function is in preparation to remove find_get_pages_range_tag(). Also modified this function to write the whole batch one at a time, rather than calling for a new set every single write. Signed-off-by: Vishal Moola (Oracle) --- fs/afs/write.c | 114

[f2fs-dev] [PATCH 20/23] nilfs2: Convert nilfs_btree_lookup_dirty_buffers() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/nilfs2/btree.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/fs/nilfs2/btree.c b/fs/nilfs2/btree.c

[f2fs-dev] [PATCH 08/23] ceph: Convert ceph_writepages_start() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). This change does NOT support large folios. This shouldn't be an issue as of now since ceph only utilizes folios of size 1 anyways, and there is a lot of work to be done on ceph

[f2fs-dev] [PATCH 11/23] f2fs: Convert f2fs_fsync_node_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Does NOT support large folios. Signed-off-by: Vishal Moola (Oracle) --- fs/f2fs/node.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/fs/f2fs/node.c

[f2fs-dev] [PATCH 10/23] ext4: Convert mpage_prepare_extent_to_map() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted the function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Now supports large folios. Signed-off-by: Vishal Moola (Oracle) --- fs/ext4/inode.c | 55 - 1 file changed, 27 insertions(+), 28

[f2fs-dev] [PATCH 09/23] cifs: Convert wdata_alloc_and_fillpages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Convert function to use folios. This is in preparation for the removal of find_get_pages_range_tag(). Now also supports the use of large folios. Since tofind might be larger than the max number of folios in a folio_batch (15), we loop through filling in wdata->pages pulling more batches until we

[f2fs-dev] [PATCH 04/23] page-writeback: Convert write_cache_pages() to use filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- mm/page-writeback.c | 44 +++- 1 file changed, 23 insertions(+), 21 deletions(-) diff --git

[f2fs-dev] [PATCH 06/23] btrfs: Convert btree_write_cache_pages() to use filemap_get_folio_tag()

2022-09-01 Thread Vishal Moola (Oracle)
Converted function to use folios throughout. This is in preparation for the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- fs/btrfs/extent_io.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/fs/btrfs/extent_io.c

[f2fs-dev] [PATCH 02/23] filemap: Added filemap_get_folios_tag()

2022-09-01 Thread Vishal Moola (Oracle)
This is the equivalent of find_get_pages_range_tag(), except for folios instead of pages. One noteable difference is filemap_get_folios_tag() does not take in a maximum pages argument. It instead tries to fill a folio batch and stops either once full (15 folios) or reaching the end of the search

[f2fs-dev] [PATCH 01/23] pagemap: Add filemap_grab_folio()

2022-09-01 Thread Vishal Moola (Oracle)
Add function filemap_grab_folio() to grab a folio from the page cache. This function is meant to serve as a folio replacement for grab_cache_page, and is used to facilitate the removal of find_get_pages_range_tag(). Signed-off-by: Vishal Moola (Oracle) --- include/linux/pagemap.h | 20

[f2fs-dev] [PATCH v4 0/3] fscrypt: rework keyring and stop using request_queue

2022-09-01 Thread Eric Biggers
Patch 1 of this series reworks the fscrypt filesystem-level keyring to not use the keyrings subsystem as part of its internal implementation (except for ->mk_users, which remains unchanged for now). This fixes several issues, described in the patch itself. This is also a prerequisite for

[f2fs-dev] [PATCH v4 2/3] fscrypt: stop holding extra request_queue references

2022-09-01 Thread Eric Biggers
From: Eric Biggers Now that the fscrypt_master_key lifetime has been reworked to not be subject to the quirks of the keyrings subsystem, blk_crypto_evict_key() no longer gets called after the filesystem has already been unmounted. Therefore, there is no longer any need to hold extra references

[f2fs-dev] [PATCH v4 1/3] fscrypt: stop using keyrings subsystem for fscrypt_master_key

2022-09-01 Thread Eric Biggers
From: Eric Biggers The approach of fs/crypto/ internally managing the fscrypt_master_key structs as the payloads of "struct key" objects contained in a "struct key" keyring has outlived its usefulness. The original idea was to simplify the code by reusing code from the keyrings subsystem.

[f2fs-dev] [PATCH v4 3/3] fscrypt: work on block_devices instead of request_queues

2022-09-01 Thread Eric Biggers
From: Christoph Hellwig request_queues are a block layer implementation detail that should not leak into file systems. Change the fscrypt inline crypto code to retrieve block devices instead of request_queues from the file system. As part of that, clean up the interaction with multi-device file

Re: [f2fs-dev] [PATCH v2] fsck.f2fs: use elapsed_time in checkpoint for period check

2022-09-01 Thread Chao Yu
On 2022/8/31 16:38, Weichao Guo wrote: We now use walltime for monthly period check. However the walltime is: * unstable(timestamp register reset) and settable(modified by user) * unreasonable(e.g: device power-off for one month, no data changed) When the walltime changes to the past before one

[f2fs-dev] [PATCH -next] f2fs: remove redundant check in f2fs_sanity_check_cluster

2022-09-01 Thread Zhang Qilong via Linux-f2fs-devel
It have checked "compressed" at the entry of f2fs_sanity_check_cluster, just remove the redundant check for better performance here. Signed-off-by: Zhang Qilong --- fs/f2fs/compress.c | 20 +--- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/fs/f2fs/compress.c