From: Matthew Wilcox <willy@infradead.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-fsdevel@vger.kernel.org, intel-gfx@lists.freedesktop.org,
linux-mm@kvack.org, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v2 6/9] i915: Use writeback_iter()
Date: Fri, 4 Apr 2025 14:40:19 +0100 [thread overview]
Message-ID: <Z-_hQwNeiOnNYJVp@casper.infradead.org> (raw)
In-Reply-To: <Z--XtaM7Z3zbjzAu@infradead.org>
On Fri, Apr 04, 2025 at 01:26:29AM -0700, Christoph Hellwig wrote:
> On Wed, Apr 02, 2025 at 04:00:00PM +0100, Matthew Wilcox (Oracle) wrote:
> > Convert from an inefficient loop to the standard writeback iterator.
>
> Not for this patch but a follow on: we really need to improve the
> abstraction for using shmem for driver a bit. Drivers implementing
> their own writeback_iter based loop is a bad idea. Instead the
> code here in __shmem_writeback and the similar version in ttm need to
> be consolidated into a nicely abstracted highlevel API in shmem.c.
>
> Similarly for the mess these drivers cause by calling into the
> write_begin and write_end aops.
Yes, I agree, we need an API for "I want to use some pagable memory"
that's almost certainly built on shmem but doesn't expose nearly as much
of the innards of shmem as this does. I've been vaguely thinking about
what that might look like ever since Darrick came up with xfile for xfs
online scrub. The GPUs have similar requirements, so that's three users.
I don't have anything concrete to talk about yet.
next prev parent reply other threads:[~2025-04-04 13:40 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-02 14:59 [PATCH v2 0/9] Remove aops->writepage Matthew Wilcox (Oracle)
2025-04-02 14:59 ` [PATCH v2 1/9] 9p: Add a migrate_folio method Matthew Wilcox (Oracle)
2025-04-03 3:46 ` Dominique Martinet
2025-04-03 3:53 ` Matthew Wilcox
2025-04-02 14:59 ` [PATCH v2 2/9] vboxsf: Convert to writepages Matthew Wilcox (Oracle)
2025-04-02 14:59 ` [PATCH v2 3/9] migrate: Remove call to ->writepage Matthew Wilcox (Oracle)
2025-04-05 16:56 ` Zi Yan
2025-04-02 14:59 ` [PATCH v2 4/9] writeback: Remove writeback_use_writepage() Matthew Wilcox (Oracle)
2025-04-02 14:59 ` [PATCH v2 5/9] shmem: Add shmem_writeout() Matthew Wilcox (Oracle)
2025-04-02 15:00 ` [PATCH v2 6/9] i915: Use writeback_iter() Matthew Wilcox (Oracle)
2025-04-04 8:26 ` Christoph Hellwig
2025-04-04 13:40 ` Matthew Wilcox [this message]
2025-04-02 15:00 ` [PATCH v2 7/9] ttm: Call shmem_writeout() from ttm_backup_backup_page() Matthew Wilcox (Oracle)
2025-04-02 15:00 ` [PATCH v2 8/9] mm: Remove swap_writepage() and shmem_writepage() Matthew Wilcox (Oracle)
2025-04-02 15:00 ` [PATCH v2 9/9] fs: Remove aops->writepage Matthew Wilcox (Oracle)
2025-04-02 17:10 ` [PATCH v2 1/9] 9p: Add a migrate_folio method David Howells
2025-04-04 8:31 ` [PATCH v2 0/9] Remove aops->writepage Christoph Hellwig
2025-04-04 13:42 ` Matthew Wilcox
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=Z-_hQwNeiOnNYJVp@casper.infradead.org \
--to=willy@infradead.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=hch@infradead.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/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).