linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* Inaccessible pages & folios
@ 2021-04-09 19:40 Matthew Wilcox
  2021-04-12 12:18 ` Claudio Imbrenda
  0 siblings, 1 reply; 6+ messages in thread
From: Matthew Wilcox @ 2021-04-09 19:40 UTC (permalink / raw)
  To: Claudio Imbrenda; +Cc: linux-mm, linux-s390

Hi Claudio,

I'm working on making the page cache manage memory in larger chunks than
PAGE_SIZE [1] [2].  In doing so, I came across this call that you added:

@@ -2807,6 +2807,13 @@ int __test_set_page_writeback(struct page *page, bool keep_write)
                inc_zone_page_state(page, NR_ZONE_WRITE_PENDING);
        }
        unlock_page_memcg(page);
+       access_ret = arch_make_page_accessible(page);

I'm going to change __test_set_page_writeback() to take a folio [3] and
now I'm wondering what interface you'd like to use.  My preference would
be to rename arch_make_page_accessible() to arch_make_folio_accessible()
and pass a folio, at which time you would make the entire folio (however
many pages might be in it) accessible.  If you would rather, we can
leave the interface as arch_make_page_accessible(), in which case we'll
just call it N times in __test_set_page_writeback() (and I won't need
to touch gup.c).

Let me know what you want.

[1] https://lwn.net/Articles/849538/
[2] https://lore.kernel.org/linux-mm/20210409185105.188284-1-willy@infradead.org/
[3] https://git.infradead.org/users/willy/pagecache.git/commitdiff/85297eb08f1b034b9652ea63dd053e3be4d7de7f

PS: The prototype is in gfp.h.  That's not really appropriate; gfp.h
is about allocating memory, and this call really has nothing to do with
memory allocation.  I think mm.h is a better place for it, if you can't
find a better header file than that.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-04-15  9:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-09 19:40 Inaccessible pages & folios Matthew Wilcox
2021-04-12 12:18 ` Claudio Imbrenda
2021-04-12 12:43   ` Matthew Wilcox
2021-04-12 13:37     ` Claudio Imbrenda
2021-04-12 13:55       ` Matthew Wilcox
2021-04-15  9:28         ` Claudio Imbrenda

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox