* [f2fs-dev] [PATCH 05/10] f2fs: Use folio_next_pos() [not found] <20251024170822.1427218-1-willy@infradead.org> @ 2025-10-24 17:08 ` Matthew Wilcox (Oracle) 2025-10-27 11:57 ` Chao Yu via Linux-f2fs-devel 0 siblings, 1 reply; 2+ messages in thread From: Matthew Wilcox (Oracle) @ 2025-10-24 17:08 UTC (permalink / raw) To: linux-fsdevel, Christian Brauner Cc: Jaegeuk Kim, Matthew Wilcox (Oracle), linux-f2fs-devel This is one instruction more efficient than open-coding folio_pos() + folio_size(). It's the equivalent of (x + y) << z rather than x << z + y << z. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Cc: Jaegeuk Kim <jaegeuk@kernel.org> Cc: Chao Yu <chao@kernel.org> Cc: linux-f2fs-devel@lists.sourceforge.net --- fs/f2fs/compress.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c index 6ad8d3bc6df7..be53e06caf3d 100644 --- a/fs/f2fs/compress.c +++ b/fs/f2fs/compress.c @@ -1329,7 +1329,7 @@ static int f2fs_write_compressed_pages(struct compress_ctx *cc, } folio = page_folio(cc->rpages[last_index]); - psize = folio_pos(folio) + folio_size(folio); + psize = folio_next_pos(folio); err = f2fs_get_node_info(fio.sbi, dn.nid, &ni, false); if (err) -- 2.47.2 _______________________________________________ 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] 2+ messages in thread
* Re: [f2fs-dev] [PATCH 05/10] f2fs: Use folio_next_pos() 2025-10-24 17:08 ` [f2fs-dev] [PATCH 05/10] f2fs: Use folio_next_pos() Matthew Wilcox (Oracle) @ 2025-10-27 11:57 ` Chao Yu via Linux-f2fs-devel 0 siblings, 0 replies; 2+ messages in thread From: Chao Yu via Linux-f2fs-devel @ 2025-10-27 11:57 UTC (permalink / raw) To: Matthew Wilcox (Oracle), linux-fsdevel, Christian Brauner Cc: Jaegeuk Kim, linux-f2fs-devel On 10/25/25 01:08, Matthew Wilcox (Oracle) wrote: > This is one instruction more efficient than open-coding folio_pos() + > folio_size(). It's the equivalent of (x + y) << z rather than > x << z + y << z. > > Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> > Cc: Jaegeuk Kim <jaegeuk@kernel.org> > Cc: Chao Yu <chao@kernel.org> > Cc: linux-f2fs-devel@lists.sourceforge.net Reviewed-by: Chao Yu <chao@kernel.org> Thanks, _______________________________________________ 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] 2+ messages in thread
end of thread, other threads:[~2025-10-27 11:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20251024170822.1427218-1-willy@infradead.org>
2025-10-24 17:08 ` [f2fs-dev] [PATCH 05/10] f2fs: Use folio_next_pos() Matthew Wilcox (Oracle)
2025-10-27 11:57 ` Chao Yu via Linux-f2fs-devel
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).