[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aQTCoABT6usmY8iF@casper.infradead.org>
Date: Fri, 31 Oct 2025 14:07:28 +0000
From: Matthew Wilcox <willy@...radead.org>
To: Konstantin Komarov <almaz.alexandrovich@...agon-software.com>
Cc: ntfs3@...ts.linux.dev, linux-kernel@...r.kernel.org,
linux-fsdevel@...r.kernel.org
Subject: Re: [PATCH] fs/ntfs3: remove ntfs_bio_pages and use page cache for
compressed I/O
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()
Powered by blists - more mailing lists