From: Matthew Wilcox <willy@infradead.org>
To: Konstantin Komarov <almaz.alexandrovich@paragon-software.com>
Cc: ntfs3@lists.linux.dev, linux-kernel@vger.kernel.org,
linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] fs/ntfs3: remove ntfs_bio_pages and use page cache for compressed I/O
Date: Fri, 31 Oct 2025 14:07:28 +0000 [thread overview]
Message-ID: <aQTCoABT6usmY8iF@casper.infradead.org> (raw)
In-Reply-To: <20251031071516.3604-1-almaz.alexandrovich@paragon-software.com>
On Fri, Oct 31, 2025 at 08:15:16AM +0100, Konstantin Komarov wrote:
> Replace the use of ntfs_bio_pages with the disk page cache for reading and
> writing compressed files. This slightly improves performance when reading
> compressed data and simplifies the I/O logic.
Yes, this is a good improvement.
> + /* Read range [lbo, lbo+len). */
> + page = read_mapping_page(mapping, lbo >> PAGE_SHIFT, NULL);
I'm not keen on this though. read_mapping_page() is deprecated; please
use read_mapping_folio().
> + kaddr = kmap_local_page(page);
kmap_local_folio()
> + if (wr) {
> + memcpy(kaddr + off, buf, op);
> + set_page_dirty(page);
folio_mark_dirty()
> + } else {
> + memcpy(buf, kaddr + off, op);
> + flush_dcache_page(page);
flush_dcache_folio()
> + }
> + kunmap_local(kaddr);
> + put_page(page);
folio_put()
next prev parent reply other threads:[~2025-10-31 14:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-31 7:15 [PATCH] fs/ntfs3: remove ntfs_bio_pages and use page cache for compressed I/O Konstantin Komarov
2025-10-31 14:07 ` Matthew Wilcox [this message]
2025-11-01 15:25 ` [PATCH v2] " Konstantin Komarov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aQTCoABT6usmY8iF@casper.infradead.org \
--to=willy@infradead.org \
--cc=almaz.alexandrovich@paragon-software.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ntfs3@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).