Thread (55 messages) 55 messages, 11 authors, 2021-05-24

Re: [PATCH v5 3/9] mm/mremap: Use pmd/pud_poplulate to update page table entries

From: Aneesh Kumar K.V <hidden>
Date: 2021-05-20 13:23:32
Also in: linux-mm

On 5/20/21 6:16 PM, Peter Xu wrote:
On Thu, May 20, 2021 at 01:56:54PM +0530, Aneesh Kumar K.V wrote:
quoted
quoted
This seems to work at least for my userfaultfd test on shmem, however I don't
fully understand the commit message [1] on: How do we guarantee we're not
moving a thp pte?
move_page_tables() checks for pmd_trans_huge() and ends up calling
move_huge_pmd if it is a THP entry.
Sorry to be unclear: what if a huge pud thp?
I am still checking. Looking at the code before commit 
c49dd340180260c6239e453263a9a244da9a7c85, I don't see kernel handling 
huge pud thp. I haven't studied huge pud thp enough to understand 
whether c49dd340180260c6239e453263a9a244da9a7c85 intent to add that 
support.

We can do a move_huge_pud() like we do for huge pmd thp. But I am not 
sure whether we handle those VMA's earlier and restrict mremap on them?

Are huge pud thp only allowed with DAX vmas?


-aneesh
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help