lkml.org 
[lkml]   [2023]   [Oct]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v2 1/3] userfaultfd: UFFDIO_REMAP: rmap preparation
From
On 23.09.23 03:31, Suren Baghdasaryan wrote:
> From: Andrea Arcangeli <aarcange@redhat.com>
>
> As far as the rmap code is concerned, UFFDIO_REMAP only alters the
> page->mapping and page->index. It does it while holding the page
> lock. However folio_referenced() is doing rmap walks without taking the
> folio lock first, so folio_lock_anon_vma_read() must be updated to
> re-check that the folio->mapping didn't change after we obtained the
> anon_vma read lock.

I'm curious: why don't we need this for existing users of
page_move_anon_rmap()? What's special about UFFDIO_REMAP?


--
Cheers,

David / dhildenb

\
 
 \ /
  Last update: 2023-10-02 16:43    [W:1.944 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site