On 11.12.23 17:22, Matthew Wilcox (Oracle) wrote:
We should only see anon folios in this function (and there are many assumptions of that already), so we can simplify these two assertions.
If we swapped in a fresh page, it is not PageAnon before we do the page_add_anon_rmap() call.
So I'm pretty sure this is wrong.[I have plans of moving the "turn into anon folio" out of page_add_anon_rmap(), it will require teaching page_add_new_anon_rmap() about RMAP_EXCLUSIVE]
-- Cheers, David / dhildenb