[PATCH v1] arm64: mm: Permit PTE SW bits to change in live mappings

Peter Xu peterx at redhat.com
Thu Jun 20 06:31:43 PDT 2024


On Thu, Jun 20, 2024 at 11:26:07AM +0100, Ryan Roberts wrote:
> Yes, I think this works as expected. huge_pte_mkuffd_wp() is just modifying the
> bits in a pte passed on the stack and returns the modified pte. The pgtable is
> not touched at this point. The magic happens in set_huge_pte_at() (called by
> huge_ptep_modify_prot_commit() in your case), which knows how the abstract "huge
> pte" maps to real PMDs or PTEs in the pgtable and applies the passed in pte
> value appropriately to all real pmds/ptes (adjusting the pfn as required in the
> process).

Ah indeed!  That's good enough. :)

Thanks,

-- 
Peter Xu




More information about the linux-arm-kernel mailing list