lkml.org 
[lkml]   [2022]   [Apr]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v3 09/16] mm/rmap: use page_move_anon_rmap() when reusing a mapped PageAnon() page exclusively
From
On 12.04.22 11:26, Vlastimil Babka wrote:
> On 3/29/22 18:04, David Hildenbrand wrote:
>> We want to mark anonymous pages exclusive, and when using
>> page_move_anon_rmap() we know that we are the exclusive user, as
>> properly documented. This is a preparation for marking anonymous pages
>> exclusive in page_move_anon_rmap().
>>
>> In both instances, we're holding page lock and are sure that we're the
>> exclusive owner (page_count() == 1). hugetlb already properly uses
>> page_move_anon_rmap() in the write fault handler.
>
> Yeah, note that do_wp_page() used to call page_move_anon_rmap() always since
> the latter was introduced, until commit 09854ba94c6a ("mm: do_wp_page()
> simplification"). Probably not intended.

Yeah, it was buried underneath all that reuse_swap_page() complexity.


--
Thanks,

David / dhildenb

\
 
 \ /
  Last update: 2022-04-12 12:28    [W:0.049 / U:0.820 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site