Tables to enforce the new default protection for the PTEs: we know that Note that when enabling userfaultfd-wp, there is no need to walk page This reverses the logic and implicitly fixes and prevents any Mapped without write-protection (see can_change_pte_writable()) to be Tracking - such that PTEs will be mapped write-protected as defaultĪnd we will only allow selected PTEs that are defintly safe to be Instead, let's enable writenotify - just like we do for softdirty That uses vma->vm_page_prot to set PTE permissions: primarily pte_modify()Īnd mk_pte(), but there might be more (move_pte() looked suspicious atįirst but the protection parameter is essentially unused). ![]() This is problematic for uffd-wp: we'd have to manually check forĪ uffd-wp PTE and manually write-protect that PTE, which is error proneĪnd the logic is the wrong way around. Is that vma->vm_page_prot will still include write permissions, to be setĪs default for all PTEs that get remapped (e.g., mprotect(), NUMA hinting, 16:33 ` Peter Xu 0 siblings, 1 reply 21+ messages in threadįrom: David Hildenbrand 12:27 UTC ( / raw)Ĭc: linux-mm, David Hildenbrand, Ives van Hoorne, Peter Xu, stable,Īndrew Morton, Hugh Dickins, Alistair Popple, Mike Rapoport,Ĭurrently, we don't enable writenotify when enabling userfaultfd-wp onĪ shared writable mapping (for now we only support SHMEM). ![]() Mm/userfaultfd: enable writenotify while userfaultfd-wp is enabled for a VMA All of help / color / mirror / Atom feed * mm/userfaultfd: enable writenotify while userfaultfd-wp is enabled for a VMA 12:27 David Hildenbrand
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |